Commit 612e57d4 authored by 胡's avatar

feat:计算接口

parent 3f4704c6
......@@ -134,7 +134,7 @@
</list-item>
<div class="userInfo">
<span>融资信息</span>
<span class="fei-button" @click="showFeiInfo">非标报价商务信息</span>
<span v-if="nowPolicy.calc_type && nowPolicy.calc_type === 'FREE_CF'" class="fei-button" @click="showFeiInfo">非标报价商务信息</span>
</div>
<div v-if="showHideOnBlur">
<x-dialog v-model="showHideOnBlur" hide-on-blur :dialog-style="{'min-height': '100px', 'padding': '5px'}" >
......@@ -143,22 +143,25 @@
<div>
<span>报价模式</span>
<span class="gray">非标业务-冬歇/雨歇</span>
<span class="gray">{{nowPolicy.product_plan_name}}</span>
</div>
<div>
<div v-if=" ['XCMG_FIRST_N_NO_INTEREST','XCMG_FIRST_N_INTEREST'].includes(nowPolicy.price_list)">
<span>首X期-期数</span>
<span class="gray">3</span>
<span class="gray">{{nowPolicy.lease_times_x}}</span>
</div>
<template v-if="nowPolicy.fallow_x_flag === 'Y'">
<div>
<span>起止月份</span>
</div>
<div style="justify-content: space-around;">
<span class="gray">2021-11-02</span>
<span class="gray">{{nowPolicy.fallow_date_f.slice(0, 10)}}</span>
<span>-</span>
<span class="gray">2021-11-02</span>
<span class="gray">{{nowPolicy.fallow_date_t.slice(0, 10)}}</span>
</div>
</template>
</div>
</x-dialog>
</div>
......@@ -167,7 +170,7 @@
<img src="@/assets/contractCreate/hint.png">提示 以下为单个设备商务政策
</div>
<list-item :item-height="44">
<item v-if="!isReadOnly" :showArrow="true" @click.native="getBusinessPolicy();showModalBusiness=true">
<item v-if="!isReadOnly" :showArrow="true" @click.native="pagenumPolicy=1;getBusinessPolicy();showModalBusiness=true">
<div slot="name" class="required">商务政策</div>
<input slot="content" v-model="saveInfo.product_plan_name" readonly placeholder="请选择">
</item>
......@@ -542,6 +545,11 @@ export default {
finance_amount: '',
credit_id: window.localStorage.credit_id,
},
nowPolicy: {},
isComputedSuccess: {
status: false,
msg: ''
},
}
},
computed: {
......@@ -599,11 +607,6 @@ export default {
if (!newVal) {
this.vehicleImg = ''
}
},
'saveInfo.product_plan_name'(n, o) {
if(n) {
}
}
},
beforeRouteEnter (to, from, next) {
......@@ -617,6 +620,7 @@ export default {
vm.saveInfo.lease_start_date = ''
vm.businessLists = []
vm.divisionLists = []
vm.nowPolicy = {}
vm.pagenum = 1
vm.pagenumPolicy = 1
vm.downNum = false
......@@ -1037,6 +1041,9 @@ export default {
vm.factory_ocr_type = res.info.factory_ocr_type
vm.saveInfo.division_n = res.info.product_name
vm.saveInfo.down_payment = res.info.down_payment
vm.nowPolicy = res.info;
console.log('复现的nowPolicy:', vm.nowPolicy);
}
vm.saveInfo.int_rate_n = vm.saveInfo.int_rate_n.replace('%', '')
vm.saveInfo.down_payment_ratio_n = vm.saveInfo.down_payment_ratio_n.replace('%', '')
......@@ -1049,6 +1056,7 @@ export default {
},
selectBusinessPolicy (e) {
let vm = this
vm.nowPolicy = e; // 保存目前的政策
vm.saveInfo.product_plan_id = e.product_plan_id
vm.saveInfo.product_plan_name = e.product_plan_name
vm.saveInfo.down_payment_ratio = e.down_payment_ratio
......@@ -1082,8 +1090,10 @@ export default {
vm.hlsPopup.hideLoading()
if (res.result === 'S') {
// vm.isComputed = true
vm.isComputedSuccess.status = true;
} else {
hlsPopup.showLongCenter(res.message)
vm.isComputedSuccess = {status: false, msg: res.message};
}
})
},
......@@ -1145,9 +1155,11 @@ export default {
vm.isComputed = true
vm.calculeFlag = true
vm.saveTed = true
vm.isComputedSuccess.status = true;
hlsPopup.showLongCenter('计算成功')
vm.goPlan()
} else {
vm.isComputedSuccess = {status: false, msg: res.message};
vm.hlsPopup.hideLoading()
hlsPopup.showLongCenter(res.message)
}
......@@ -1212,8 +1224,10 @@ export default {
vm.hlsPopup.hideLoading()
if (res.result === 'S') {
hlsPopup.showLongCenter('保存成功')
vm.isComputedSuccess.status = true;;
vm.$routeGo()
} else {
vm.isComputedSuccess = {status: false, msg: res.message};
hlsPopup.showLongCenter(res.message)
}
})
......@@ -1241,6 +1255,10 @@ export default {
async next () {
let vm = this
vm.isComputed = await vm.isComputedCheck()
if(!vm.isComputedSuccess.status) {
hlsPopup.showLongCenter(vm.isComputedSuccess.msg);
return
}
if (vm.isReadOnly) {
vm.$router.push({
name: 'CreateEnclosureInfo',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment