|
@@ -342,7 +342,7 @@
|
|
|
<!--单价18-->
|
|
|
<Column :label="$t('lift.unitPrice')" prop="unitPrice" align="right" v-if="checkPermi(['user:contract:lift:unitPriceEdit'])">
|
|
|
<template v-slot="scope">
|
|
|
- <MoneyInput :inputValue="scope.row.unitPrice" :zeroLength="2" @change="item=>valueChanged(item,scope.row,'unitPrice')" ></MoneyInput>
|
|
|
+ <MoneyInput :inputValue="scope.row.unitPrice" :zeroLength="2" @change="item=>valueChanged(item,scope.row,'unitPrice',true)" ></MoneyInput>
|
|
|
</template>
|
|
|
</Column >
|
|
|
<!--报价折扣19-->
|
|
@@ -415,13 +415,13 @@
|
|
|
<!--评审运费40 可修改-->
|
|
|
<Column :label="$t('lift.reviewShippingCosts')" prop="reviewShippingCosts" align="right" v-if="checkPermi(['user:contract:lift:reviewShippingCostsEdit'])">
|
|
|
<template v-slot="scope">
|
|
|
- <MoneyInput :inputValue="scope.row.reviewShippingCosts" :zeroLength="2" @change="item=>valueChanged(item,scope.row,'reviewShippingCosts')" ></MoneyInput>
|
|
|
+ <MoneyInput :inputValue="scope.row.reviewShippingCosts" :zeroLength="2" @change="item=>valueChanged(item,scope.row,'reviewShippingCosts',true)" ></MoneyInput>
|
|
|
</template>
|
|
|
</Column >
|
|
|
<!--评审佣金41 可修改-->
|
|
|
<Column :label="$t('lift.reviewCommission')" prop="reviewCommission" align="right" v-if="checkPermi(['user:contract:lift:reviewCommissionEdit'])">
|
|
|
<template v-slot="scope">
|
|
|
- <MoneyInput :inputValue="scope.row.reviewCommission" :zeroLength="2" @change="item=>valueChanged(item,scope.row,'reviewCommission')" ></MoneyInput>
|
|
|
+ <MoneyInput :inputValue="scope.row.reviewCommission" :zeroLength="2" @change="item=>valueChanged(item,scope.row,'reviewCommission',true)" ></MoneyInput>
|
|
|
</template>
|
|
|
</Column >
|
|
|
|
|
@@ -450,14 +450,14 @@
|
|
|
<!--预计内陆运费48 可修改-->
|
|
|
<Column :label="$t('lift.planInlandFreightCost')" align="right" v-if="checkPermi(['user:contract:lift:planInlandFreightCost'])" prop="planInlandFreightCost" >
|
|
|
<template v-slot="scope">
|
|
|
- <MoneyInput :inputValue="scope.row.planInlandFreightCost" :zeroLength="2" @change="item=>valueChanged(item,scope.row,'planInlandFreightCost')" ></MoneyInput>
|
|
|
+ <MoneyInput :inputValue="scope.row.planInlandFreightCost" :zeroLength="2" @change="item=>valueChanged(item,scope.row,'planInlandFreightCost',true)" ></MoneyInput>
|
|
|
</template>
|
|
|
</Column>
|
|
|
|
|
|
<!--预计海运费49 可修改-->
|
|
|
<Column :label="$t('lift.planOceanFreight')" align="right" v-if="checkPermi(['user:contract:lift:planOceanFreight'])" prop="planOceanFreight" >
|
|
|
<template v-slot="scope">
|
|
|
- <MoneyInput :inputValue="scope.row.planOceanFreight" :zeroLength="2" @change="item=>valueChanged(item,scope.row,'planOceanFreight')" ></MoneyInput>
|
|
|
+ <MoneyInput :inputValue="scope.row.planOceanFreight" :zeroLength="2" @change="item=>valueChanged(item,scope.row,'planOceanFreight',true)" ></MoneyInput>
|
|
|
</template>
|
|
|
</Column>
|
|
|
|
|
@@ -476,8 +476,8 @@
|
|
|
|
|
|
<!--其他费用52 不可修改-->
|
|
|
<Column :label="$t('lift.otherFees')" prop="otherCost" v-if="checkPermi(['user:contract:lift:otherCost'])">
|
|
|
- <template #default="{ row }">
|
|
|
- <span>{{ toDecimal2(numFormat(row.otherCost)) }}</span>
|
|
|
+ <template v-slot="scope">
|
|
|
+ <MoneyInput :inputValue="scope.row.otherCost" :zeroLength="2" @change="item=>valueChanged(item,scope.row,'otherCost',true)" ></MoneyInput>
|
|
|
</template>
|
|
|
</Column>
|
|
|
<!--附加费用53 不可修改-->
|
|
@@ -576,7 +576,7 @@ import MoreBtn from "@/components/MoreBtn/index.vue";
|
|
|
import {addLiftBatch, listAllById, listLift, selectProductionOrderNo, updateOrderNoBo} from "@/api/contract/lift";
|
|
|
import {getAreaList} from "@/api/business/crm/account";
|
|
|
import {curAgent} from "@/api/business/crm/lead";
|
|
|
-import {getAllOwnerList, getAuthRole} from "@/api/system/user";
|
|
|
+import {getAllOwnerList, getAuthRole, getNickNameList} from "@/api/system/user";
|
|
|
import MoneyInput from "@/components/element/form/items/moneyInput.vue";
|
|
|
import DatePicker from "@/components/element/form/items/DatePicker.vue";
|
|
|
import DictColumn from "@/components/element/table/DictColumn.vue";
|
|
@@ -590,6 +590,7 @@ import {addSn, listSn} from "@/api/contract/liftSn";
|
|
|
import InputNumberColumn from "@/components/element/table/InputNumberColumn.vue";
|
|
|
import InputNumber from "@/components/element/form/items/InputNumber.vue";
|
|
|
import {getAllNationNeedLanguageList} from "@/api/user/country";
|
|
|
+import {delcommafy} from "@/utils/money";
|
|
|
|
|
|
export default {
|
|
|
name: "Lift",
|
|
@@ -758,13 +759,9 @@ export default {
|
|
|
checkPermi,
|
|
|
/** 查询客户所有人列表 */
|
|
|
getAllOwnerList() {
|
|
|
- getAllOwnerList({onlySalesRole: false}).then(res => {
|
|
|
+ getNickNameList().then(res => {
|
|
|
this.ownerList = res.data;
|
|
|
})
|
|
|
- // //将超级管理员的账号添加
|
|
|
- // getAuthRole(1).then(response => {
|
|
|
- // this.ownerList.push(response.user)
|
|
|
- // })
|
|
|
},
|
|
|
//获取代理商
|
|
|
async curAgent() {
|
|
@@ -955,18 +952,46 @@ export default {
|
|
|
this.$set(this.queryParams, 'rate4SigningContracts', null)
|
|
|
this.$set(this.queryParams, 'rate4Shipment', null)
|
|
|
this.$set(this.queryParams, 'elevatorCode', null)
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
this.handleQuery();
|
|
|
},
|
|
|
- valueChanged(value, rowAmount,column) {
|
|
|
+ valueChanged(value, rowAmount,column,sumFlag) {
|
|
|
this.$nextTick(() => {
|
|
|
this.$set(rowAmount,column,value)
|
|
|
- // this.$set(rowAmount,'additionalCost',this.sumPrice(rowAmount))
|
|
|
+ if(sumFlag != null){
|
|
|
+ console.log("有效果")
|
|
|
+ this.$set(rowAmount,'additionalCost',this.sumPrice1(rowAmount))
|
|
|
+ }
|
|
|
})
|
|
|
},
|
|
|
+ sumPrice1(row){
|
|
|
+ if(isNaN(row.unitPrice)){
|
|
|
+ row.unitPrice = 0.00
|
|
|
+ }
|
|
|
+ if(isNaN(row.planInlandFreightCost)){
|
|
|
+ row.planInlandFreightCost = 0.00
|
|
|
+ }
|
|
|
+ if(isNaN(row.planOceanFreight)){
|
|
|
+ row.planOceanFreight = 0.00
|
|
|
+ }
|
|
|
+ if(isNaN(row.reviewShippingCosts)){
|
|
|
+ row.reviewShippingCosts = 0.00
|
|
|
+ }
|
|
|
+ if(isNaN(row.reviewCommission)){
|
|
|
+ row.reviewCommission = 0.00
|
|
|
+ }
|
|
|
+ if(isNaN(row.otherCost)){
|
|
|
+ row.otherCost = 0.00
|
|
|
+ }
|
|
|
+ let amount = (Number(delcommafy(row.planInlandFreightCost)) +
|
|
|
+ Number(delcommafy(row.planOceanFreight)) +
|
|
|
+ Number(delcommafy(row.reviewShippingCosts)) +
|
|
|
+ Number(delcommafy(row.reviewCommission))+
|
|
|
+ Number(delcommafy(row.otherCost))).toFixed(2) || 0.00
|
|
|
+ row.additionalCost = amount
|
|
|
+ console.log("amount============================》",amount)
|
|
|
+ row.liftAmount = (Number(delcommafy(amount))+Number(delcommafy(row.unitPrice))).toFixed(2)
|
|
|
+ return amount
|
|
|
+ },
|
|
|
|
|
|
|
|
|
// 多选框选中数据
|