Merge remote-tracking branch 'websoft/master'
This commit is contained in:
@@ -46,6 +46,9 @@
|
|||||||
<el-table-column label="金蝶未认领金额" min-width="140" align="right">
|
<el-table-column label="金蝶未认领金额" min-width="140" align="right">
|
||||||
<template #default="{ row }">{{ formatMoney(row.unclaimedAmount) }}</template>
|
<template #default="{ row }">{{ formatMoney(row.unclaimedAmount) }}</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
<el-table-column label="剩余可认领金额" min-width="140" align="right">
|
||||||
|
<template #default="{ row }">{{ formatMoney(flowRemaining(row)) }}</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="summary" label="摘要" min-width="180" show-overflow-tooltip />
|
<el-table-column prop="summary" label="摘要" min-width="180" show-overflow-tooltip />
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-row :gutter="32" class="receipt-claim-batch-form-page__claim-info">
|
<el-row :gutter="32" class="receipt-claim-batch-form-page__claim-info">
|
||||||
@@ -298,10 +301,21 @@ export default {
|
|||||||
0
|
0
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
flowRemaining(flow) {
|
||||||
|
return Math.max(Number(flow.unclaimedAmount || 0) - Number(flow.claimedAmount || 0), 0);
|
||||||
|
},
|
||||||
maxAllocation(row) {
|
maxAllocation(row) {
|
||||||
const current = Number(row.settlement.allocations?.[row.flow.id] || 0);
|
const current = Number(row.settlement.allocations?.[row.flow.id] || 0);
|
||||||
const otherTotal = this.settlementAllocatedTotal(row.settlement) - current;
|
const otherTotal = this.settlementAllocatedTotal(row.settlement) - current;
|
||||||
return Math.max(this.settlementRemaining(row.settlement) - otherTotal, 0);
|
// 流水维度:该流水其余分摊已占用部分同样挤占剩余可认领金额
|
||||||
|
const flowOtherTotal = this.flowAllocatedTotal(row.flow.id) - current;
|
||||||
|
return Math.max(
|
||||||
|
Math.min(
|
||||||
|
this.settlementRemaining(row.settlement) - otherTotal,
|
||||||
|
this.flowRemaining(row.flow) - flowOtherTotal
|
||||||
|
),
|
||||||
|
0
|
||||||
|
);
|
||||||
},
|
},
|
||||||
handleAllocationChange(settlement) {
|
handleAllocationChange(settlement) {
|
||||||
const total = this.settlementAllocatedTotal(settlement);
|
const total = this.settlementAllocatedTotal(settlement);
|
||||||
|
|||||||
Reference in New Issue
Block a user