edit
This commit is contained in:
@ -11,7 +11,7 @@ import { VehicleService } from '../../../services/vehicle.service';
|
||||
@Component({
|
||||
selector: 'app-Vehicle-components-Audit-detail',
|
||||
templateUrl: './detail.component.html',
|
||||
styleUrls: ['./detail.component.less'],
|
||||
styleUrls: ['./detail.component.less']
|
||||
})
|
||||
export class VehicleComponentsAuditDetailComponent implements OnInit {
|
||||
i: any;
|
||||
@ -23,7 +23,9 @@ export class VehicleComponentsAuditDetailComponent implements OnInit {
|
||||
modalName = '';
|
||||
ui!: SFUISchema;
|
||||
columns!: STColumn[];
|
||||
detailData: any;
|
||||
detailData: any = {
|
||||
carNo: '111'
|
||||
};
|
||||
schema!: SFSchema;
|
||||
@ViewChild('sf', { static: false }) sf!: SFComponent;
|
||||
schema1!: SFSchema;
|
||||
@ -31,13 +33,14 @@ export class VehicleComponentsAuditDetailComponent implements OnInit {
|
||||
validData: any = ['suppliersType'];
|
||||
suppliersData: any = {};
|
||||
|
||||
isEdit = false;
|
||||
constructor(
|
||||
private http: _HttpClient,
|
||||
private modal: ModalHelper,
|
||||
public service: VehicleService,
|
||||
private route: ActivatedRoute,
|
||||
private modalHelper: ModalHelper,
|
||||
private msgSrv: NzMessageService,
|
||||
private msgSrv: NzMessageService
|
||||
) {}
|
||||
|
||||
ngOnInit() {
|
||||
@ -46,12 +49,12 @@ export class VehicleComponentsAuditDetailComponent implements OnInit {
|
||||
this.initSF1();
|
||||
this.initST();
|
||||
}
|
||||
/**
|
||||
/**
|
||||
* 查询参数
|
||||
*/
|
||||
get reqParams() {
|
||||
return { id: this.route.snapshot?.params?.id };
|
||||
}
|
||||
get reqParams() {
|
||||
return { id: this.route.snapshot?.params?.id };
|
||||
}
|
||||
/**
|
||||
* 初始化查询表单
|
||||
*/
|
||||
@ -64,17 +67,17 @@ export class VehicleComponentsAuditDetailComponent implements OnInit {
|
||||
type: 'string',
|
||||
ui: {
|
||||
widget: 'date',
|
||||
format: 'yyyy-MM-dd 00:00:00',
|
||||
format: 'yyyy-MM-dd 00:00:00'
|
||||
// hidden: this.modalName === 'effectiveDate' ? false : true,
|
||||
} as SFDateWidgetSchema,
|
||||
},
|
||||
} as SFDateWidgetSchema
|
||||
}
|
||||
},
|
||||
required: ['effectiveDate'],
|
||||
required: ['effectiveDate']
|
||||
};
|
||||
this.ui = { '*': { spanLabelFixed: 120, grid: { span: 24 } } };
|
||||
}
|
||||
initST() {
|
||||
this.columns =[
|
||||
this.columns = [
|
||||
{ title: '认证司机', index: 'name', width: 300, className: 'text-center' },
|
||||
{ title: '司机手机号', index: 'mobile', width: 300, className: 'text-center' },
|
||||
{ title: '是否挂靠', render: 'isSelf', width: 300, className: 'text-center' },
|
||||
@ -87,15 +90,15 @@ export class VehicleComponentsAuditDetailComponent implements OnInit {
|
||||
buttons: [
|
||||
{
|
||||
text: '查看协议',
|
||||
click: (_record) => this.viewEvaluate(_record),
|
||||
click: _record => this.viewEvaluate(_record)
|
||||
},
|
||||
{
|
||||
text: '上传协议',
|
||||
click: (_record) => this.updateEvaluate(_record),
|
||||
},
|
||||
],
|
||||
},
|
||||
]
|
||||
click: _record => this.updateEvaluate(_record)
|
||||
}
|
||||
]
|
||||
}
|
||||
];
|
||||
}
|
||||
initSF1() {
|
||||
this.schema1 = {
|
||||
@ -106,7 +109,7 @@ export class VehicleComponentsAuditDetailComponent implements OnInit {
|
||||
title: '类型',
|
||||
enum: [
|
||||
{ label: '非外部供应商', value: 0 },
|
||||
{ label: '外部供应商', value: 1 },
|
||||
{ label: '外部供应商', value: 1 }
|
||||
],
|
||||
default: '',
|
||||
ui: {
|
||||
@ -121,60 +124,59 @@ export class VehicleComponentsAuditDetailComponent implements OnInit {
|
||||
this.suppliersData.externalSuppliersId = '';
|
||||
}
|
||||
this.initSF1();
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
},
|
||||
externalSuppliersId: {
|
||||
title: '外部供应商id',
|
||||
type: 'string',
|
||||
default: '',
|
||||
ui: {
|
||||
visibleIf: { suppliersType: (value: any) => value === 1 },
|
||||
},
|
||||
},
|
||||
visibleIf: { suppliersType: (value: any) => value === 1 }
|
||||
}
|
||||
}
|
||||
},
|
||||
required: this.validData,
|
||||
required: this.validData
|
||||
};
|
||||
}
|
||||
// 获取录单员
|
||||
// 获取录单员
|
||||
getDetailList() {
|
||||
console.log( this.route.snapshot?.params?.id)
|
||||
console.log(this.route.snapshot?.params?.id);
|
||||
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_get}`, params).subscribe(res => {
|
||||
console.log(res);
|
||||
// this.detailData = res;
|
||||
});
|
||||
}
|
||||
|
||||
goBack() {
|
||||
window.history.go(-1);
|
||||
}
|
||||
|
||||
|
||||
handleCancel(name: any) {
|
||||
|
||||
}
|
||||
handleCancel(name: any) {}
|
||||
|
||||
/**
|
||||
*查看评价
|
||||
*/
|
||||
*查看评价
|
||||
*/
|
||||
viewEvaluate(item: any) {
|
||||
// this.modal.createStatic(VehicleImgViewComponent, { i: { imgUrl: item } }).subscribe(() => {
|
||||
// // this.st.reload();
|
||||
// });
|
||||
}
|
||||
/**
|
||||
*查看评价
|
||||
*/
|
||||
*查看评价
|
||||
*/
|
||||
updateEvaluate(item: any) {
|
||||
// this.modal.createStatic(VehicleComponentsListEditComponent, { i: { item }, infoData: item }).subscribe(() => {
|
||||
// // this.st.reload();
|
||||
// // this.getInfo();
|
||||
// });
|
||||
}
|
||||
handleOK() {
|
||||
|
||||
handleOK() {}
|
||||
|
||||
ratify() {
|
||||
this.isEdit = true;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user