Commit 3c213c45 by Jansa Jose

dc

parent cc5934d6
...@@ -486,16 +486,24 @@ ...@@ -486,16 +486,24 @@
<input class="search" placeholder="Search Services" (keyup)="searchIssues($event)"> <input class="search" placeholder="Search Services" (keyup)="searchIssues($event)">
</div> </div>
</div> </div>
<p *ngIf="!issuesData">No Record Found</p>
<!-- service-tabs-->
<div class="service_tab_inner" *ngIf="issuesData">
<div class="row"> <div class="row">
<div class="col-md-12"> <div class="col col-6">
<div class="service_methods"> <div class="arrow_btn up_arrow" (click)="scrollToTop('issue_cntr')"></div>
<p *ngIf="!issuesData; else listIssues">No Record Found</p> <ul class="nav services_tab" id="issue_cntr">
<ng-template #listIssues> <li class="nav-item" *ngFor="let issue_data of issuesData; let i = index;">
<ul> <a [ngClass]="(i == 0)?'nav-link text_truncate active':'nav-link text_truncate'" data-toggle="pill" [attr.href]="'#issue_'+issue_data.issue_id"><img src="../../../assets/images/default.png">{{issue_data.issue}}</a>
<div *ngFor="let issue_data of issuesData"> </li>
<li data-toggle="collapse" [attr.data-target]="'#issue_' + issue_data.issue_id">{{issue_data.issue}}</li> </ul>
<div class="service_list collapse" [attr.id]="'issue_' + issue_data.issue_id"> <div class="arrow_btn down_arrow" (click)="scrollToBottom('issue_cntr')"></div>
<ul> </div>
<div class="col col-6">
<div class="arrow_btn"></div>
<div class="tab-content backgroundColor">
<div *ngFor="let issue_data of issuesData; let i = index;" [ngClass]="(i == 0)?'tab-pane container active':'tab-pane container'" [attr.id]="'issue_'+issue_data.issue_id">
<ul malihu-scrollbar [scrollbarOptions]="scrollbarOptions" [attr.id]="'sub_issue_cntr_'+issue_data.issue_id">
<li *ngFor="let sub_issue_data of issue_data.sub_categories"> <li *ngFor="let sub_issue_data of issue_data.sub_categories">
<button id="custom_check_button"> <button id="custom_check_button">
<label> <label>
...@@ -507,12 +515,11 @@ ...@@ -507,12 +515,11 @@
</ul> </ul>
</div> </div>
</div> </div>
</ul> <div class="arrow_btn"></div>
</ng-template>
</div> </div>
</div> </div>
</div> </div>
<br>
<div class="row"> <div class="row">
<div class="col-md-12"> <div class="col-md-12">
<button [ngClass]="{'log_btn_diabled':selectedIssues.length == 0}" class="log_btn next_btn floatRight" type="button" (click)="jumpToStep3()">NEXT</button> <button [ngClass]="{'log_btn_diabled':selectedIssues.length == 0}" class="log_btn next_btn floatRight" type="button" (click)="jumpToStep3()">NEXT</button>
...@@ -573,7 +580,10 @@ ...@@ -573,7 +580,10 @@
<h3>SUMMARY</h3> <h3>SUMMARY</h3>
<div class="row"> <div class="row">
<div class="col-md-12"> <div class="col-md-12">
<h6 class="pt10 textLeft">Issues</h6> <!-- <h6 class="pt10 textLeft">Issues</h6> -->
<div class="wizard_subhead">
Issues Spoted
</div>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
...@@ -581,19 +591,25 @@ ...@@ -581,19 +591,25 @@
<div class="selected_services"> <div class="selected_services">
<ul> <ul>
<li *ngFor="let selIssue of selectedIssues">{{selIssue.issue_category}}<a (click)="removeSelectedItem(selIssue.issue_id,selIssue.sub_issue_id)">&times;</a></li> <li *ngFor="let selIssue of selectedIssues">{{selIssue.issue_category}}<a (click)="removeSelectedItem(selIssue.issue_id,selIssue.sub_issue_id)">&times;</a></li>
<a goToStep="0"><li class="add_more_services">Add more Services</li></a>
<input #goTostep1 type="hidden" goToStep="0">
</ul> </ul>
</div> </div>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="col-md-12"> <div class="col-md-12">
<h6 class="pt10 textLeft"><a goToStep="0">Add more services</a></h6> <div class="wizard_subhead">
<input #goTostep1 type="hidden" goToStep="0"> Location
</div>
</div> </div>
</div> </div>
<div class="row"> <div class="row">
<div class="col-md-12">
<input #newGoogleLocSearch placeholder="Enter Location" autocorrect="off" autocapitalize="off" spellcheck="off" type="text" [ngModel]="(wizardData && wizardData.pickup_data && wizardData.pickup_data.pickup_loc)?wizardData.pickup_data.pickup_loc:''" (keyup)="googlesearchLocError = false;" (ngModelChange)="get_newlocaion(newGoogleLocSearch.value)" [attr.value]="(wizardData && wizardData.pickup_data && wizardData.pickup_data.pickup_loc)?wizardData.pickup_data.pickup_loc:''"> <input #newGoogleLocSearch placeholder="Enter Location" autocorrect="off" autocapitalize="off" spellcheck="off" type="text" [ngModel]="(wizardData && wizardData.pickup_data && wizardData.pickup_data.pickup_loc)?wizardData.pickup_data.pickup_loc:''" (keyup)="googlesearchLocError = false;" (ngModelChange)="get_newlocaion(newGoogleLocSearch.value)" [attr.value]="(wizardData && wizardData.pickup_data && wizardData.pickup_data.pickup_loc)?wizardData.pickup_data.pickup_loc:''">
</div> </div>
</div>
<div class="row"> <div class="row">
<div class="col-md-6"> <div class="col-md-6">
<input placeholder="LAST MAINTENANCE DATE" type="" bsDatepicker name="dob" [ngModel]="" (ngModelChange)="get_newdate($event)"> <input placeholder="LAST MAINTENANCE DATE" type="" bsDatepicker name="dob" [ngModel]="" (ngModelChange)="get_newdate($event)">
......
...@@ -98,6 +98,8 @@ export class DashboardComponent implements OnInit { ...@@ -98,6 +98,8 @@ export class DashboardComponent implements OnInit {
@ViewChild("serviceHistoryTab") public serviceHistoryTabRef: ElementRef; @ViewChild("serviceHistoryTab") public serviceHistoryTabRef: ElementRef;
@ViewChild("closeVehicleAddForm") public closeVehicleAddFormRef: ElementRef; @ViewChild("closeVehicleAddForm") public closeVehicleAddFormRef: ElementRef;
public scrollbarOptions = { axis: 'y', theme: 'minimal-dark' };
constructor(private router : Router, constructor(private router : Router,
public ngZone : NgZone, public ngZone : NgZone,
private route : ActivatedRoute, private route : ActivatedRoute,
...@@ -257,6 +259,7 @@ export class DashboardComponent implements OnInit { ...@@ -257,6 +259,7 @@ export class DashboardComponent implements OnInit {
} }
}); });
} }
console.log(thisObj.selectedIssues);
this.calculateEstimate(); this.calculateEstimate();
} }
...@@ -547,14 +550,22 @@ export class DashboardComponent implements OnInit { ...@@ -547,14 +550,22 @@ export class DashboardComponent implements OnInit {
this.issuesData = this.defIssuesData; this.issuesData = this.defIssuesData;
} else { } else {
const thisObj = this; const thisObj = this;
let subCatArr: any;
let data: any[] = new Array(); let data: any[] = new Array();
let serRegExp = new RegExp(event.target.value,"gi"); let serRegExp = new RegExp(event.target.value,"gi");
thisObj.defIssuesData.forEach(function (issues,index) { thisObj.defIssuesData.forEach(function (issues,index) {
let issueCat = issues.issue; let issueCat = issues.issue;
if(issueCat.search(serRegExp) != -1){ if(issueCat.search(serRegExp) != -1){
data.push(thisObj.defIssuesData[index]); data.push(thisObj.defIssuesData[index]);
} else {
subCatArr = issues.sub_categories;
subCatArr.forEach(function (issues_cat) {
let sub_issue_cat = issues_cat.issue_category;
if(sub_issue_cat.search(serRegExp) != -1){
data.push(thisObj.defIssuesData[index]);
}
});
} }
}); });
this.issuesData = (data.length > 0)?data:false; this.issuesData = (data.length > 0)?data:false;
...@@ -758,6 +769,10 @@ export class DashboardComponent implements OnInit { ...@@ -758,6 +769,10 @@ export class DashboardComponent implements OnInit {
this.optionalDescription = ''; this.optionalDescription = '';
} }
scrollToTop(id){
$('#'+id).stop().animate({scrollTop: 0}, 800);
}
scrollToBottom(id){ scrollToBottom(id){
$('#'+id).stop().animate({scrollTop: $('#'+id)[0].scrollHeight}, 1500); $('#'+id).stop().animate({scrollTop: $('#'+id)[0].scrollHeight}, 1500);
} }
......
...@@ -484,6 +484,7 @@ ...@@ -484,6 +484,7 @@
padding:8px; padding:8px;
padding-left:15px; padding-left:15px;
border-radius: 8px; border-radius: 8px;
padding-right: 35px !important;
color: #272a31; color: #272a31;
background-image: url("../../../assets/images/asset_arrow.png"); background-image: url("../../../assets/images/asset_arrow.png");
background-size: 17px; background-size: 17px;
...@@ -503,6 +504,9 @@ ...@@ -503,6 +504,9 @@
} }
} }
} }
.backgroundColor{
background: #f2f2f275;
}
.tab-content{ .tab-content{
padding-top: 10px; padding-top: 10px;
padding-bottom: 10px; padding-bottom: 10px;
...@@ -770,6 +774,7 @@ ...@@ -770,6 +774,7 @@
padding: 5px; padding: 5px;
margin-bottom: 10px; margin-bottom: 10px;
padding-left: 15px; padding-left: 15px;
background-image: url("/assets/images/asset_down_time_arrow.png"); background-image: url("/assets/images/asset_down_time_arrow.png");
background-position: right 5px top 2px; background-position: right 5px top 2px;
background-repeat: no-repeat; background-repeat: no-repeat;
......
...@@ -107,9 +107,6 @@ export class IndexComponent implements OnInit { ...@@ -107,9 +107,6 @@ export class IndexComponent implements OnInit {
} }
ngOnInit() { ngOnInit() {
// this.wizardModalTrrigerInput.nativeElement.click();
this.vehicleDataForm = new FormGroup({ this.vehicleDataForm = new FormGroup({
trim: new FormControl(''), milage: new FormControl(''), emgine: new FormControl(''), trim: new FormControl(''), milage: new FormControl(''), emgine: new FormControl(''),
last_date: new FormControl(''), last_date: new FormControl(''),
...@@ -222,14 +219,22 @@ export class IndexComponent implements OnInit { ...@@ -222,14 +219,22 @@ export class IndexComponent implements OnInit {
this.issuesData = this.defIssuesData; this.issuesData = this.defIssuesData;
} else { } else {
const thisObj = this; const thisObj = this;
let subCatArr: any;
let data: any[] = new Array(); let data: any[] = new Array();
let serRegExp = new RegExp(event.target.value,"gi"); let serRegExp = new RegExp(event.target.value,"gi");
thisObj.defIssuesData.forEach(function (issues,index) { thisObj.defIssuesData.forEach(function (issues,index) {
let issueCat = issues.issue; let issueCat = issues.issue;
if(issueCat.search(serRegExp) != -1){ if(issueCat.search(serRegExp) != -1){
data.push(thisObj.defIssuesData[index]); data.push(thisObj.defIssuesData[index]);
} else {
subCatArr = issues.sub_categories;
subCatArr.forEach(function (issues_cat) {
let sub_issue_cat = issues_cat.issue_category;
if(sub_issue_cat.search(serRegExp) != -1){
data.push(thisObj.defIssuesData[index]);
}
});
} }
}); });
this.issuesData = (data.length > 0)?data:false; this.issuesData = (data.length > 0)?data:false;
...@@ -243,10 +248,8 @@ export class IndexComponent implements OnInit { ...@@ -243,10 +248,8 @@ export class IndexComponent implements OnInit {
} }
get_newlocaion(lastLoc){ get_newlocaion(lastLoc){
this.cfautocomplete.addListener("place_changed", () => { this.cfautocomplete.addListener("place_changed", () => {
console.log('ffdf');
this.ngZone.run(() => { this.ngZone.run(() => {
let places: google.maps.places.PlaceResult = this.cfautocomplete.getPlace(); let places: google.maps.places.PlaceResult = this.cfautocomplete.getPlace();
console.log(places);
if (places == undefined || places == null || places === undefined || places === null || if (places == undefined || places == null || places === undefined || places === null ||
places.geometry == undefined || places.geometry == null || places.geometry === undefined || places.geometry === null || places.geometry == undefined || places.geometry == null || places.geometry === undefined || places.geometry === null ||
places.formatted_address == undefined || places.formatted_address == null || places.formatted_address === undefined || places.formatted_address === null) { places.formatted_address == undefined || places.formatted_address == null || places.formatted_address === undefined || places.formatted_address === null) {
...@@ -259,7 +262,6 @@ export class IndexComponent implements OnInit { ...@@ -259,7 +262,6 @@ export class IndexComponent implements OnInit {
'pickup_lat':places.geometry.location.lat(), 'pickup_lat':places.geometry.location.lat(),
'pickup_lng':places.geometry.location.lng() 'pickup_lng':places.geometry.location.lng()
}; };
console.log(this.wizardData);
this.addresssearchLocError = false; this.addresssearchLocError = false;
this.lat = places.geometry.location.lat(); this.lat = places.geometry.location.lat();
this.lng = places.geometry.location.lng(); this.lng = places.geometry.location.lng();
......
...@@ -48,6 +48,12 @@ ...@@ -48,6 +48,12 @@
padding:0px !important; padding:0px !important;
} }
.text_truncate{
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
button { button {
cursor: pointer; cursor: pointer;
&:focus { &:focus {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment