mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-15 12:56:44 +08:00
切换tab,通过,未通过时,需要重置右上角的按钮状态--全部展开
This commit is contained in:
@@ -37,45 +37,42 @@
|
||||
>{{ item.approvalDate }}</div>
|
||||
<div class="bg-white pv15 pr15 pl10 mt15">
|
||||
<van-collapse v-model="activeNames">
|
||||
<!-- <van-checkbox-group v-model="item.checkboxResult" :ref="'checkboxGroup'+index"> -->
|
||||
<van-collapse-item :name="item01.id" v-for="(item01, index01) in item.claimApprovalSearchLst" :key="index01">
|
||||
<template #title>
|
||||
<span @click.stop="checkBoxSwitch(item01.id,item01.isChecked)">
|
||||
<i :class="item01.isChecked=='0'?'checked':'nochecked'"></i>
|
||||
</span>
|
||||
<!-- <van-checkbox :name="item01.id" v-if="active == 'notApproved'" label-disabled @click.stop="checkBoxClick"></van-checkbox> -->
|
||||
<span class="ml5 mr10 fwb">{{index01+1}}.{{item01.insuredName}}</span>
|
||||
<span class="mr10 fwb">{{item01.caseEndDate}}</span>
|
||||
<span class="mr10 fwb">{{item01.getMoney}}元</span>
|
||||
</template>
|
||||
<div class="pb10 pt10 border-gb" style="border-top: 1px solid #dadada;">
|
||||
<div class="w130 inline-b">赔案号:</div>
|
||||
<span class="fs14 c-gray-dark ml20">{{ item01.clmNo }}</span>
|
||||
</div>
|
||||
<div v-for="(item02, index02) in item01.claimPayeeLst" :key="index02">
|
||||
<div class="pb10 pt10 border-gb">
|
||||
<div class="w130 inline-b">领款人:</div>
|
||||
<span class="fs14 c-gray-dark ml20">{{ item02.payeeName }}</span>
|
||||
</div>
|
||||
<div class="pb10 pt10 border-gb">
|
||||
<div class="w130 inline-b">领款金额(万元):</div>
|
||||
<span class="fs14 c-gray-dark ml20">{{ item02.payMoney }}</span>
|
||||
</div>
|
||||
<div class="pb10 pt10 border-gb">
|
||||
<div class="w130 inline-b">先前支付失败次数:</div>
|
||||
<span class="fs14 c-gray-dark ml20">{{ item02.getCount }}</span>
|
||||
</div>
|
||||
<div class="pb10 pt10 border-gb">
|
||||
<div class="w130 inline-b">上一次支付失败原因:</div>
|
||||
<span class="fs14 c-gray-dark ml20">{{ item02.lastFailReason }}</span>
|
||||
</div>
|
||||
<div class="pb10 pt10 border-gb">
|
||||
<div class="w130 inline-b">上一次支付失败日期:</div>
|
||||
<span class="fs14 c-gray-dark ml20">{{ item02.lastFailDate }}</span>
|
||||
</div>
|
||||
</div>
|
||||
</van-collapse-item>
|
||||
<!-- </van-checkbox-group> -->
|
||||
<van-collapse-item :name="item01.id" v-for="(item01, index01) in item.claimApprovalSearchLst" :key="index01">
|
||||
<template #title>
|
||||
<span class="w30 h30 inline-b" @click.stop="checkBoxSwitch(item01.id,item01.isChecked)">
|
||||
<i :class="item01.isChecked=='0'?'checked':'nochecked'"></i>
|
||||
</span>
|
||||
<span class="ml5 mr10 fwb">{{index01+1}}.{{item01.insuredName}}</span>
|
||||
<span class="mr10 fwb">{{item01.caseEndDate}}</span>
|
||||
<span class="mr10 fwb">{{item01.getMoney}}元</span>
|
||||
</template>
|
||||
<div class="pb10 pt10 border-gb" style="border-top: 1px solid #dadada;">
|
||||
<div class="w130 inline-b">赔案号:</div>
|
||||
<span class="fs14 c-gray-dark ml20">{{ item01.clmNo }}</span>
|
||||
</div>
|
||||
<div v-for="(item02, index02) in item01.claimPayeeLst" :key="index02">
|
||||
<div class="pb10 pt10 border-gb">
|
||||
<div class="w130 inline-b">领款人:</div>
|
||||
<span class="fs14 c-gray-dark ml20">{{ item02.payeeName }}</span>
|
||||
</div>
|
||||
<div class="pb10 pt10 border-gb">
|
||||
<div class="w130 inline-b">领款金额(万元):</div>
|
||||
<span class="fs14 c-gray-dark ml20">{{ item02.payMoney }}</span>
|
||||
</div>
|
||||
<div class="pb10 pt10 border-gb">
|
||||
<div class="w130 inline-b">先前支付失败次数:</div>
|
||||
<span class="fs14 c-gray-dark ml20">{{ item02.getCount }}</span>
|
||||
</div>
|
||||
<div class="pb10 pt10 border-gb">
|
||||
<div class="w130 inline-b">上一次支付失败原因:</div>
|
||||
<span class="fs14 c-gray-dark ml20">{{ item02.lastFailReason }}</span>
|
||||
</div>
|
||||
<div class="pb10 pt10 border-gb">
|
||||
<div class="w130 inline-b">上一次支付失败日期:</div>
|
||||
<span class="fs14 c-gray-dark ml20">{{ item02.lastFailDate }}</span>
|
||||
</div>
|
||||
</div>
|
||||
</van-collapse-item>
|
||||
</van-collapse>
|
||||
</div>
|
||||
</div>
|
||||
@@ -140,7 +137,7 @@ export default {
|
||||
window.appCallBack = this.appCallBack
|
||||
},
|
||||
methods: {
|
||||
checkBtn() {
|
||||
checkBtn() {
|
||||
let title = this.isOpen == '1' ? '全部收起' : '全部展开'
|
||||
this.$jump({
|
||||
flag: 'webview_right_button',
|
||||
@@ -248,64 +245,6 @@ export default {
|
||||
that.$forceUpdate()
|
||||
console.log(this.claimApprovalIds,'claimApprovalIds')
|
||||
},
|
||||
checkBoxClick(){
|
||||
// ev.stopPropagation();
|
||||
let that = this
|
||||
this.claimApprovalIds= []
|
||||
//非全选状态时,更新claimApprovalIds数组
|
||||
this.claimApprovalList.forEach(function(item) {
|
||||
that.claimApprovalIds = that.claimApprovalIds.concat(item.checkboxResult)
|
||||
})
|
||||
that.$forceUpdate()
|
||||
if(that.claimApprovalIds.length){
|
||||
that.getTotalMoneyFunc()
|
||||
}
|
||||
//审批弹框点击取消之后,操作checkbox或全选时,统计通过、拒绝按钮数量
|
||||
// 按钮状态 0通过 1拒绝
|
||||
if(this.btnStatus == 0){
|
||||
this.refuseNum = 0
|
||||
this.passNum = this.claimApprovalIds.length
|
||||
}else if(this.btnStatus == 1){
|
||||
this.refuseNum = this.claimApprovalIds.length
|
||||
this.passNum = 0
|
||||
}
|
||||
console.log(this.claimApprovalIds,'claimApprovalIds')
|
||||
},
|
||||
//全选
|
||||
checkAllFunc() {
|
||||
let that = this
|
||||
if(that.claimApprovalIds.length != that.total){
|
||||
this.claimApprovalIds= []
|
||||
this.claimApprovalList.forEach(function(item) {
|
||||
item.checkboxResult = []
|
||||
let arr = []
|
||||
item.claimApprovalSearchLst.forEach(function(item01) {
|
||||
arr.push(item01.id)
|
||||
that.claimApprovalIds.push(item01.id)
|
||||
})
|
||||
item.checkboxResult = arr
|
||||
})
|
||||
that.getTotalMoneyFunc()
|
||||
}else{ //取消全选
|
||||
this.claimApprovalIds= []
|
||||
this.claimApprovalList.forEach(function(item) {
|
||||
item.checkboxResult = []
|
||||
let arr = []
|
||||
item.checkboxResult = arr
|
||||
})
|
||||
that.totalMoney = 0
|
||||
}
|
||||
//审批弹框点击取消之后,操作checkbox或全选时,统计通过、拒绝按钮数量
|
||||
// 按钮状态 0通过 1拒绝
|
||||
if(this.btnStatus == 0){
|
||||
this.refuseNum = 0
|
||||
this.passNum = this.claimApprovalIds.length
|
||||
}else if(this.btnStatus == 1){
|
||||
this.refuseNum = this.claimApprovalIds.length
|
||||
this.passNum = 0
|
||||
}
|
||||
that.$forceUpdate()
|
||||
},
|
||||
//通过按钮
|
||||
passHandle(){
|
||||
if(this.claimApprovalIds.length){
|
||||
@@ -341,8 +280,11 @@ export default {
|
||||
}).then(() => {
|
||||
claimApproval({claimApprovalIds:this.claimApprovalIds,approvalResult:approvalResult}).then(res => {
|
||||
if (res.result == '0') {
|
||||
that.getList()
|
||||
} else {
|
||||
that.getList()
|
||||
} else if(res.result == '2') { //当前数据正在审批中,请稍后再试--刷新数据
|
||||
that.getList()
|
||||
this.$toast(res.resultMessage)
|
||||
}else{
|
||||
this.$toast(res.resultMessage)
|
||||
}
|
||||
})
|
||||
@@ -350,8 +292,13 @@ export default {
|
||||
},
|
||||
//审批记录--切换1已通过,0未通过按钮状态
|
||||
approvalRecordSwitch(plainStatus){
|
||||
this.getList(plainStatus)
|
||||
this.plainStatus = plainStatus
|
||||
let that = this
|
||||
this.getList(plainStatus)
|
||||
this.plainStatus = plainStatus
|
||||
//切换tab时,需要重置右上角的按钮状态--全部展开
|
||||
that.activeNames = []
|
||||
that.isOpen = 0 //右上角按钮状态 0 全部收起 1 全部展开
|
||||
that.checkBtn() // 初始化显示按钮
|
||||
},
|
||||
//初始化列表
|
||||
async getList(plainStatus) {
|
||||
@@ -415,6 +362,7 @@ export default {
|
||||
})
|
||||
},
|
||||
tabChange(name) {
|
||||
let that = this
|
||||
this.currentPage = 1
|
||||
this.active = name
|
||||
this.claimApprovalList = []
|
||||
@@ -425,6 +373,10 @@ export default {
|
||||
}else{
|
||||
this.getList()
|
||||
}
|
||||
//切换tab时,需要重置右上角的按钮状态--全部展开
|
||||
that.activeNames = []
|
||||
that.isOpen = 0 //右上角按钮状态 0 全部收起 1 全部展开
|
||||
that.checkBtn() // 初始化显示按钮
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user