车辆对接

This commit is contained in:
wangshiming
2021-12-16 11:23:34 +08:00
parent 1a8468a8a9
commit fc53095c17
15 changed files with 450 additions and 140 deletions

View File

@ -11,6 +11,7 @@ import { ImageViewComponent } from 'src/app/shared/components/imagelist';
import { VehicleService } from '../../../services/vehicle.service';
// import { VehicleComponentsListEditComponent } from '../edit/edit.component';
// import { VehicleImgViewComponent } from '../img-view/img-view.component';
import { EADateUtil } from '@shared';
@Component({
selector: 'app-Vehicle-components-Audit-detail',
@ -22,17 +23,18 @@ export class VehicleComponentsAuditDetailComponent implements OnInit {
@ViewChild('redectModal', { static: false }) redectModal!: any;
columns!: STColumn[];
detailData: any = this.initData();
tempalateData = { ...this.detailData };
tempalateData :any;
contenCarNoColor: any;
contencarModel: any;
contenCarLength: any;
isEdit = false;
approvalOpinion = '';
uploadURl = apiConf.waterFileUpload;
disabledUpload = false;
constructor(public service: VehicleService, private route: ActivatedRoute, private nzModalService: NzModalService) {}
ngOnInit() {
this.getSelectList();
this.getDetailList();
this.initST();
}
@ -67,9 +69,9 @@ export class VehicleComponentsAuditDetailComponent implements OnInit {
const params = {
id: this.route.snapshot?.params?.id
};
this.service.request(`${this.service.$api_get_operate_get}`, params).subscribe(res => {
console.log(res);
// this.detailData = res;
this.service.request(`${this.service.$api_get_operate_getaudit}`, params).subscribe(res => {
this.detailData = res;
this.tempalateData = res;
});
}
@ -116,6 +118,15 @@ export class VehicleComponentsAuditDetailComponent implements OnInit {
save() {
this.isEdit = false;
this.detailData.driverLicenseRegisterTime = EADateUtil.yearToDate(this.detailData?.driverLicenseRegisterTime)
this.detailData.driverLicenseEndTime = EADateUtil.yearToDate(this.detailData?.driverLicenseEndTime)
this.detailData.driverLicenseGetTime = EADateUtil.yearToDate(this.detailData?.driverLicenseGetTime)
this.detailData.roadTransportStartTime = EADateUtil.yearToDate(this.detailData?.roadTransportStartTime)
this.detailData.roadTransportEndTime = EADateUtil.yearToDate(this.detailData?.roadTransportEndTime)
}
ratify() {
@ -132,7 +143,12 @@ export class VehicleComponentsAuditDetailComponent implements OnInit {
goBack() {
window.history.go(-1);
}
/**
* 查询参数
*/
get reqParams() {
return { id: this.route.snapshot?.params?.id };
}
showImg(url: any) {
const params = {
imgList: [url],
@ -187,4 +203,26 @@ export class VehicleComponentsAuditDetailComponent implements OnInit {
carFrontPhotoWatermark: ''
};
}
// 获取录单员
getSelectList() {
this.Serveice("CarColor")
this.Serveice("CarModel")
this.Serveice("CarLength")
}
Serveice(param :any) {
let value: any;
this.service.request(`${this.service.$api_get_getDictValue}`,
{
dictKey: param
}).subscribe((res) => {
if(param === 'CarColor') {
this.contenCarNoColor = res;
} else if(param === 'CarModel') {
this.contencarModel = res;
} else if(param === 'CarLength') {
this.contenCarLength = res;
}
})
return value;
}
}