edit
This commit is contained in:
@ -21,6 +21,10 @@ import { WaybillManagementServe } from '../../services/waybill-management.servic
|
||||
styleUrls: ['./abnormal-appear.component.less']
|
||||
})
|
||||
export class WaybillManagementAbnormalAppearComponent implements OnInit {
|
||||
@ViewChild('detailModal', { static: true })
|
||||
detailModal!: any;
|
||||
@ViewChild('replyModal', { static: true })
|
||||
replyModal!: any;
|
||||
@ViewChild('st', { static: true })
|
||||
st!: STComponent;
|
||||
@ViewChild('st2', { static: true })
|
||||
@ -44,7 +48,14 @@ export class WaybillManagementAbnormalAppearComponent implements OnInit {
|
||||
};
|
||||
|
||||
columns: STColumn[] = [
|
||||
{ title: '异常编号', index: 'exceptionCode', width: '180px', className: 'text-left' },
|
||||
{
|
||||
title: '异常编号',
|
||||
index: 'exceptionCode',
|
||||
width: '180px',
|
||||
className: 'text-left',
|
||||
type: 'link',
|
||||
click: item => this.reviewDetailAction(item)
|
||||
},
|
||||
{ title: '异常类型', index: 'exceptionTypeLabel', width: '180px', className: 'text-left' },
|
||||
{ title: '关联运单号', index: 'wayBillCode', width: '180px', className: 'text-left' },
|
||||
{ title: '网络货运人', index: 'enterpriseInfoName', width: '250px', className: 'text-left' },
|
||||
@ -54,10 +65,24 @@ export class WaybillManagementAbnormalAppearComponent implements OnInit {
|
||||
{ title: '承运司机', index: 'driver', width: '250px', className: 'text-left' },
|
||||
{ title: '异常信息', index: 'exceptionContent', width: '250px', className: 'text-left' },
|
||||
{ title: '异常图片', render: 'exceptionCertificateFirstFilePath', width: '300px', className: 'text-left' },
|
||||
{ title: '上报时间', index: 'createTime', width: '180px', className: 'text-left' }
|
||||
{ title: '上报时间', index: 'createTime', width: '180px', className: 'text-center' },
|
||||
{
|
||||
title: '操作',
|
||||
fixed: 'right',
|
||||
width: '100px',
|
||||
className: 'text-center',
|
||||
buttons: [{ text: '回复', click: item => this.replyAction(item) }]
|
||||
}
|
||||
];
|
||||
columns2: STColumn[] = [
|
||||
{ title: '异常编号', index: 'exceptionCode', width: '180px', className: 'text-left' },
|
||||
{
|
||||
title: '异常编号',
|
||||
index: 'exceptionCode',
|
||||
width: '180px',
|
||||
className: 'text-left',
|
||||
type: 'link',
|
||||
click: item => this.reviewDetailAction(item)
|
||||
},
|
||||
{ title: '异常类型', index: 'exceptionTypeLabel', width: '180px', className: 'text-left' },
|
||||
{ title: '关联运单号', index: 'wayBillCode', width: '180px', className: 'text-left' },
|
||||
{ title: '网络货运人', index: 'enterpriseInfoName', width: '180px', className: 'text-left' },
|
||||
@ -74,7 +99,6 @@ export class WaybillManagementAbnormalAppearComponent implements OnInit {
|
||||
];
|
||||
resourceStatus: number | undefined;
|
||||
|
||||
|
||||
get reqParams() {
|
||||
return {
|
||||
...this.sf?.value,
|
||||
@ -82,7 +106,7 @@ export class WaybillManagementAbnormalAppearComponent implements OnInit {
|
||||
reportingTime: {
|
||||
start: this.sf?.value?.reportingTime?.[0] || '',
|
||||
end: this.sf?.value?.reportingTime?.[1] || ''
|
||||
},
|
||||
}
|
||||
};
|
||||
}
|
||||
get reqParams2() {
|
||||
@ -92,11 +116,12 @@ export class WaybillManagementAbnormalAppearComponent implements OnInit {
|
||||
reportingTime: {
|
||||
start: this.sf?.value?.reportingTime?.[0] || '',
|
||||
end: this.sf?.value?.reportingTime?.[1] || ''
|
||||
},
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
constructor(public service: WaybillManagementServe, private nzModalService: NzModalService, public shipperSrv: ShipperBaseService) { }
|
||||
itemInfo: any = {};
|
||||
replyContent = '';
|
||||
constructor(public service: WaybillManagementServe, private nzModalService: NzModalService, public shipperSrv: ShipperBaseService) {}
|
||||
|
||||
ngOnInit(): void {
|
||||
this.initSF();
|
||||
@ -116,6 +141,51 @@ export class WaybillManagementAbnormalAppearComponent implements OnInit {
|
||||
get queryFieldCount(): number {
|
||||
return Object.keys(this.schema?.properties || {}).length;
|
||||
}
|
||||
|
||||
reviewDetailAction(item: any) {
|
||||
this.itemInfo = {};
|
||||
this.service.request(this.service.$api_get_listOperate_detail, { id: item.id }).subscribe(res => {
|
||||
if (res) {
|
||||
this.itemInfo = res;
|
||||
const modal = this.nzModalService.create({
|
||||
nzContent: this.detailModal,
|
||||
nzWidth: 600,
|
||||
nzTitle: '异常详情',
|
||||
nzFooter: []
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
replyAction(item: any) {
|
||||
this.replyContent = '';
|
||||
const modal = this.nzModalService.create({
|
||||
nzContent: this.replyModal,
|
||||
nzTitle: '回复',
|
||||
nzOnOk: () => {
|
||||
if (!this.replyContent) {
|
||||
this.service.msgSrv.warning('请填写回复内容');
|
||||
return false;
|
||||
}
|
||||
this.service
|
||||
.request(this.service.$api_operate_reply, [
|
||||
{
|
||||
id: item.id,
|
||||
replyContent: this.replyContent
|
||||
}
|
||||
])
|
||||
.subscribe(res => {
|
||||
if (res) {
|
||||
this.service.msgSrv.success('回复成功');
|
||||
this.st.load(1);
|
||||
this.getGoodsSourceStatistical();
|
||||
}
|
||||
});
|
||||
return true;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
initSF() {
|
||||
this.schema = {
|
||||
properties: {
|
||||
@ -265,7 +335,7 @@ export class WaybillManagementAbnormalAppearComponent implements OnInit {
|
||||
*/
|
||||
resetSF() {
|
||||
this.sf.reset();
|
||||
this.isLoading = true
|
||||
this.isLoading = true;
|
||||
}
|
||||
// 获取城市列表
|
||||
getRegionCode(regionCode: any) {
|
||||
|
||||
Reference in New Issue
Block a user