Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
dcarfixers_angular
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
16
Issues
16
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tobin
dcarfixers_angular
Commits
af0f06d1
Commit
af0f06d1
authored
Feb 01, 2019
by
Tobin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
daily commit
parent
0e2d189c
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
172 additions
and
54 deletions
+172
-54
app-routing.module.ts
src/app/app-routing.module.ts
+1
-1
app.module.ts
src/app/app.module.ts
+2
-1
dashboard.component.html
src/app/home/dashboard/dashboard.component.html
+50
-46
dashboard.component.ts
src/app/home/dashboard/dashboard.component.ts
+23
-3
index.component.scss
src/app/home/index/index.component.scss
+1
-1
index.component.ts
src/app/home/index/index.component.ts
+13
-2
responsive.scss
src/assets/css/responsive.scss
+29
-0
asset_nodata.png
src/assets/images/asset_nodata.png
+0
-0
styles.scss
src/styles.scss
+53
-0
No files found.
src/app/app-routing.module.ts
View file @
af0f06d1
...
@@ -6,7 +6,7 @@ const routes: Routes = [
...
@@ -6,7 +6,7 @@ const routes: Routes = [
];
];
@
NgModule
({
@
NgModule
({
imports
:
[
RouterModule
.
forRoot
(
routes
)],
imports
:
[
RouterModule
.
forRoot
(
routes
,
{
useHash
:
true
}
)],
exports
:
[
RouterModule
]
exports
:
[
RouterModule
]
})
})
export
class
AppRoutingModule
{
}
export
class
AppRoutingModule
{
}
src/app/app.module.ts
View file @
af0f06d1
...
@@ -7,6 +7,7 @@ import { HomeModule} from './home/home.module';
...
@@ -7,6 +7,7 @@ import { HomeModule} from './home/home.module';
import
{
NavbarComponent
}
from
'./navbar/navbar.component'
;
import
{
NavbarComponent
}
from
'./navbar/navbar.component'
;
import
{
FooterComponent
}
from
'./footer/footer.component'
;
import
{
FooterComponent
}
from
'./footer/footer.component'
;
import
{
ReactiveFormsModule
}
from
'@angular/forms'
;
import
{
ReactiveFormsModule
}
from
'@angular/forms'
;
import
{
HashLocationStrategy
,
LocationStrategy
}
from
'@angular/common'
;
@
NgModule
({
@
NgModule
({
declarations
:
[
declarations
:
[
...
@@ -21,7 +22,7 @@ import { ReactiveFormsModule } from '@angular/forms';
...
@@ -21,7 +22,7 @@ import { ReactiveFormsModule } from '@angular/forms';
ReactiveFormsModule
,
ReactiveFormsModule
,
HttpClientModule
HttpClientModule
],
],
providers
:
[],
providers
:
[
{
provide
:
LocationStrategy
,
useClass
:
HashLocationStrategy
}
],
bootstrap
:
[
AppComponent
]
bootstrap
:
[
AppComponent
]
})
})
export
class
AppModule
{
}
export
class
AppModule
{
}
src/app/home/dashboard/dashboard.component.html
View file @
af0f06d1
...
@@ -156,10 +156,13 @@
...
@@ -156,10 +156,13 @@
</div>
</div>
<div
class=
"row line_row"
>
<div
class=
"row line_row"
>
<div
class=
"col-md-12"
>
<div
class=
"col-md-12"
>
<div
class=
"vehicle_list"
>
<div
class=
"no_datafound"
*
ngIf=
"!vehDetails; else savedVechiles"
>
<ul>
<img
src=
"assets/images/asset_nodata.png"
>
<li
*
ngIf=
"!vehDetails; else savedVechiles"
>
NO DATA FOUND
</li>
<p>
No Data Found
</p>
<ng-template
#
savedVechiles
>
</div>
<ng-template
#
savedVechiles
>
<div
class=
"vehicle_list"
>
<ul>
<li
*
ngFor=
"let vehicle of vehDetails"
>
<li
*
ngFor=
"let vehicle of vehDetails"
>
<div
class=
"car_details"
>
<div
class=
"car_details"
>
<h5><strong>
{{ vehicle.car_maker | titlecase }}
</strong>
{{ vehicle.car_model | titlecase }}
</h5>
<h5><strong>
{{ vehicle.car_maker | titlecase }}
</strong>
{{ vehicle.car_model | titlecase }}
</h5>
...
@@ -188,14 +191,13 @@
...
@@ -188,14 +191,13 @@
<div
class=
"button_bay"
>
<div
class=
"button_bay"
>
<div
class=
"btn-group-justified"
role=
"group"
aria-label=
"Basic example"
>
<div
class=
"btn-group-justified"
role=
"group"
aria-label=
"Basic example"
>
<button
type=
"button"
class=
"btn book btn-sm"
data-toggle=
"modal"
data-target=
"#wizard"
(
click
)="
bookVechile
(
vehicle
.
customer_veh_id
)"
>
Book Now
</button>
<button
type=
"button"
class=
"btn book btn-sm"
data-toggle=
"modal"
data-target=
"#wizard"
(
click
)="
bookVechile
(
vehicle
.
customer_veh_id
)"
>
Book Now
</button>
<!-- <button type="button" class="btn btn-secondary btn-sm" data-toggle="modal" data-target="#editvehicle">Edit</button> -->
<button
type=
"button"
class=
"btn btn-danger btn-sm"
(
click
)="
deleteCustomerCar
(
vehicle
.
customer_id
,
vehicle
.
customer_veh_id
)"
>
Delete
</button>
<button
type=
"button"
class=
"btn btn-danger btn-sm"
(
click
)="
deleteCustomerCar
(
vehicle
.
customer_id
,
vehicle
.
customer_veh_id
)"
>
Delete
</button>
</div>
</div>
</div>
</div>
</li>
</li>
</
ng-template
>
</
ul
>
</
ul
>
</
div
>
</
div
>
</
ng-template
>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -213,22 +215,23 @@
...
@@ -213,22 +215,23 @@
<div
class=
"row line_row"
>
<div
class=
"row line_row"
>
<div
class=
"col-md-12"
>
<div
class=
"col-md-12"
>
<div
class=
"table-responsive"
>
<div
class=
"table-responsive"
>
<table>
<div
class=
"no_datafound"
*
ngIf=
"!successBookDtls; else successBooking"
>
<thead>
<img
src=
"assets/images/asset_nodata.png"
>
<tr>
<p>
No Data Found
</p>
<th>
Order no
</th>
</div>
<th>
Order Date
</th>
<ng-template
#
successBooking
>
<th>
Vehicle
</th>
<table>
<th>
Mechanic
</th>
<thead>
<th>
Cost
</th>
<tr>
<th>
Action
</th>
<th>
Order no
</th>
</tr>
<th>
Order Date
</th>
</thead>
<th>
Vehicle
</th>
<tbody>
<th>
Mechanic
</th>
<tr
*
ngIf=
"!successBookDtls; else successBooking"
>
<th>
Cost
</th>
<td>
No Data Found
</td>
<th>
Action
</th>
</tr>
</tr>
<ng-template
#
successBooking
>
</thead>
<tbody>
<tr
*
ngFor=
"let bookData of successBookDtls"
>
<tr
*
ngFor=
"let bookData of successBookDtls"
>
<td>
{{bookData.booking_id}}
</td>
<td>
{{bookData.booking_id}}
</td>
<td>
{{bookData.scheduled_date+' '+bookData.scheduled_time}}
</td>
<td>
{{bookData.scheduled_date+' '+bookData.scheduled_time}}
</td>
...
@@ -241,9 +244,9 @@
...
@@ -241,9 +244,9 @@
</div>
</div>
</td>
</td>
</tr>
</tr>
</
ng-template
>
</
tbody
>
</t
body
>
</t
able
>
</
tabl
e>
</
ng-templat
e>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -262,22 +265,23 @@
...
@@ -262,22 +265,23 @@
<div
class=
"row line_row"
>
<div
class=
"row line_row"
>
<div
class=
"col-md-12"
>
<div
class=
"col-md-12"
>
<div
class=
"table-responsive"
>
<div
class=
"table-responsive"
>
<table>
<div
class=
"no_datafound"
*
ngIf=
"!bookingDetails; else allBookDtls"
>
<thead>
<img
src=
"assets/images/asset_nodata.png"
>
<tr>
<p>
No Data Found
</p>
<th>
Order no
</th>
</div>
<th>
Order Date
</th>
<ng-template
#
allBookDtls
>
<th>
Vehicle
</th>
<table>
<th>
Mechanic
</th>
<thead>
<th>
Service Charge
</th>
<tr>
<th>
Order Status
</th>
<th>
Order no
</th>
</tr>
<th>
Order Date
</th>
</thead>
<th>
Vehicle
</th>
<tbody>
<th>
Mechanic
</th>
<tr
*
ngIf=
"!bookingDetails; else allBookDtls"
>
<th>
Service Charge
</th>
<td>
No Data Found
</td>
<th>
Order Status
</th>
</tr>
</tr>
<ng-template
#
allBookDtls
>
</thead>
<tbody>
<tr
*
ngFor=
"let bookData of bookingDetails"
>
<tr
*
ngFor=
"let bookData of bookingDetails"
>
<td>
{{bookData.booking_id}}
</td>
<td>
{{bookData.booking_id}}
</td>
<td>
{{bookData.scheduled_date+' '+bookData.scheduled_time}}
</td>
<td>
{{bookData.scheduled_date+' '+bookData.scheduled_time}}
</td>
...
@@ -290,9 +294,9 @@
...
@@ -290,9 +294,9 @@
<p
*
ngSwitchCase=
"3"
class=
"canceled_status"
>
Canceled
</p>
<p
*
ngSwitchCase=
"3"
class=
"canceled_status"
>
Canceled
</p>
</td>
</td>
</tr>
</tr>
</
ng-template
>
</
tbody
>
</t
body
>
</t
able
>
</
tabl
e>
</
ng-templat
e>
</div>
</div>
</div>
</div>
</div>
</div>
...
...
src/app/home/dashboard/dashboard.component.ts
View file @
af0f06d1
...
@@ -109,6 +109,7 @@ export class DashboardComponent implements OnInit {
...
@@ -109,6 +109,7 @@ export class DashboardComponent implements OnInit {
this
.
loader
=
false
;
this
.
loader
=
false
;
this
.
activeTab
=
'profile'
;
this
.
activeTab
=
'profile'
;
this
.
errMessage
=
false
;
this
.
errMessage
=
false
;
this
.
vehDetails
=
false
;
this
.
searchLocError
=
false
;
this
.
searchLocError
=
false
;
this
.
showLeftArrow
=
false
;
this
.
showLeftArrow
=
false
;
this
.
showRightArrow
=
true
;
this
.
showRightArrow
=
true
;
...
@@ -185,6 +186,7 @@ export class DashboardComponent implements OnInit {
...
@@ -185,6 +186,7 @@ export class DashboardComponent implements OnInit {
}
}
getCustBookDetails
(){
getCustBookDetails
(){
this
.
loader
=
true
;
this
.
webService
.
post_data
(
'getCustBookDetails'
,
{
'customer_id'
:
this
.
loginDetails
.
customer_id
}).
subscribe
(
response
=>
{
this
.
webService
.
post_data
(
'getCustBookDetails'
,
{
'customer_id'
:
this
.
loginDetails
.
customer_id
}).
subscribe
(
response
=>
{
if
(
response
.
status
==
'1'
&&
response
.
bookData
!=
'undefined'
&&
response
.
bookData
!=
undefined
&&
response
.
bookData
!=
'null'
&&
response
.
bookData
!=
null
)
{
if
(
response
.
status
==
'1'
&&
response
.
bookData
!=
'undefined'
&&
response
.
bookData
!=
undefined
&&
response
.
bookData
!=
'null'
&&
response
.
bookData
!=
null
)
{
this
.
bookingDetails
=
response
.
bookData
;
this
.
bookingDetails
=
response
.
bookData
;
...
@@ -201,14 +203,19 @@ export class DashboardComponent implements OnInit {
...
@@ -201,14 +203,19 @@ export class DashboardComponent implements OnInit {
this
.
successBookDtls
=
false
;
this
.
successBookDtls
=
false
;
}
}
}
}
this
.
loader
=
false
;
});
});
}
}
getCustVehDetails
(){
getCustVehDetails
(){
this
.
loader
=
true
;
this
.
webService
.
post_data
(
'customerVechiles'
,
{
'customer_id'
:
this
.
loginDetails
.
customer_id
}).
subscribe
(
response
=>
{
this
.
webService
.
post_data
(
'customerVechiles'
,
{
'customer_id'
:
this
.
loginDetails
.
customer_id
}).
subscribe
(
response
=>
{
if
(
response
.
status
==
'1'
&&
response
.
vehData
!=
'undefined'
&&
response
.
vehData
!=
undefined
&&
response
.
vehData
!=
'null'
&&
response
.
vehData
!=
null
)
{
if
(
response
.
status
==
'1'
&&
response
.
vehData
!=
'
'
&&
response
.
vehData
!=
'
undefined'
&&
response
.
vehData
!=
undefined
&&
response
.
vehData
!=
'null'
&&
response
.
vehData
!=
null
)
{
this
.
vehDetails
=
response
.
vehData
;
this
.
vehDetails
=
response
.
vehData
;
}
else
{
this
.
vehDetails
=
false
;
}
}
this
.
loader
=
false
;
});
});
}
}
...
@@ -628,8 +635,20 @@ export class DashboardComponent implements OnInit {
...
@@ -628,8 +635,20 @@ export class DashboardComponent implements OnInit {
confirmBooking
(){
confirmBooking
(){
this
.
wizardData
[
'customer_id'
]
=
this
.
loginDetails
.
customer_id
;
this
.
wizardData
[
'customer_id'
]
=
this
.
loginDetails
.
customer_id
;
this
.
wizardData
[
'selected_issues'
]
=
this
.
selectedIssues
;
this
.
wizardData
[
'selected_issues'
]
=
this
.
selectedIssues
;
this
.
wizardData
[
'optionalDescription'
]
=
this
.
optionalDescription
;
let
formData
:
FormData
=
new
FormData
();
formData
.
append
(
'data'
,
JSON
.
stringify
(
this
.
wizardData
));
this
.
webService
.
post_data
(
'scheduleNow'
,
this
.
wizardData
).
subscribe
(
response
=>
{
this
.
optionalImges
.
forEach
(
function
(
imgData
,
index
)
{
if
(
!
imgData
){
return
true
;
}
formData
.
append
(
"optFile_"
+
(
index
),
imgData
.
file
);
});
this
.
webService
.
multipart_post
(
'scheduleNow'
,
formData
).
subscribe
(
response
=>
{
// this.webService.post_data('scheduleNow',this.wizardData).subscribe(response => {
if
(
response
.
status
==
'1'
){
if
(
response
.
status
==
'1'
){
this
.
closeWizardRef
.
nativeElement
.
click
();
this
.
closeWizardRef
.
nativeElement
.
click
();
this
.
closeQuoteWizardRef
.
nativeElement
.
click
();
this
.
closeQuoteWizardRef
.
nativeElement
.
click
();
...
@@ -638,7 +657,8 @@ export class DashboardComponent implements OnInit {
...
@@ -638,7 +657,8 @@ export class DashboardComponent implements OnInit {
this
.
selectedIssues
=
[];
this
.
selectedIssues
=
[];
this
.
serviceHistoryTabRef
.
nativeElement
.
click
();
this
.
serviceHistoryTabRef
.
nativeElement
.
click
();
this
.
loader
=
false
;
this
.
getCustBookDetails
();
}
else
{
}
else
{
this
.
loader
=
false
;
this
.
loader
=
false
;
return
false
;
return
false
;
...
...
src/app/home/index/index.component.scss
View file @
af0f06d1
...
@@ -668,7 +668,7 @@
...
@@ -668,7 +668,7 @@
width
:
100%
;
width
:
100%
;
border
:
1px
solid
#1e1e1e
;
border
:
1px
solid
#1e1e1e
;
color
:
#bfbfbf
;
color
:
#bfbfbf
;
padding
-top
:
10px
;
padding
:
10px
;
border-radius
:
20px
;
border-radius
:
20px
;
-webkit-border-radius
:
20px
;
-webkit-border-radius
:
20px
;
-moz-border-radius
:
20px
;
-moz-border-radius
:
20px
;
...
...
src/app/home/index/index.component.ts
View file @
af0f06d1
...
@@ -396,13 +396,24 @@ export class IndexComponent implements OnInit {
...
@@ -396,13 +396,24 @@ export class IndexComponent implements OnInit {
confirmBooking
(){
confirmBooking
(){
this
.
wizardData
[
'customer_id'
]
=
this
.
loginDetails
.
customer_id
;
this
.
wizardData
[
'customer_id'
]
=
this
.
loginDetails
.
customer_id
;
this
.
wizardData
[
'selected_issues'
]
=
this
.
selectedIssues
;
this
.
wizardData
[
'selected_issues'
]
=
this
.
selectedIssues
;
this
.
wizardData
[
'optionalDescription'
]
=
this
.
optionalDescription
;
this
.
webService
.
post_data
(
'scheduleNow'
,
this
.
wizardData
).
subscribe
(
response
=>
{
let
formData
:
FormData
=
new
FormData
();
formData
.
append
(
'data'
,
JSON
.
stringify
(
this
.
wizardData
));
this
.
optionalImges
.
forEach
(
function
(
imgData
,
index
)
{
if
(
!
imgData
){
return
true
;
}
formData
.
append
(
"optFile_"
+
(
index
),
imgData
.
file
);
});
this
.
webService
.
multipart_post
(
'scheduleNow'
,
formData
).
subscribe
(
response
=>
{
// this.webService.post_data('scheduleNow',this.wizardData).subscribe(response => {
if
(
response
.
status
==
'1'
){
if
(
response
.
status
==
'1'
){
this
.
closeWizardRef
.
nativeElement
.
click
();
this
.
closeWizardRef
.
nativeElement
.
click
();
this
.
closeQuoteWizardRef
.
nativeElement
.
click
();
this
.
closeQuoteWizardRef
.
nativeElement
.
click
();
this
.
router
.
navigate
([
'../dashboard'
],{
queryParams
:
{
tab
:
'service'
}});
this
.
router
.
navigate
([
'../dashboard'
],{
queryParams
:
{
tab
:
'service'
}});
this
.
loader
=
false
;
}
else
{
}
else
{
this
.
loader
=
false
;
this
.
loader
=
false
;
return
false
;
return
false
;
...
...
src/assets/css/responsive.scss
View file @
af0f06d1
...
@@ -41,6 +41,35 @@
...
@@ -41,6 +41,35 @@
}
}
.title_banner
{
.title_banner
{
padding
:
15px
!
important
;
padding
:
15px
!
important
;
padding-top
:
100px
!
important
;
}
.title_banner
h1
{
font-size
:
21px
;
}
.log_btn
{
width
:
100px
!
important
;
background-image
:
none
!
important
;
}
.modal-body
{
padding
:
0px
!
important
;
}
.wizard_quotes
{
width
:
100%
!
important
;
}
.scheduletiming_listing
{
width
:
100%
!
important
;
}
.scheduletiming_listing
{
width
:
100%
!
important
;
}
.testimonial_div
{
padding
:
5px
;
.container-fluid
{
max-width
:
100%
!
important
;
}
}
}
.dashboard_tab_content
{
.dashboard_tab_content
{
.container-fluid
{
.container-fluid
{
...
...
src/assets/images/asset_nodata.png
0 → 100644
View file @
af0f06d1
20.5 KB
src/styles.scss
View file @
af0f06d1
...
@@ -479,4 +479,56 @@ section.module.parallax {
...
@@ -479,4 +479,56 @@ section.module.parallax {
.invisible
{
.invisible
{
opacity
:
0
!
important
;
opacity
:
0
!
important
;
}
.success_div
{
width
:
100%
;
background-color
:
#fff
;
text-align
:
center
;
padding-top
:
40px
;
padding-bottom
:
40px
;
img
{
width
:
80px
;
}
h2
{
text-align
:
center
;
padding-top
:
20px
;
padding-bottom
:
20px
;
font-weight
:
400
;
font-size
:
20px
;
color
:
#37547e
;
}
.okay_btn
{
border
:
2px
solid
#2655bf
;
color
:
#2655bf
;
padding
:
10px
;
padding-left
:
50px
;
padding-right
:
50px
;
background
:
transparent
;
margin
:
0
auto
;
border-radius
:
25px
;
-webkit-border-radius
:
25px
;
-moz-border-radius
:
25px
;
-ms-border-radius
:
25px
;
-o-border-radius
:
25px
;
margin-top
:
30px
;
&
:focus
{
outline
:none
;
}
}
}
.no_datafound
{
width
:
100%
;
text-align
:
center
;
img
{
width
:
90px
;
}
p
{
color
:
#37547e
!
important
;
font-size
:
25px
!
important
;
padding-top
:
15px
;
padding-bottom
:
30px
!
important
;
font-weight
:
400
!
important
;
}
}
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment