采购结算校验
This commit is contained in:
@ -4,7 +4,7 @@
|
||||
v-model:value="tableId" v-model:tableName="tableName" v-model:columnName="columnName"
|
||||
:btnTip="btnTip" @change="changeUpload" :multiple="true" :dataDelete="true"
|
||||
:showDownloadIcon="false"/>
|
||||
<a-table :columns="columns" :data-source="dataFile" >
|
||||
<a-table :columns="columns" :data-source="dataFile" :pagination="false">
|
||||
<template #bodyCell="{ column,record,index, text }">
|
||||
<template v-if="column.dataIndex === 'fileOrg'">
|
||||
<a @click="handleDownload(record)">{{record.fileOrg}}</a>
|
||||
|
||||
@ -107,6 +107,10 @@
|
||||
}
|
||||
let res = await request(obj)
|
||||
tableData.value = res || []
|
||||
tableData.value.forEach(v =>{
|
||||
v.qtySettleGj = v.qtyGj
|
||||
v.qtySettleM3 = v.qtyM3
|
||||
})
|
||||
}
|
||||
async function handleSubmit() {
|
||||
closeModal();
|
||||
|
||||
@ -121,6 +121,7 @@
|
||||
let qtySettleM3 = 0
|
||||
let amount = 0
|
||||
let idx = dataList.value.findIndex(v =>v[rowKey] == curRecord[rowKey])
|
||||
let priceDesc = ''
|
||||
arr.forEach(v=> {
|
||||
qtySettleGj+=Number(v.qtySettleGj) || 0
|
||||
qtySettleM3+=Number(v.qtySettleM3) || 0
|
||||
@ -128,6 +129,14 @@
|
||||
if (idx>-1&&!dataList.value[idx].id) {
|
||||
v.id = ''
|
||||
}
|
||||
let a = v.uomName
|
||||
if (v.uomCode == 'M3' && v.qtySettleM3 && v.priceM3) {
|
||||
a= a+':'+Number(v.qtySettleM3)+'*'+Number(v.priceM3)+'='+Number(v.amount)+';'
|
||||
}
|
||||
if (v.uomCode == 'GJ' && v.qtySettleGj && v.priceGj) {
|
||||
a= a+':'+Number(v.qtySettleGj)+'*'+Number(v.priceGj)+'='+Number(v.amount)+';'
|
||||
}
|
||||
priceDesc=priceDesc+a
|
||||
})
|
||||
// price_gj=amount/qty_settle_gj,保留4位小数
|
||||
// price_m3=amount/qty_settle_m3,保留4位小数
|
||||
@ -140,6 +149,7 @@
|
||||
dataList.value[idx].amount = amount.toFixed(2)
|
||||
dataList.value[idx].priceGj = priceGj.toFixed(4)
|
||||
dataList.value[idx].priceM3 = priceM3.toFixed(4)
|
||||
dataList.value[idx].priceDesc = priceDesc
|
||||
if (props.pageType == 'supplier') {
|
||||
dataList.value[idx].lngPngSettlePurDtlList = arr
|
||||
} else {
|
||||
|
||||
@ -123,7 +123,7 @@
|
||||
},
|
||||
schemas: customSearchFormSchema,
|
||||
fieldMapToTime: [['datePlan', ['startDate', 'endDate'], 'YYYY-MM']],
|
||||
showResetButton: false,
|
||||
showResetButton: true,
|
||||
},
|
||||
beforeFetch: (params) => {
|
||||
return { ...params, FormId: formIdComputedRef.value, PK: 'id',page:params.limit };
|
||||
|
||||
@ -12,6 +12,8 @@ export const customFormConfig = {
|
||||
'ContractPurInt',
|
||||
'ContractSalesInt',
|
||||
'addDayPlanPngSettleSales',
|
||||
'addDayPlanPngSettlePur'
|
||||
'addDayPlanPngSettlePur',
|
||||
'ContractTransPng',
|
||||
'ContractProc'
|
||||
],
|
||||
};
|
||||
Reference in New Issue
Block a user