|
|
@@ -187,10 +187,12 @@
|
|
|
<headerTitle title="物品清单" size="16px" style="margin-top: 20px"></headerTitle>
|
|
|
<inventoryTableDetails
|
|
|
ref="inventoryTableDetailsRef"
|
|
|
- :isAllPrice="false"
|
|
|
+ :isAllPrice="true"
|
|
|
:showSummary="true"
|
|
|
:isSelected="false"
|
|
|
+ :isDiscountTotalPrice="true"
|
|
|
cacheKeyUrl="eos-prepayment-inventoryTableDetails"
|
|
|
+ :countObj="countObj"
|
|
|
></inventoryTableDetails>
|
|
|
|
|
|
<!-- 付款信息 -->
|
|
|
@@ -310,6 +312,11 @@
|
|
|
paymentTermsOptions: [],
|
|
|
accountingSubjectList: [],
|
|
|
businessId: '',
|
|
|
+ countObj: {
|
|
|
+ countKey: 'purchaseCount',
|
|
|
+ unitKey: 'purchaseUnit',
|
|
|
+ unitIdKey: 'purchaseUnitId'
|
|
|
+ },
|
|
|
tabOptions: [
|
|
|
{ key: 'main', name: '预付款项' },
|
|
|
{ key: 'bpm', name: '流程详情' }
|
|
|
@@ -414,6 +421,14 @@
|
|
|
this.isDetail = type === 'detail';
|
|
|
if ((this.isUpdate || this.isDetail) && row) {
|
|
|
this.form = await getPrepaymentInfo(row.id);
|
|
|
+ this.form.totalAmount = this.form.productList.reduce((sum, item) => {
|
|
|
+ const val = parseFloat(item.totalPrice);
|
|
|
+ return sum + (isNaN(val) ? 0 : val);
|
|
|
+ }, 0);
|
|
|
+ this.form.discountTotalPrice = this.form.productList.reduce((sum, item) => {
|
|
|
+ const val = parseFloat(item.discountTotalPrice);
|
|
|
+ return sum + (isNaN(val) ? 0 : val);
|
|
|
+ }, 0);
|
|
|
this.businessId = row.id;
|
|
|
this.$nextTick(() => {
|
|
|
this.$refs.inventoryTableDetailsRef &&
|