Commit 0e335c28 by kyle

规划参数

parent 8f6d420c
......@@ -64,7 +64,7 @@
<text>新房贷款年利率:</text>
<view class="inputContent">
<input class="uni-input" type="number" placeholder="请输入"
maxlength="3" v-model="housePurchaseInfo.interestRate"
maxlength="4" v-model="housePurchaseInfo.interestRate"
/><label for="">%</label>
</view>
</view>
......@@ -137,8 +137,8 @@
class="btn" @click="startCount()">开始计算</button>
</view>
</form>
<!--测算结果-->
<view class="result_wrapper" v-show="resultFlag">
<!--测算结果-- v-show="resultFlag"-->
<view class="result_wrapper">
<view class="suggestInfo">
<view class="title">
<view>
......@@ -197,7 +197,7 @@
<!--旧房贷款余额组件-->
<loanBalance v-if="isLoanSelected" :a="accumulationFundParams" :b="commercialLoansParams" :loanType="1" @getData="getData"></loanBalance>
<!--规划参数组件-->
<planningParameters v-if="paramsSelected"></planningParameters>
<planningParameters v-if="paramsSelected" @getData="getPlanParams"></planningParameters>
</view>
</view>
</template>
......@@ -267,6 +267,11 @@
this.provCityQry();
},
methods:{
getPlanParams(e){
console.log(e)
// 从规划参数弹窗获取数据
this.closeBtn()
},
editParams(){
this.dialogIsShow = this.isEditFlag = true;
},
......@@ -301,7 +306,7 @@
}
this.myChart.setOption({
legend: {
data: ['首付款', '总贷款金额']
data: ['首付款', '总贷款金额']
},
grid: {
left: '20%', // 调整这个属性
......@@ -398,6 +403,7 @@
this.resultFlag = true;
this.resultInfos = res['data'];
this.housePurchasePrices = res['data']['housePurchasePrices'];
this.drawLine()
}else{
common.errorDialog(2,res['message'])
}
......@@ -465,8 +471,8 @@
.inputItem {
.inputContent {
label{
width: 200rpx;
text-align: right;
white-space: nowrap;
}
}
.btn_wrapper{
......
......@@ -28,6 +28,7 @@
import api from '../../api/api';
import common from '../../common/common'
export default{
emits:['getData'],
data(){
return {
paramsLists:[
......@@ -52,6 +53,12 @@
onLoad(){
},
setup(props,content){
const sendData = (e) =>{
content.emit('getData',e);
}
return {sendData}
},
methods:{
onchange(e) {
// const value = e.detail.value;
......@@ -77,7 +84,16 @@
})
},
confirmParams(){
const params = {
housePriceGrowthRate:this.editParamLists.filter(item=>item.alias==='housePriceGrowthRate')[0].value,//房价增长率
houseDepreciationRate:this.editParamLists.filter(item=>item.alias==='houseDepreciationRate')[0].value,//房屋折旧率
downPaymentMin:this.editParamLists.filter(item=>item.alias==='downPaymentMin')[0].value,//首付款最低成数(百分位)
interestRate:this.editParamLists.filter(item=>item.alias==='interestRate')[0].value, //贷款年利率
tnvestmentRate:this.editParamLists.filter(item=>item.alias==='tnvestmentRate')[0].value,//投资回报率
incomeRate:this.editParamLists.filter(item=>item.alias==='incomeRate')[0].value,//收入增长率
acceptableLossRate:this.editParamLists.filter(item=>item.alias==='acceptableLossRate')[0].value,//可接受本金损失率
}
this.sendData(params)
},
// 获取房价增长率
queryCommercialHousingPrice(provinceId,cityId){
......
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