Commit a7282ad4 by Sweet Zhang

修改问题

parent a89c0464
{ // launch.json 配置了启动调试时相关设置,configurations下节点名称可为 app-plus/h5/mp-weixin/mp-baidu/mp-alipay/mp-qq/mp-toutiao/mp-360/
// launchtype项可配置值为local或remote, local代表前端连本地云函数,remote代表前端连云端云函数
"version": "0.0",
"configurations": [{
"default" :
{
"launchtype" : "local"
},
"mp-weixin" :
{
"launchtype" : "local"
},
"type" : "uniCloud"
}
]
}
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
<text>万能账户首年交费<text style="font-size: 24rpx;">(如有)</text></text> <text>万能账户首年交费<text style="font-size: 24rpx;">(如有)</text></text>
<view class="inputContent"> <view class="inputContent">
<input class="uni-input" type="number" placeholder="请输入" <input class="uni-input" type="number" placeholder="请输入"
v-model="irrAndSimpleCalcuteParam.allFirstPayment" v-model="irrAndSimpleCalcuteParam.allFirstPayment" @blur="withdrawalTypeInit()"
/><label for=""></label> /><label for=""></label>
</view> </view>
</view> </view>
...@@ -61,7 +61,7 @@ ...@@ -61,7 +61,7 @@
</view> </view>
</view> </view>
<!-- 年金提领信息 --> <!-- 年金提领信息 -->
<view class="annuityContent" v-show="calcuteType==='2'"> <view class="annuityContent" v-show="calcuteType==='2' && !irrAndSimpleCalcuteParam.allFirstPayment">
<view v-for="item in yearWithdrawalInfos"> <view v-for="item in yearWithdrawalInfos">
<view class="inputItem"> <view class="inputItem">
<text>从第几个保单年度开始提取:</text> <text>从第几个保单年度开始提取:</text>
...@@ -142,11 +142,11 @@ ...@@ -142,11 +142,11 @@
<view class="simpleDataResult" v-if="resultShowFlag && calcuteMethod == '1'"> <view class="simpleDataResult" v-if="resultShowFlag && calcuteMethod == '1'">
<view class="inputItem"> <view class="inputItem">
<text class="resultTitle">IRR复利</text> <text class="resultTitle">IRR复利</text>
<text class="calcNumber">{{irrAndSimpleResInfos.length>0?(irrAndSimpleResInfos[0]['irrValue'] * 100).toFixed(3) | numberToCurrency:null}}%</text> <text class="calcNumber">{{irrAndSimpleResInfos.length>0?(irrAndSimpleResInfos[0]['irrValue'] * 100).toFixed(3):null}}%</text>
</view> </view>
<view class="inputItem"> <view class="inputItem">
<text class="resultTitle">单利</text> <text class="resultTitle">单利</text>
<text class="calcNumber">{{irrAndSimpleResInfos.length>0?(irrAndSimpleResInfos[0]['simpleValue'] * 100).toFixed(3) | numberToCurrency:null}}%</text> <text class="calcNumber">{{irrAndSimpleResInfos.length>0?(irrAndSimpleResInfos[0]['simpleValue'] * 100).toFixed(3):null}}%</text>
</view> </view>
</view> </view>
<!-- 批量计算显示结果 --> <!-- 批量计算显示结果 -->
...@@ -262,20 +262,25 @@ ...@@ -262,20 +262,25 @@
} }
}, },
methods: { methods: {
// 当有万能账户时,提领信息清空
withdrawalTypeInit(){
if(this.irrAndSimpleCalcuteParam.allFirstPayment>0) {
this.yearWithdrawalInfos=null
}
},
switchTab(e){ switchTab(e){
if(this.calcuteType !=e){ if(this.calcuteType !=e){
this.calcuteType = e; this.calcuteType = e;
//点年金时初始化1条提领信息 //点年金时初始化1条提领信息
if(e=='2'){ if(e=='2'){
this.irrAndSimpleCalcuteParam.allFirstPayment = null;
this.yearWithdrawalInfos = [].concat([{withdrawalType:'1', this.yearWithdrawalInfos = [].concat([{withdrawalType:'1',
withdrawalStart:null, withdrawalStart:null,
yearWithdrawalAmount:null}]); yearWithdrawalAmount:null}]);
}else if(e=='1'){ }else if(e=='1'){
this.irrAndSimpleCalcuteParam.allFirstPayment = null; this.irrAndSimpleCalcuteParam.allFirstPayment = null;
}else{ }else{
//年金切换到增额时万能账户清空,提领信息清空
this.irrAndSimpleCalcuteParam.allFirstPayment = null;
this.yearWithdrawalInfos = [];
} }
this.resultShowFlag = false; this.resultShowFlag = false;
} }
...@@ -352,7 +357,8 @@ ...@@ -352,7 +357,8 @@
}, },
//提领信息+ //提领信息+
add(){ add(){
this.yearWithdrawalInfos.push({withdrawalType:undefined, this.yearWithdrawalInfos.push({
withdrawalType:undefined,
withdrawalStart:undefined, withdrawalStart:undefined,
withdrawalEnd:undefined, withdrawalEnd:undefined,
yearWithdrawalAmount:undefined, yearWithdrawalAmount:undefined,
...@@ -411,9 +417,9 @@ ...@@ -411,9 +417,9 @@
}) })
return; return;
} }
//年金单次计算时,如果有提领信息,提领信息结束时间为现金价值的年度+1 //年金单次计算时,有提领信息
if(this.calcuteType == 2 && this.yearWithdrawalInfos.length>0){ if(this.calcuteType == 2 && this.yearWithdrawalInfos && this.yearWithdrawalInfos.length>0){
this.yearWithdrawalInfos[0].withdrawalEnd = Number(this.irrAndSimple.nyear) + 1 this.yearWithdrawalInfos[0].withdrawalEnd = Number(this.irrAndSimple.nyear)
} }
} }
const params = { const params = {
......
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