Compare commits

...

5 Commits

Author SHA1 Message Date
liu.xiaofeng@ebiz-digits.com
55f430d9d2 上传附件页面关于图片删除逻辑代码修改 2023-07-20 10:36:04 +08:00
liu.xiaofeng@ebiz-digits.com
1040189bd4 上传附件图片上传失败增加提示以及响应图片集合清空 2023-07-19 15:34:44 +08:00
liu.xiaofeng@ebiz-digits.com
6c24848ef5 上传附件如果是身份证的话提前做ocr识别如果识别不过的话需要重新上传逻辑修改 2023-07-19 15:26:23 +08:00
liu.xiaofeng@ebiz-digits.com
a7b6b835ba 上传附件代码逻辑修改 2023-07-19 14:16:51 +08:00
liu.xiaofeng@ebiz-digits.com
60a4e2d954 上传附件重复添加同一类型的附件删除原附件 2023-07-10 15:46:26 +08:00

View File

@@ -9,15 +9,7 @@
<van-field required label="银行卡账户" disabled />
</van-cell-group>
<div @click="test('fileListBank', saleInsuredInfo.idType)">
<van-uploader
name="fileListBank"
v-model="fileListBank"
:after-read="afterRead"
@delete="deleteImg"
:before-delete="beforeDelete"
class="mt10 ml20"
:max-count="1"
/>
<van-uploader name="fileListBank" v-model="fileListBank" :after-read="afterRead" @delete="deleteImg" :before-delete="beforeDelete" class="mt10 ml20" :max-count="1"/>
</div>
</div>
<div v-else>
@@ -35,29 +27,13 @@
<van-field required :label="item.id == '2' ? `${item.text}户主页` : `${item.text}正面`" disabled />
</van-cell-group>
<div @click="test('fileListIdFront', saleInsuredInfo.idType)" class="flex align-items-e">
<van-uploader
name="fileListIdFront"
v-model="fileListIdFront"
:after-read="afterRead"
:before-delete="beforeDelete"
class="mt10 ml20"
:max-count="1"
@delete="deleteImg"
/>
<van-uploader name="fileListIdFront" v-model="fileListIdFront" :after-read="afterRead" :before-delete="beforeDelete" class="mt10 ml20" :max-count="1" @delete="deleteImg"/>
</div>
<van-cell-group>
<van-field required :label="item.id == '2' ? `${item.text}本人页` : `${item.text}反面`" disabled />
</van-cell-group>
<div @click="test('fileListIdBack', saleInsuredInfo.idType)">
<van-uploader
name="fileListIdBack"
v-model="fileListIdBack"
:after-read="afterRead"
@delete="deleteImg"
:before-delete="beforeDelete"
class="mt10 ml20"
:max-count="1"
/>
<van-uploader name="fileListIdBack" v-model="fileListIdBack" :after-read="afterRead" @delete="deleteImg" :before-delete="beforeDelete" class="mt10 ml20" :max-count="1"/>
</div>
</div>
<div v-if="item.id == '4'">
@@ -65,109 +41,23 @@
<van-field required :label="`${item.text}头像面`" disabled />
</van-cell-group>
<div @click="test('fileLIstImg', saleInsuredInfo.idType)">
<van-uploader
name="fileLIstImg"
v-model="fileLIstImg"
:after-read="afterRead"
@delete="deleteImg"
:before-delete="beforeDelete"
class="mt10 ml20"
:max-count="1"
/>
<van-uploader name="fileLIstImg" v-model="fileLIstImg" :after-read="afterRead" @delete="deleteImg" :before-delete="beforeDelete" class="mt10 ml20" :max-count="1"/>
</div>
</div>
<!-- <div v-if="item.id == '3' || item.id == '4'">
<van-cell-group>
<van-field required :label="item.id == '3' ? `${item.text}` : `${item.text}本人照片页`" disabled />
</van-cell-group>
<div @click="test('fileLIstImg', saleInsuredInfo.idType)">
<van-uploader
name="fileLIstImg"
v-model="fileLIstImg"
:after-read="afterRead"
@delete="deleteImg"
:before-delete="beforeDelete"
class="mt10 ml20"
:max-count="1"
/>
</div>
</div> -->
<!-- <div v-if="item.id == '5' || item.id == '6'">
<van-cell-group>
<van-field required :label="`${item.text}头像面`" disabled />
</van-cell-group>
<div @click="test('fileLIstImg', saleInsuredInfo.idType)">
<van-uploader
name="fileLIstImg"
v-model="fileLIstImg"
:after-read="afterRead"
@delete="deleteImg"
:before-delete="beforeDelete"
class="mt10 ml20"
:max-count="1"
/>
</div>
</div> -->
<!-- <div v-if="item.id == '7'">
<van-cell-group>
<van-field required :label="item.text" disabled />
</van-cell-group>
<div @click="test('saleInsuredInfoOther', saleInsuredInfo.idType)">
<van-uploader
name="saleInsuredInfoOther"
v-model="saleInsuredInfoOther"
:after-read="afterRead"
@delete="deleteImg"
:before-delete="beforeDelete"
class="mt10 ml20"
:max-count="1"
/>
</div>
</div> -->
</div>
</div>
<van-cell-group>
<van-field required label="银行卡正面" disabled />
</van-cell-group>
<div @click="test('fileListBank', saleInsuredInfo.idType)">
<van-uploader
name="fileListBank"
v-model="fileListBank"
:after-read="afterRead"
@delete="deleteImg"
:before-delete="beforeDelete"
class="mt10 ml20"
:max-count="1"
/>
<van-uploader name="fileListBank" v-model="fileListBank" :after-read="afterRead" @delete="deleteImg" :before-delete="beforeDelete" class="mt10 ml20" :max-count="1"/>
</div>
<van-cell-group v-if="isNotify">
<van-field label="健康告知异常类资料" disabled />
</van-cell-group>
<div v-if="isNotify" @click="test('fileListNotify', saleInsuredInfo.idType)">
<van-uploader
name="fileListNotify"
v-model="fileListNotify"
:after-read="afterRead"
@delete="deleteImg"
:before-delete="beforeDelete"
class="mt10 ml20"
:max-count="20"
/>
<van-uploader name="fileListNotify" v-model="fileListNotify" :after-read="afterRead" @delete="deleteImg" :before-delete="beforeDelete" class="mt10 ml20" :max-count="20"/>
</div>
<!-- <van-cell-group>
<van-field required label="银行卡反面" disabled />
</van-cell-group>
<div @click="test('fileListBankBack', saleInsuredInfo.idType)">
<van-uploader
name="fileListBankBack"
v-model="fileListBankBack"
:after-read="afterRead"
@delete="deleteImg"
:before-delete="beforeDelete"
class="mt10 ml20"
:max-count="1"
/>
</div> -->
</div>
</div>
</div>
@@ -185,29 +75,13 @@
<van-field required :label="item.id == '2' ? `${item.text}户主页` : `${item.text}正面`" disabled />
</van-cell-group>
<div @click="test('fileListIdFrontInsured', saleInsuredPersonInfo.idType)">
<van-uploader
name="fileListIdFrontInsured"
v-model="fileListIdFrontInsured"
:after-read="afterRead"
:before-delete="beforeDelete"
@delete="deleteImg"
class="mt10 ml20"
:max-count="1"
/>
<van-uploader name="fileListIdFrontInsured" v-model="fileListIdFrontInsured" :after-read="afterRead" :before-delete="beforeDelete" @delete="deleteImg" class="mt10 ml20" :max-count="1"/>
</div>
<van-cell-group>
<van-field required :label="item.id == '2' ? `${item.text}本人页` : `${item.text}反面`" disabled />
</van-cell-group>
<div @click="test('fileListIdBackInsured', saleInsuredPersonInfo.idType)">
<van-uploader
name="fileListIdBackInsured"
v-model="fileListIdBackInsured"
:after-read="afterRead"
:before-delete="beforeDelete"
@delete="deleteImg"
class="mt10 ml20"
:max-count="1"
/>
<van-uploader name="fileListIdBackInsured" v-model="fileListIdBackInsured" :after-read="afterRead" :before-delete="beforeDelete" @delete="deleteImg" class="mt10 ml20" :max-count="1"/>
</div>
</div>
<div v-if="item.id == '4'">
@@ -215,15 +89,7 @@
<van-field required :label="`${item.text}头像页`" disabled />
</van-cell-group>
<div @click="test('fileLIstImgInsured', saleInsuredPersonInfo.idType)">
<van-uploader
name="fileLIstImgInsured"
v-model="fileLIstImgInsured"
:after-read="afterRead"
:before-delete="beforeDelete"
@delete="deleteImg"
class="mt10 ml20"
:max-count="1"
/>
<van-uploader name="fileLIstImgInsured" v-model="fileLIstImgInsured" :after-read="afterRead" :before-delete="beforeDelete" @delete="deleteImg" class="mt10 ml20" :max-count="1"/>
</div>
</div>
</div>
@@ -232,44 +98,12 @@
<van-field label="健康告知异常类资料" disabled />
</van-cell-group>
<div v-if="isNotifyInsured" @click="test('fileListNotifyInsured', saleInsuredInfo.idType)">
<van-uploader
name="fileListNotifyInsured"
v-model="fileListNotifyInsured"
:after-read="afterRead"
@delete="deleteImg"
:before-delete="beforeDelete"
class="mt10 ml20"
:max-count="20"
/>
<van-uploader name="fileListNotifyInsured" v-model="fileListNotifyInsured" :after-read="afterRead" @delete="deleteImg" :before-delete="beforeDelete" class="mt10 ml20" :max-count="20"/>
</div>
</div>
</div>
</div>
</div>
<!-- <div>
<div class="flex p10 align-items-c bg-white mt10">
<span>请点击+上传健康告知异常类资料</span>
</div>
<div class="m20 bg-white">
<div class="p10">
<van-cell-group>
<van-field required label="健康告知异常类资料" disabled />
</van-cell-group>
<div @click="test('fileListNotify')">
<van-uploader
name="fileListNotify"
v-model="fileListNotify"
:after-read="afterRead"
@delete="deleteImg"
:before-delete="beforeDelete"
class="mt10 ml20"
:max-count="1"
/>
</div>
</div>
</div>
</div> -->
<!-- 受益人类型 -->
<div v-if="saleBtnfPersonInfo">
<div class="flex bg-white p10 align-items-c">
@@ -284,29 +118,13 @@
<van-field required :label="item.id == '2' ? `${item01.name}+${item.text}户主页` : `${item01.name}+${item.text}正面`" disabled />
</van-cell-group>
<div @click="test('fileListIdFrontBeneficiary', item01.idType, item01.bnfId)">
<van-uploader
:name="'fileListIdFrontBeneficiary'+index01"
v-model="bnfInfo[index01].fileListIdFrontBeneficiary"
:after-read="afterRead"
:before-delete="beforeDelete"
@delete="deleteImg"
class="mt10 ml20"
:max-count="1"
/>
<van-uploader :name="'fileListIdFrontBeneficiary'+index01" v-model="bnfInfo[index01].fileListIdFrontBeneficiary" :after-read="afterRead" :before-delete="beforeDelete" @delete="deleteImg" class="mt10 ml20" :max-count="1"/>
</div>
<van-cell-group>
<van-field required :label="item.id == '2' ? `${item01.name}+${item.text}本人页` : `${item01.name}+${item.text}反面`" disabled />
</van-cell-group>
<div @click="test('fileListIdBackBeneficiary', item01.idType, item01.bnfId)">
<van-uploader
:name="'fileListIdBackBeneficiary'+index01"
v-model="bnfInfo[index01].fileListIdBackBeneficiary"
:after-read="afterRead"
:before-delete="beforeDelete"
@delete="deleteImg"
class="mt10 ml20"
:max-count="1"
/>
<van-uploader :name="'fileListIdBackBeneficiary'+index01" v-model="bnfInfo[index01].fileListIdBackBeneficiary" :after-read="afterRead" :before-delete="beforeDelete" @delete="deleteImg" class="mt10 ml20" :max-count="1"/>
</div>
</div>
<div v-if="item.id == '4'">
@@ -314,15 +132,7 @@
<van-field required :label="`${item01.name}+${item.text}头像页`" disabled />
</van-cell-group>
<div @click="test('fileLIstImgBeneficiary', item01.idType, item01.bnfId)">
<van-uploader
:name="'fileLIstImgBeneficiary'+index01"
v-model="bnfInfo[index01].fileLIstImgBeneficiary"
:after-read="afterRead"
:before-delete="beforeDelete"
@delete="deleteImg"
class="mt10 ml20"
:max-count="1"
/>
<van-uploader :name="'fileLIstImgBeneficiary'+index01" v-model="bnfInfo[index01].fileLIstImgBeneficiary" :after-read="afterRead" :before-delete="beforeDelete" @delete="deleteImg" class="mt10 ml20" :max-count="1"/>
</div>
</div>
</div>
@@ -330,65 +140,6 @@
</div>
</div>
</div>
<!-- <div v-if="typebeneficiary == true">
<div class="flex bg-white p10 align-items-c">
<span>受益人附件</span>
</div>
<div class="m20 bg-white">
<van-cell-group>
<van-field required label="受益人附件上传" disabled />
</van-cell-group>
<div @click="test('fileListtypebeneficiary', saleInsuredPersonInfo.idType)" class="flex">
<van-uploader
name="fileListtypebeneficiary"
v-model="fileListtypebeneficiary"
:after-read="afterRead"
:before-delete="beforeDelete"
@delete="deleteImg"
class="mt10 ml20"
:max-count="9"
/>
</div>
</div>
</div> -->
<!-- 受益人类型end -->
<!-- <div> -->
<!-- <div class="flex bg-white p10 align-items-c"> -->
<!-- <div class="attachmentManagement-block"></div> -->
<!-- <span>其他</span>
</div> -->
<!-- <div class="m20 bg-white">
<div @click="test('fileListOther', saleInsuredPersonInfo.idType)" class="flex">
<van-uploader
name="fileListOtherOne"
v-model="fileListOtherOne"
:after-read="afterRead"
:before-delete="beforeDelete"
@delete="deleteImg"
class="mt10 ml20"
:max-count="1"
/>
<van-uploader
name="fileListOtherTwo"
v-model="fileListOtherTwo"
:after-read="afterRead"
:before-delete="beforeDelete"
@delete="deleteImg"
class="mt10 ml20"
:max-count="1"
/>
<van-uploader
name="fileListOtherThree"
v-model="fileListOtherThree"
:after-read="afterRead"
:before-delete="beforeDelete"
@delete="deleteImg"
class="mt10 ml20"
:max-count="1"
/>
</div>
</div>
</div> -->
</div>
<div class="ml30 mt30 mb80">
<van-radio-group v-model="radio">
@@ -396,16 +147,9 @@
</van-radio-group>
</div>
<div class="bg-white bottom-btn">
<van-button
type="danger"
class="attachmentManagement-next"
size="large"
:disabled="!(isDisabled == false && isDisabledBnf == false)"
@click="next"
@touchstart="beforeNext(isDisabled)"
v-no-more-click="1000"
>下一步</van-button
>
<van-button type="danger" class="attachmentManagement-next" size="large" :disabled="!(isDisabled == false && isDisabledBnf == false)" @click="next" @touchstart="beforeNext(isDisabled)" v-no-more-click="1000">
下一步
</van-button>
</div>
</div>
</template>
@@ -805,10 +549,8 @@ export default {
})
}
},
// 删除图片前
beforeDelete(file, detail) {
let that = this
Dialog.confirm({
title: '提示',
message: '您确定要删除吗',
@@ -825,8 +567,6 @@ export default {
} else if (detail.name == 'fileListBank') {
this.fileListBank = []
this.deleteImg(file, 'fileListBank')
// } else if (detail.name == 'fileListBankBack') {
// this.fileListBankBack = []
} else if (detail.name == 'fileListIdFrontInsured') {
this.fileListIdFrontInsured = []
this.deleteImg(file, 'fileListIdFrontInsured')
@@ -839,26 +579,12 @@ export default {
} else if (detail.name == 'fileLIstImgInsured') {
this.fileLIstImgInsured = []
this.deleteImg(file, 'fileLIstImgInsured')
// } else if (detail.name == 'fileListOtherOne') {
// this.fileListOtherOne = []
// } else if (detail.name == 'fileListOtherTwo') {
// this.fileListOtherTwo = []
// } else if (detail.name == 'fileListOtherThree') {
// this.fileListOtherThree = []
} else if (detail.name == 'saleInsuredInfoOther') {
this.saleInsuredInfoOther = []
this.deleteImg(file, 'saleInsuredInfoOther')
} else if (detail.name == 'saleInsuredPersonInfoOther') {
this.saleInsuredPersonInfoOther = []
this.deleteImg(file, 'saleInsuredPersonInfoOther')
// } else if (detail.name == 'fileListtypebeneficiary') {
// that.fileListtypebeneficiary.map((item, index, array) => {
// if (item.content == file.content) {
// array.splice(index, 1)
// } else {
// return
// }
// })
} else if (detail.name.indexOf('fileListIdFrontBeneficiary') != -1) {
//单独处理受益人影像删除通过name值查询到当前收益指的索引值下标操作data数据中定义的数据
let detailIndex = detail.name.substring(26,detail.name.length)
@@ -965,22 +691,19 @@ export default {
// 删除图片
deleteImg(file, nameList) {
let that = this
that.list.map((item, index, array) => {
// if (item.fileName.indexOf(file.file.name) == -1) {
// return
// } else {
// array.splice(index, 1)
// }
debugger
that.list.forEach((item, index) => {
if (item.fileName == file.name && nameList == item.name) {
array.splice(index, 1)
that.list.splice(index, 1)
}
//单独处理受益人影像删除通过bnfId查询到删除某条数据
if(nameList == 'fileListIdFrontBeneficiary' || nameList == 'fileListIdBackBeneficiary' || nameList == 'fileLIstImgBeneficiary'){
if (item.fileName == file.name && item.subBusinessNo == that.bnfId) {
array.splice(index, 1)
that.list.splice(index, 1)
}
}
})
debugger
},
afterRead(file) {
let that = this
@@ -1018,53 +741,20 @@ export default {
let that = this
this.$toast.loading({
duration: 0, // 持续展示 toast
forbidClick: true, // 禁用背景点击
loadingType: 'spinner',
message: '加载中……',
})
let formdata = new FormData()
formdata.append('imgPath', that.dataURLtoFile(that.file, that.imgName))
uploadImg(formdata).then(
(res) => {
// console.log(res)
if (res.result == '0') {
this.$toast.clear()
if(res.path){
if (
that.type == 'fileListIdFront' ||
that.type == 'fileListIdBack' ||
that.type == 'fileLIstImg' ||
that.type == 'fileListBank' ||
// that.type == 'fileListBankBack' ||
that.type == 'fileListNotify' ||
that.type == 'saleInsuredInfoOther'
) {
if(res.result == 0 && res.path){
if (that.type == 'fileListIdFront' || that.type == 'fileListIdBack' || that.type == 'fileLIstImg' || that.type == 'fileListBank' || that.type == 'fileListNotify' || that.type == 'saleInsuredInfoOther') {
let imageInfoType = ''
let name = ''
// if (that.type == 'fileListIdFront' && that.id == '1') {
// imageInfoType = '1'
// } else if (that.type == 'fileListIdBack' && that.id == '1') {
// imageInfoType = '2'
// } else if (that.type == 'fileListBank') {
// imageInfoType = '3'
// } else if (that.type == 'fileListIdFront' && that.id == '2') {
// imageInfoType = '5'
// } else if (that.type == 'fileListIdBack' && that.id == '2') {
// imageInfoType = '6'
// } else if (that.type == 'fileLIstImg' && that.id == '3') {
// imageInfoType = '7'
// } else if (that.type == 'fileLIstImg' && that.id == '4') {
// imageInfoType = '8'
// } else if (that.type == 'fileLIstImg' && that.id == '5') {
// imageInfoType = '9'
// } else if (that.type == 'fileLIstImg' && that.id == '6') {
// imageInfoType = '10'
// } else if (that.type == 'saleInsuredInfoOther' && that.id == '7') {
// imageInfoType = '11'
// }
if (that.type == 'fileListIdFront' && that.id == '1') {
//身份证正面
name = 'fileListIdFront'
@@ -1129,40 +819,28 @@ export default {
//银行卡正面
name = 'fileListBank'
imageInfoType = '3'
// } else if (that.type == 'fileListBankBack') {
// //银行卡反面
// imageInfoType = '19'
} else if (that.type == 'fileListNotify') {
name = 'fileListNotify'
imageInfoType = '24'
}
this.imageType = imageInfoType
let obj = {
name: name,
businessNo: that.orderNo,
businessType: '',
imageInfoType: imageInfoType,
// window.localStorage.setItem('bankCardUrlInsuredPath', encodeURI(JSON.parse(data).path).replace(/\+/g, '%2B'))
rgssUrl: encodeURI(res.path).replace(/\+/g, '%2B'),
subBusinessType: '0',
subBusinessNo: that.saleInsuredInfo.appntId,
fileName: that.imgName,
}
this.imageType = imageInfoType
that.list.push(obj)
} else if (
that.type == 'fileListIdFrontInsured' ||
that.type == 'fileListIdBackInsured' ||
that.type == 'fileListBankInsured' ||
that.type == 'fileLIstImgInsured' ||
that.type == 'fileListNotifyInsured' ||
that.type == 'saleInsuredPersonInfoOther'
) {
}
else if (that.type == 'fileListIdFrontInsured' || that.type == 'fileListIdBackInsured' || that.type == 'fileListBankInsured' || that.type == 'fileLIstImgInsured' || that.type == 'fileListNotifyInsured' || that.type == 'saleInsuredPersonInfoOther') {
// 是被保险人
// 证件类型
let imageInfoType = ''
let name = ''
if (that.type == 'fileListIdFrontInsured' && that.id == '1') {
name = 'fileListIdFrontInsured'
imageInfoType = '1'
@@ -1212,7 +890,7 @@ export default {
name = 'fileListNotifyInsured'
imageInfoType = '24'
}
this.imageType = imageInfoType
let obj = {
name: name,
businessNo: that.orderNo,
@@ -1223,16 +901,11 @@ export default {
subBusinessNo: that.saleInsuredPersonInfo.insuredId,
fileName: that.imgName,
}
this.imageType = imageInfoType
that.list.push(obj)
} else if (
that.type == 'fileListIdFrontBeneficiary' ||
that.type == 'fileListIdBackBeneficiary' ||
that.type == 'fileLIstImgBeneficiary'
) {
}
else if (that.type == 'fileListIdFrontBeneficiary' || that.type == 'fileListIdBackBeneficiary' || that.type == 'fileLIstImgBeneficiary') {
// 是收益人
// 证件类型
let imageInfoType = ''
let name = ''
@@ -1282,7 +955,7 @@ export default {
name = 'fileListIdBackBeneficiary'
imageInfoType = '18'
}
this.imageType = imageInfoType
let obj = {
name: name,
businessNo: that.orderNo,
@@ -1293,9 +966,9 @@ export default {
subBusinessNo: that.bnfId,
fileName: that.imgName,
}
this.imageType = imageInfoType
that.list.push(obj)
} else if (that.type == 'fileListOther') {
}
else if (that.type == 'fileListOther') {
// 是其他
let type = '2'
let name = 'fileListOther'
@@ -1309,37 +982,9 @@ export default {
subBusinessNo: '',
fileName: that.imgName,
}
that.list.push(obj)
// } else if (that.type == 'fileListtypebeneficiary') {
// // 是受益人
// let type = '3'
// let obj = {
// businessNo: that.orderNo,
// businessType: '',
// imageInfoType: '21',
// rgssUrl: encodeURI(res.path).replace(/\+/g, '%2B'),
// subBusinessType: type,
// subBusinessNo: '',
// fileName: that.imgName
// }
// that.list.push(obj)
} else if (that.type == 'fileListNotify') {
// 健康告知异常类资料
// let obj = {
// name: 'fileListNotify',
// businessNo: that.orderNo,
// businessType: '',
// imageInfoType: '24',
// rgssUrl: encodeURI(res.path).replace(/\+/g, '%2B'),
// subBusinessType: '0',
// subBusinessNo: '',
// fileName: that.imgName,
// }
// that.list.push(obj)
}
let imgPath = res.path
//只有身份证件才进行ocr校验
if(that.type == 'fileListIdFront' || that.type == 'fileListIdBack' || that.type == 'fileLIstImg' ||
@@ -1368,7 +1013,8 @@ export default {
this.IDCardOCRValite(that.id, this.orderNo, imgPath, "OTHER", '')
}
}
}else{
}
else{
switch (that.type) {
case 'fileListIdFront':
that.fileListIdFront = []
@@ -1427,7 +1073,8 @@ export default {
}
this.$toast.clear()
}
} else {
}
else {
switch (that.type) {
case 'fileListIdFront':
that.fileListIdFront = []
@@ -1575,7 +1222,6 @@ export default {
this.$toast('请勾选确认销售人员已见证各证件原件并拍照上传')
}
},
IDCardOCRValite(idType, orderNo, imgPath, cardSide, flag){
let param = {
idType : idType,
@@ -1596,11 +1242,7 @@ export default {
if('appentFront' == flag){
this.saleInsuredInfo.sex = this.saleInsuredInfo.sex == '0'? '男' :'女'
res.content.birth = utils.formatDate(Date.parse(res.content.birth), 'yyyy-MM-dd')
if(this.saleInsuredInfo.name != res.content.name ||
this.saleInsuredInfo.sex != res.content.sex ||
this.saleInsuredInfo.birthday != res.content.birth ||
this.saleInsuredInfo.idNo != res.content.idNum
){
if(this.saleInsuredInfo.name != res.content.name || this.saleInsuredInfo.sex != res.content.sex || this.saleInsuredInfo.birthday != res.content.birth || this.saleInsuredInfo.idNo != res.content.idNum){
isFlag = false;
}
}
@@ -1625,11 +1267,7 @@ export default {
this.saleInsuredPersonInfo.sex = this.saleInsuredPersonInfo.sex == '0'? '男' :'女'
res.content.birth = utils.formatDate(Date.parse(res.content.birth), 'yyyy-MM-dd')
//被保人身份证正面
if(this.saleInsuredPersonInfo.name != res.content.name ||
this.saleInsuredPersonInfo.sex != res.content.sex ||
this.saleInsuredPersonInfo.birthday != res.content.birth ||
this.saleInsuredPersonInfo.idNo != res.content.idNum
){
if(this.saleInsuredPersonInfo.name != res.content.name || this.saleInsuredPersonInfo.sex != res.content.sex || this.saleInsuredPersonInfo.birthday != res.content.birth || this.saleInsuredPersonInfo.idNo != res.content.idNum){
isFlag = false;
}
}else if('insuredBack' == flag){
@@ -1653,11 +1291,7 @@ export default {
this.saleBtnfPersonInfo.sex = this.saleBtnfPersonInfo.sex == '0'? '男' :'女'
res.content.birth = utils.formatDate(Date.parse(res.content.birth), 'yyyy-MM-dd')
//受益人身份证正面
if(this.saleBtnfPersonInfo.name != res.content.name ||
this.saleBtnfPersonInfo.sex != res.content.sex ||
this.saleBtnfPersonInfo.birthday != res.content.birth ||
this.saleBtnfPersonInfo.idNo != res.content.idNum
){
if(this.saleBtnfPersonInfo.name != res.content.name || this.saleBtnfPersonInfo.sex != res.content.sex || this.saleBtnfPersonInfo.birthday != res.content.birth || this.saleBtnfPersonInfo.idNo != res.content.idNum){
isFlag = false;
}
}else if('beneficiaryBack' == flag){
@@ -1688,41 +1322,9 @@ export default {
}
});
},
// 点击下一步
next() {
console.log(888)
let that = this
// this.$toast.loading({
// duration: 0, // 持续展示 toast
// forbidClick: true, // 禁用背景点击
// loadingType: 'spinner',
// message: '加载中……'
// })
//注释双录提示
// let request = {
// productList: JSON.parse(localStorage.chooseProductCodes),
// // productList: ["DCRS_A0009"],
// birthday: this.saleInsuredInfo.birthday
// }
// check(request).then(res => {
// if (res.result == '0') {
// if (res.status == '0') {
// // 弹
// window.localStorage.setItem('attachmentShow', '0')
// } else {
// // 不弹
// window.localStorage.setItem('attachmentShow', '1')
// }
// } else {
// // 不弹
// window.localStorage.setItem('attachmentShow', '1')
// }
// })
// delete that.list.fileName
that.list.map((i) => {
delete i.name
})
@@ -1739,7 +1341,8 @@ export default {
},
orderType: that.changeCard ? 'MEDIANEW_ORDER' : 'MEDIA_ORDER',
}
console.log(data)
return
saveInformation(data).then((res) => {
if (res.result == '0') {
this.$toast.clear()
@@ -1777,13 +1380,11 @@ export default {
confirmButtonColor:'#FF0000',
showCancelButton:false
})
//that.$toast(res.resultMessage)
}
})
},
},
computed: {
// eslint-disable-next-line vue/return-in-computed-property
typebeneficiary() {
// 1.趸交保费≥20万元或期交保费*总期数≥20万元时
// 2.指定受益人
@@ -1957,11 +1558,6 @@ export default {
) {
//去掉收益人添加的,有收益人删掉该行显示下面影藏判断
that.isDisabled = false
// if ((that.typebeneficiary && val.fileListtypebeneficiary.length != '0') || (!that.typebeneficiary && val.fileListtypebeneficiary.length == '0')) {
// that.isDisabled = false
// } else {
// that.isDisabled = true
// }
} else {
that.isDisabled = true
}