|
|
@ -60,7 +60,7 @@ |
|
|
|
:tableObjectExtend="tableObjectExtend" |
|
|
|
@buttonBaseClick="detailButtonBaseClick" |
|
|
|
> |
|
|
|
<template #qty="{row}"> |
|
|
|
<template #qty="{row}" v-if="tabCurrent.prop == 'ShareReconciliation'"> |
|
|
|
<span :style="{color:row.qty>0?'red':row.qty<0?'#409eff':'#000'}">{{ row.qty }}</span> |
|
|
|
</template> |
|
|
|
<template #amount="{row}" v-if="tabCurrent.prop == 'ShareReconciliation'"> |
|
|
@ -169,13 +169,13 @@ const butttondata = (row, $index) => { |
|
|
|
// defaultButtons.mainListEditBtn({hasPermi:'wms:customerStatementMain:update'}), // 编辑 |
|
|
|
// defaultButtons.mainListDeleteBtn({hasPermi:'wms:customerStatementMain:delete'}), // 删除 |
|
|
|
{ |
|
|
|
label: t('ts.重新比对'), |
|
|
|
label: t('ts.重新对比'), |
|
|
|
name: 'rematch', |
|
|
|
hide: isShowMainButton(row, ['2']), |
|
|
|
type: 'primary', |
|
|
|
icon: '', |
|
|
|
color: '', |
|
|
|
hasPermi: '', |
|
|
|
hasPermi: 'wms:customer-statement-main:recontrast', |
|
|
|
link: true // 文本展现按钮 |
|
|
|
}, |
|
|
|
{ |
|
|
@ -185,7 +185,7 @@ const butttondata = (row, $index) => { |
|
|
|
type: 'primary', |
|
|
|
icon: '', |
|
|
|
color: '', |
|
|
|
hasPermi: '', |
|
|
|
hasPermi: 'wms:customer-statement-main:confirmationContrast', |
|
|
|
link: true // 文本展现按钮 |
|
|
|
}, |
|
|
|
{ |
|
|
@ -194,7 +194,7 @@ const butttondata = (row, $index) => { |
|
|
|
hide: isShowMainButton(row, ['3','4']), |
|
|
|
type: 'primary', |
|
|
|
color: '', |
|
|
|
hasPermi: '', |
|
|
|
hasPermi: 'wms:customer-statement-main:import', |
|
|
|
link: true // 文本展现按钮 |
|
|
|
}, |
|
|
|
{ |
|
|
@ -203,7 +203,7 @@ const butttondata = (row, $index) => { |
|
|
|
hide: isShowMainButton(row, ['4']), |
|
|
|
type: 'primary', |
|
|
|
color: '', |
|
|
|
hasPermi: '', |
|
|
|
hasPermi: 'wms:customer-statement-main:confirmationShare', |
|
|
|
link: true // 文本展现按钮 |
|
|
|
}, |
|
|
|
{ |
|
|
@ -215,8 +215,8 @@ const butttondata = (row, $index) => { |
|
|
|
hasPermi: '', |
|
|
|
link: true // 文本展现按钮 |
|
|
|
}, |
|
|
|
defaultButtons.mainSendBackBtn({ hide: isShowMainButton(row, ['3','4','5']) }), // 退回 |
|
|
|
defaultButtons.mainListCancelBtn({ hide: isShowMainButton(row, ['2','3','4','5'])}), // 作废 |
|
|
|
defaultButtons.mainSendBackBtn({hasPermi: 'wms:customer-statement-main:sendBack', hide: isShowMainButton(row, ['3','4','5']) }), // 退回 |
|
|
|
defaultButtons.mainListCancelBtn({ hasPermi: 'wms:customer-statement-main:publish',hide: isShowMainButton(row, ['2','3','4','5'])}), // 作废 |
|
|
|
|
|
|
|
|
|
|
|
] |
|
|
@ -443,12 +443,12 @@ const changeTabs = async (item) => { |
|
|
|
DetailAllSchemas.value = CustomerStatementDetail.allSchemas |
|
|
|
otherHeadButttonData.value = [{ |
|
|
|
label: t(`ts.导出`).replace('ts.', ''), |
|
|
|
name: 'exportDetail', |
|
|
|
name: 'export', |
|
|
|
hide: false, |
|
|
|
type: 'success', |
|
|
|
icon: 'ep:download', |
|
|
|
color: '', |
|
|
|
hasPermi: '' |
|
|
|
hasPermi: 'wms:customer-statement-main:export' |
|
|
|
}] |
|
|
|
} else if (item.prop == 'Reconciliation') { |
|
|
|
// 点击对账差异按钮 |
|
|
@ -459,7 +459,7 @@ const changeTabs = async (item) => { |
|
|
|
value: chooseRow.value.id |
|
|
|
}] |
|
|
|
DetailAllSchemas.value = CustomerStatementReconciliation.allSchemas |
|
|
|
apiPage.value = CustomerStatementMainApi.getCustomerStatementMainPage |
|
|
|
apiPage.value = CustomerStatementDetailApi.getCustomerStatementReconciliationPage |
|
|
|
otherHeadButttonData.value = [ |
|
|
|
{ |
|
|
|
label: t(`ts.导出`).replace('ts.', ''), |
|
|
@ -468,24 +468,24 @@ const changeTabs = async (item) => { |
|
|
|
type: 'success', |
|
|
|
icon: 'ep:download', |
|
|
|
color: '', |
|
|
|
hasPermi: '' |
|
|
|
hasPermi: 'wms:customer-statement-main:export' |
|
|
|
}, |
|
|
|
{ |
|
|
|
label: t('ts.重新对比'), |
|
|
|
name: 'againContrast', |
|
|
|
hide: false, |
|
|
|
hide: isShowMainButton( chooseRow.value, ['2']), |
|
|
|
type: 'primary', |
|
|
|
color: '', |
|
|
|
float:'left', |
|
|
|
hasPermi: '' |
|
|
|
hasPermi: 'wms:customer-statement-main:recontrast' |
|
|
|
},{ |
|
|
|
label: t('ts.确认对比结果'), |
|
|
|
name: 'confirmResults', |
|
|
|
hide: false, |
|
|
|
hide: isShowMainButton( chooseRow.value, ['2']), |
|
|
|
type: 'primary', |
|
|
|
color: '', |
|
|
|
float:'left', |
|
|
|
hasPermi: '' |
|
|
|
hasPermi: 'wms:customer-statement-main:confirmationContrast' |
|
|
|
}] |
|
|
|
} else if (item.prop == 'ShareReconciliation') { |
|
|
|
// 点击模具分摊对账单按钮 |
|
|
@ -505,16 +505,16 @@ const changeTabs = async (item) => { |
|
|
|
type: 'success', |
|
|
|
icon: 'ep:download', |
|
|
|
color: '', |
|
|
|
hasPermi: '' |
|
|
|
hasPermi: 'wms:customer-statement-main:export' |
|
|
|
}, |
|
|
|
{ |
|
|
|
label: t('ts.确认分摊金额'), |
|
|
|
name: 'confirmShareMoney', |
|
|
|
hide: false, |
|
|
|
hide: isShowMainButton(chooseRow.value, ['4']), |
|
|
|
type: 'primary', |
|
|
|
color: '', |
|
|
|
float:'left', |
|
|
|
hasPermi: '' |
|
|
|
hasPermi: 'wms:customer-statement-main:confirmationShare' |
|
|
|
}] |
|
|
|
} else{ |
|
|
|
tableObjectExtend.value = [] |
|
|
@ -524,9 +524,17 @@ const changeTabs = async (item) => { |
|
|
|
} |
|
|
|
} |
|
|
|
// 点击子表按钮事件 |
|
|
|
const detailButtonBaseClick = (val, item) => { |
|
|
|
if (val == 'exportReconciliation') { |
|
|
|
// 子表导出对账差异 |
|
|
|
const detailButtonBaseClick = (val, item,detailTableObject) => { |
|
|
|
if (val == 'export') { |
|
|
|
// 子表导出明细 |
|
|
|
if (tabCurrent.value.prop == 'Detail') { |
|
|
|
handleExportDetail(detailTableObject) |
|
|
|
} else if (tabCurrent.value.prop == 'Reconciliation') { |
|
|
|
// 子表导出对账差异 |
|
|
|
handleExportReconciliation(detailTableObject) |
|
|
|
} { |
|
|
|
|
|
|
|
} |
|
|
|
}else if (val == 'againContrast') { |
|
|
|
// 重新对比 |
|
|
|
}else if (val == 'confirmResults') { |
|
|
@ -536,6 +544,34 @@ const detailButtonBaseClick = (val, item) => { |
|
|
|
}else if (val == 'confirmShareMoney') { |
|
|
|
// 确认分摊金额 |
|
|
|
} |
|
|
|
} |
|
|
|
// 子表导出明细 |
|
|
|
const handleExportDetail = async (detailTableObject) => { |
|
|
|
try { |
|
|
|
// 导出的二次确认 |
|
|
|
await message.exportConfirm() |
|
|
|
// 发起导出 |
|
|
|
exportLoading.value = true |
|
|
|
const data = await CustomerStatementDetailApi.exportCustomerStatementDetail(detailTableObject.params) |
|
|
|
download.excel(data, `对账差异【${formatDate(new Date())}】.xlsx`) |
|
|
|
} catch { |
|
|
|
} finally { |
|
|
|
exportLoading.value = false |
|
|
|
} |
|
|
|
} |
|
|
|
// 子表导出对账差异 |
|
|
|
const handleExportReconciliation = async (detailTableObject) => { |
|
|
|
try { |
|
|
|
// 导出的二次确认 |
|
|
|
await message.exportConfirm() |
|
|
|
// 发起导出 |
|
|
|
exportLoading.value = true |
|
|
|
const data = await CustomerStatementDetailApi.exportCustomerStatementCompareDetail(detailTableObject.params) |
|
|
|
download.excel(data, `对账差异【${formatDate(new Date())}】.xlsx`) |
|
|
|
} catch { |
|
|
|
} finally { |
|
|
|
exportLoading.value = false |
|
|
|
} |
|
|
|
} |
|
|
|
// 模具分摊对账单修改进屋金额 |
|
|
|
const openDetailForm = (row) => { |
|
|
|