|
|
@ -178,6 +178,11 @@ |
|
|
|
<el-form-item><span class="addinputInfo">{{ formobj.loanSecondarySalesCost.vehicleEvaluation }}</span></el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="24"> |
|
|
|
<span style="color: red;font-weight: bold">注:以下费用客户自行处理的无需录入</span> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="8"> |
|
|
|
<div class="span-sty">资方结清费用</div> |
|
|
@ -280,10 +285,16 @@ |
|
|
|
<el-form-item><el-input class="addinputInfo addinputw" v-model="formobj.loanSecondarySalesCost.costDescription" clearable placeholder=""/></el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="24"> |
|
|
|
<div class="span-sty">购方应交总金额</div> |
|
|
|
<el-form-item><span class="addinputInfo">{{ purchaserMoney }}</span></el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="24"> |
|
|
|
<div class="span-sty">预计亏损金额</div> |
|
|
|
<el-form-item><span class="addinputInfo">{{ lossPrice() }}</span></el-form-item> |
|
|
|
<el-form-item><span class="addinputInfo">{{ lossPrice }}</span></el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
@ -410,6 +421,84 @@ export default { |
|
|
|
rules: {} |
|
|
|
} |
|
|
|
}, |
|
|
|
computed: { |
|
|
|
// 计算购方应交总金额 = 车辆售价 + 承担方为购方的各项费用 |
|
|
|
purchaserMoney() { |
|
|
|
let money = 0 |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.vehPrice !== '' ? this.formobj.loanSecondarySalesCost.vehPrice : 0)) * 100) / 100 |
|
|
|
// 资方结清费用不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.bankSettleCost !== '' && this.formobj.loanSecondarySalesCost.bankSettleCostAssume === '购方') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.bankSettleCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 车辆违章费用不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.vehicleViolationCost !== '' && this.formobj.loanSecondarySalesCost.vehicleViolationCostAssume === '购方') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.vehicleViolationCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 年检费不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.inspectYearCost !== '' && this.formobj.loanSecondarySalesCost.inspectYearCostAssume === '购方') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.inspectYearCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 保险费不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.insureCost !== '' && this.formobj.loanSecondarySalesCost.insureCostAssume === '购方') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.insureCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 过户费不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.ownershipCost !== '' && this.formobj.loanSecondarySalesCost.ownershipCostAssume === '购方') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.ownershipCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 停车费不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.stopCost !== '' && this.formobj.loanSecondarySalesCost.stopCostAssume === '购方') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.stopCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 其他费用不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.otherCost !== '' && this.formobj.loanSecondarySalesCost.otherCostAssume === '购方') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.otherCost)) * 100) / 100 |
|
|
|
} |
|
|
|
return money |
|
|
|
}, |
|
|
|
// 计算预计亏损金额 = 欠款合计 - 贷款保证金 - 车辆售价 + 催收费用 + 承担方为公司的各项费用 |
|
|
|
lossPrice() { |
|
|
|
let money = '0' |
|
|
|
money = Math.round((parseFloat(this.formobj.loanSecondarySalesCost.arrearsAll) - parseFloat(this.formobj.loanSecondarySalesCost.loanDeposit)) * 100) / 100 |
|
|
|
// 车辆售价不等于空 |
|
|
|
if (this.formobj.loanSecondarySalesCost.vehPrice !== '') { |
|
|
|
money = Math.round((parseFloat(money) - parseFloat(this.formobj.loanSecondarySalesCost.vehPrice)) * 100) / 100 |
|
|
|
} |
|
|
|
// 催收费用不等于空 |
|
|
|
if (this.formobj.loanSecondarySalesCost.collectionCost !== '') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.collectionCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 资方结清费用不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.bankSettleCost !== '' && this.formobj.loanSecondarySalesCost.bankSettleCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.bankSettleCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 车辆违章费用不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.vehicleViolationCost !== '' && this.formobj.loanSecondarySalesCost.vehicleViolationCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.vehicleViolationCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 年检费不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.inspectYearCost !== '' && this.formobj.loanSecondarySalesCost.inspectYearCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.inspectYearCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 保险费不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.insureCost !== '' && this.formobj.loanSecondarySalesCost.insureCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.insureCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 过户费不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.ownershipCost !== '' && this.formobj.loanSecondarySalesCost.ownershipCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.ownershipCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 停车费不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.stopCost !== '' && this.formobj.loanSecondarySalesCost.stopCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.stopCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 其他费用不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.otherCost !== '' && this.formobj.loanSecondarySalesCost.otherCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.otherCost)) * 100) / 100 |
|
|
|
} |
|
|
|
return money |
|
|
|
} |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
UpNumber(e) { |
|
|
|
e.target.value = e.target.value.replace(/[^0-9.]/g, '') // 清除“数字”和“.”以外的字符 |
|
|
@ -524,53 +613,11 @@ export default { |
|
|
|
this.formobj.loanSecondarySalesCost.otherCostAssume = '' |
|
|
|
} |
|
|
|
}, |
|
|
|
// 计算预计亏损金额 = 欠款合计 - 贷款保证金 - 车辆售价 + 催收费用 + 承担方为公司的各项费用 |
|
|
|
lossPrice() { |
|
|
|
let money = '0' |
|
|
|
money = Math.round((parseFloat(this.formobj.loanSecondarySalesCost.arrearsAll) - parseFloat(this.formobj.loanSecondarySalesCost.loanDeposit)) * 100) / 100 |
|
|
|
// 车辆售价不等于空 |
|
|
|
if (this.formobj.loanSecondarySalesCost.vehPrice !== '') { |
|
|
|
money = Math.round((parseFloat(money) - parseFloat(this.formobj.loanSecondarySalesCost.vehPrice)) * 100) / 100 |
|
|
|
} |
|
|
|
// 催收费用不等于空 |
|
|
|
if (this.formobj.loanSecondarySalesCost.collectionCost !== '') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.collectionCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 资方结清费用不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.bankSettleCost !== '' && this.formobj.loanSecondarySalesCost.bankSettleCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.bankSettleCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 车辆违章费用不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.vehicleViolationCost !== '' && this.formobj.loanSecondarySalesCost.vehicleViolationCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.vehicleViolationCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 年检费不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.inspectYearCost !== '' && this.formobj.loanSecondarySalesCost.inspectYearCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.inspectYearCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 保险费不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.insureCost !== '' && this.formobj.loanSecondarySalesCost.insureCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.insureCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 过户费不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.ownershipCost !== '' && this.formobj.loanSecondarySalesCost.ownershipCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.ownershipCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 停车费不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.stopCost !== '' && this.formobj.loanSecondarySalesCost.stopCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.stopCost)) * 100) / 100 |
|
|
|
} |
|
|
|
// 其他费用不等于空且承担方为公司 |
|
|
|
if (this.formobj.loanSecondarySalesCost.otherCost !== '' && this.formobj.loanSecondarySalesCost.otherCostAssume === '公司') { |
|
|
|
money = Math.round((parseFloat(money) + parseFloat(this.formobj.loanSecondarySalesCost.otherCost)) * 100) / 100 |
|
|
|
} |
|
|
|
this.formobj.loanSecondarySalesCost.lossPrice = money |
|
|
|
return money |
|
|
|
}, |
|
|
|
resetState() { |
|
|
|
this.viewState = 1 |
|
|
|
}, |
|
|
|
saveOrUpdate() { |
|
|
|
this.formobj.loanSecondarySalesCost.lossPrice = this.lossPrice |
|
|
|
this.$refs['form_obj'].validate((valid) => { |
|
|
|
if (valid) { |
|
|
|
this.submitdisabled = true |
|
|
@ -588,6 +635,7 @@ export default { |
|
|
|
}) |
|
|
|
}, |
|
|
|
submit() { |
|
|
|
this.formobj.loanSecondarySalesCost.lossPrice = this.lossPrice |
|
|
|
this.$refs['form_obj'].validate((valid) => { |
|
|
|
if (valid) { |
|
|
|
this.submitdisabled = true |
|
|
|