|
@ -264,7 +264,7 @@ const butttondata = (row) => { |
|
|
defaultButtons.mainListDocumentPrintBtn({ hide: isShowMainButton(row, ['3','8']) }), // 单据打印 |
|
|
defaultButtons.mainListDocumentPrintBtn({ hide: isShowMainButton(row, ['3','8']) }), // 单据打印 |
|
|
// 生成记录 |
|
|
// 生成记录 |
|
|
{ |
|
|
{ |
|
|
label: '处理', |
|
|
label: '发货', |
|
|
name: 'genRecords', |
|
|
name: 'genRecords', |
|
|
hide: isShowMainButton(row, ['3']), |
|
|
hide: isShowMainButton(row, ['3']), |
|
|
type: 'primary', |
|
|
type: 'primary', |
|
@ -462,14 +462,28 @@ const handleTur = async (id: number) => { |
|
|
/** 处理按钮操作 */ |
|
|
/** 处理按钮操作 */ |
|
|
const genRecords = async (id: number) => { |
|
|
const genRecords = async (id: number) => { |
|
|
try { |
|
|
try { |
|
|
// 处理的二次确认 |
|
|
await SupplierdeliverRequestMainApi.selfCheckReport(id).then(res => { |
|
|
await message.confirm('是否处理所选中数据?') |
|
|
if(!res){ |
|
|
tableObject.loading = true |
|
|
message.warning("请先上传自检报告!") |
|
|
// 发起处理 |
|
|
return |
|
|
await SupplierdeliverRequestMainApi.genRecordsSupplierdeliverRequestMain(id) |
|
|
}else{ |
|
|
message.success(t('处理成功!')) |
|
|
// 处理的二次确认 |
|
|
// 刷新列表 |
|
|
message.confirm('是否处理所选中数据?') |
|
|
await getList() |
|
|
tableObject.loading = true |
|
|
|
|
|
// 发起处理 |
|
|
|
|
|
SupplierdeliverRequestMainApi.genRecordsSupplierdeliverRequestMain(id).then(res => { |
|
|
|
|
|
if(!res){ |
|
|
|
|
|
message.success(t('处理成功!')) |
|
|
|
|
|
// 单据打印 |
|
|
|
|
|
handleDocumentPrint(id) |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
// 刷新列表 |
|
|
|
|
|
getList() |
|
|
|
|
|
} |
|
|
|
|
|
}).catch(err => { |
|
|
|
|
|
console.log("自检报告校验异常",err) |
|
|
|
|
|
}) |
|
|
} catch {}finally{ |
|
|
} catch {}finally{ |
|
|
tableObject.loading = false |
|
|
tableObject.loading = false |
|
|
} |
|
|
} |
|
|