mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-19 13:46:44 +08:00
Merge branch 'master' into feature/GFRS-1020【0521】国富人寿附加豁免保险费重大疾病保险关连3款主险产品
This commit is contained in:
@@ -194,3 +194,4 @@ export function getPayState(data) {
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
@@ -931,6 +931,11 @@ export default {
|
||||
shortName: '寿险',
|
||||
name: '国富人寿国富栋梁定期寿险',
|
||||
code: 'GFRS_M0020'
|
||||
},
|
||||
{
|
||||
shortName: '重疾险',
|
||||
name: '国富人寿爱易保重大疾病保险',
|
||||
code: 'GFRS_M0021'
|
||||
}
|
||||
],
|
||||
// 职级
|
||||
|
||||
@@ -1,35 +1,59 @@
|
||||
<template>
|
||||
<div class="occupation pb70">
|
||||
<van-search v-model="searchParams" placeholder="请输入搜索关键词" show-action shape="round" @clear="clearSearch" @search="onSearch">
|
||||
<van-search v-model="searchParams" @input="onSearch" placeholder="请输入搜索关键词" show-action shape="round" @clear="clearSearch" @search="onSearch">
|
||||
<div slot="action" @click="onSearch">搜索</div>
|
||||
</van-search>
|
||||
<div class="main-area fs12">
|
||||
<div class="item p10">
|
||||
<p class="p5" v-for="(item, index) in occupationList" :key="index" @click="handleFirst(item)" :class="{ active: first.code == item.code }">
|
||||
{{ item.name }}
|
||||
</p>
|
||||
<div class="choose-result fs12 pl25" v-if="third.code">
|
||||
<p>职业代码:{{ third.code }}</p>
|
||||
<p>职业:{{ chooseName }}</p>
|
||||
</div>
|
||||
<div>
|
||||
<div :class="[isSearch ? 'hidden' : '']">
|
||||
<p class="fs14 pl20 fwb pv5">常用职业</p>
|
||||
<div class="common-occupation flex flex-wrap fs12 ph25">
|
||||
<div v-for="(item, index) in commonList" @click="commonChoose(item, index)" :key="index" :class="[item.isActive ? 'active' : '', 'fwb']">
|
||||
{{ item.name }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="item p10">
|
||||
<p class="p5" v-for="(item, index) in sec" :key="index" @click="handleSec(item)" :class="{ active: second.code == item.code }">
|
||||
{{ item.name }}
|
||||
</p>
|
||||
<div :class="[isSearch ? 'hidden' : '']">
|
||||
<p class="fs14 pl20 fwb pv5">全部职业</p>
|
||||
<div class="main-area fs12 ph10 pb20">
|
||||
<div class="item ph10">
|
||||
<p class="p5" v-for="(item, index) in occupationList" :key="index" @click="handleFirst(item)" :class="{ active: first.code == item.code }">
|
||||
{{ item.name }}
|
||||
</p>
|
||||
</div>
|
||||
<div class="item ph10">
|
||||
<p class="p5" v-for="(item, index) in sec" :key="index" @click="handleSec(item)" :class="{ active: second.code == item.code }">
|
||||
{{ item.name }}
|
||||
</p>
|
||||
</div>
|
||||
<div class="item ph10">
|
||||
<p class="p5" v-for="(item, index) in thi" :key="index" @click="handleThi(item)" :class="{ active: third.code == item.code }">
|
||||
{{ item.name }}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="item p10">
|
||||
<p class="p5" v-for="(item, index) in thi" :key="index" @click="handleThi(item)" :class="{ active: third.code == item.code }">
|
||||
{{ item.name }}
|
||||
</p>
|
||||
</div>
|
||||
<div v-if="third.code" class="choose-result">
|
||||
<p>职业代码:{{ third.code }}</p>
|
||||
<p>职业:{{ chooseName }}</p>
|
||||
<div :class="[isSearch ? '' : 'hidden']">
|
||||
<p class="fs14 pl20 fwb pv5">搜索结果</p>
|
||||
<div class="item p10 search-result fs14 flex flex-direction-colunm">
|
||||
<p class="p5 mv5" :class="[item.isActive ? 'active' : '']" v-for="(item, index) in searchList" @click="searchChoose(item, index)" :key="index">
|
||||
<span v-html="item.showName.replace(new RegExp(searchParams, 'g'), `<span class="red">${searchParams}</span>`)"></span>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<van-button type="danger" class="bottom-btn" @click="ensureChoose">确认选择</van-button>
|
||||
<div class="close-btn fixed">
|
||||
<van-button type="danger" @click="ensureChoose">确认选择</van-button>
|
||||
<!-- <van-button type="primary" @click="$emit('chooseOccupation', '')">取消</van-button> -->
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import occupationData from './data/occupation'
|
||||
import { getBankList } from '@/api/ebiz/sale/sale'
|
||||
import { Search, Sticky } from 'vant'
|
||||
export default {
|
||||
name: 'Occupation',
|
||||
@@ -63,7 +87,10 @@ export default {
|
||||
third: {},
|
||||
chooseName: '',
|
||||
lifeGrade: '',
|
||||
healthGrade: ''
|
||||
healthGrade: '',
|
||||
commonList: [],
|
||||
isSearch: false, // 是否搜索中
|
||||
searchList: []
|
||||
}
|
||||
},
|
||||
components: {
|
||||
@@ -71,6 +98,7 @@ export default {
|
||||
[Sticky.name]: Sticky
|
||||
},
|
||||
created() {
|
||||
// let occupationData = JSON.parse(window.localStorage.getItem('OccupationList'))
|
||||
this.init(occupationData)
|
||||
},
|
||||
mounted() {},
|
||||
@@ -82,6 +110,16 @@ export default {
|
||||
this.lifeGrade = this.life
|
||||
this.healthGrade = this.health
|
||||
this.third = {}
|
||||
|
||||
getBankList({
|
||||
operateType: 'hot_occupation'
|
||||
}).then(res => {
|
||||
if (res.result == '0') {
|
||||
this.commonList = res.content
|
||||
} else {
|
||||
this.$toast(res.resultMessage)
|
||||
}
|
||||
})
|
||||
},
|
||||
handleFirst(item) {
|
||||
this.sec = item.subs
|
||||
@@ -89,43 +127,127 @@ export default {
|
||||
this.second = {}
|
||||
this.thi = []
|
||||
this.third = {}
|
||||
this.commonInit()
|
||||
},
|
||||
handleSec(item) {
|
||||
this.thi = item.subs
|
||||
this.second = item
|
||||
this.third = {}
|
||||
this.commonInit()
|
||||
},
|
||||
handleThi(item) {
|
||||
this.third = item
|
||||
this.chooseName = this.third.name
|
||||
this.commonInit()
|
||||
},
|
||||
ensureChoose() {
|
||||
if (this.third.code) {
|
||||
this.$emit('chooseOccupation', this.third)
|
||||
console.log(this.third)
|
||||
} else {
|
||||
this.$toast('请选择职业')
|
||||
}
|
||||
},
|
||||
onSearch() {
|
||||
let data = []
|
||||
for (let item of occupationData) {
|
||||
if (JSON.stringify(item).indexOf(this.searchParams) != -1) {
|
||||
data.push(item)
|
||||
}
|
||||
this.sec = []
|
||||
this.thi = []
|
||||
this.first = {}
|
||||
this.second = {}
|
||||
this.third = {}
|
||||
this.commonInit()
|
||||
if (this.searchParams) {
|
||||
this.searchList = []
|
||||
this.isSearch = true
|
||||
this.occupationList.forEach(first => {
|
||||
first.subs.forEach(second => {
|
||||
second.subs.forEach(third => {
|
||||
if (third.name.indexOf(this.searchParams) != -1) {
|
||||
// this.searchList.push(Object.assign(third, { isActive: false }, { showName: first[index1].name + second[index2].name + third.name }))
|
||||
this.searchList.push(Object.assign(third, { isActive: false }, { showName: first.name + ' - ' + second.name + ' - ' + third.name }))
|
||||
console.log('first = ', first)
|
||||
}
|
||||
})
|
||||
})
|
||||
})
|
||||
console.log('this.searchList ==', this.searchList)
|
||||
} else {
|
||||
this.isSearch = false
|
||||
}
|
||||
this.init(data)
|
||||
// this.isSearch = true
|
||||
|
||||
// let data = JSON.parse(JSON.stringify(occupationData))
|
||||
// data.forEach(first => {
|
||||
// first.firstSubs = []
|
||||
// first.subs.forEach(second => {
|
||||
// second.secondSubs = []
|
||||
// second.subs.forEach(third => {
|
||||
// if (third.name.indexOf(this.searchParams) != -1) {
|
||||
// second.secondSubs.push(third)
|
||||
// }
|
||||
// })
|
||||
// second.subs = second.secondSubs
|
||||
// if (second.secondSubs.length != 0) {
|
||||
// first.firstSubs.push(second)
|
||||
// }
|
||||
// delete second.secondSubs
|
||||
// })
|
||||
// first.subs = first.firstSubs
|
||||
// delete first.firstSubs
|
||||
// })
|
||||
// for (let i = 0; i < data.length; i++) {
|
||||
// if (data[i].subs.length == 0) {
|
||||
// data.splice(i, 1)
|
||||
// i--
|
||||
// }
|
||||
// }
|
||||
// this.init(data)
|
||||
},
|
||||
clearSearch() {
|
||||
this.init(occupationData)
|
||||
},
|
||||
commonChoose(item, index) {
|
||||
this.commonInit()
|
||||
this.commonList[index].isActive = true
|
||||
this.occupationList.forEach(occupation => {
|
||||
occupation.subs.forEach(sub => {
|
||||
sub.subs.forEach(occupaitonItem => {
|
||||
if (occupaitonItem.code == item.code) {
|
||||
this.first = occupation
|
||||
this.sec = occupation.subs
|
||||
this.second = sub
|
||||
this.thi = sub.subs
|
||||
this.third = occupaitonItem
|
||||
this.chooseName = this.third.name
|
||||
}
|
||||
})
|
||||
})
|
||||
})
|
||||
},
|
||||
searchChoose(item, index) {
|
||||
this.searchList.forEach(item => {
|
||||
item.isActive = false
|
||||
})
|
||||
this.searchList[index].isActive = true
|
||||
this.third = item
|
||||
this.chooseName = this.third.name
|
||||
},
|
||||
commonInit() {
|
||||
this.commonList.forEach(item => {
|
||||
item.isActive = false
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.close-btn {
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
.van-button {
|
||||
width: 100% !important;
|
||||
}
|
||||
}
|
||||
.occupation {
|
||||
.main-area {
|
||||
padding: 10px;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
.item {
|
||||
@@ -133,20 +255,50 @@ export default {
|
||||
flex-grow: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
height: 360px;
|
||||
overflow-y: auto;
|
||||
}
|
||||
.active {
|
||||
color: red;
|
||||
background-color: #f2f2f2;
|
||||
}
|
||||
.choose-result {
|
||||
position: fixed;
|
||||
width: 100%;
|
||||
left: 20px;
|
||||
bottom: 44px;
|
||||
z-index: 100;
|
||||
background: #ffffff;
|
||||
}
|
||||
.choose-result {
|
||||
width: 100%;
|
||||
background: #ffffff;
|
||||
line-height: 20px;
|
||||
color: #e9332e;
|
||||
box-sizing: border-box;
|
||||
height: 40px;
|
||||
}
|
||||
.hidden {
|
||||
visibility: hidden;
|
||||
}
|
||||
.common-occupation {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
display: flex;
|
||||
// flex-wrap: wrap;
|
||||
align-items: center;
|
||||
div {
|
||||
// width: 30%;
|
||||
// height: 20px;
|
||||
padding: 4px;
|
||||
line-height: 20px;
|
||||
color: red;
|
||||
text-align: center;
|
||||
border: 1px solid #f2f2f2;
|
||||
margin: 5px;
|
||||
border-radius: 10px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
}
|
||||
.active {
|
||||
color: #e9332e;
|
||||
background-color: #f2f2f2;
|
||||
}
|
||||
.search-result {
|
||||
height: 420px;
|
||||
overflow-y: auto;
|
||||
p {
|
||||
// margin: 0 auto;
|
||||
text-align: left;
|
||||
min-width: 120px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,12 +11,6 @@
|
||||
right-icon="arrow"
|
||||
/>
|
||||
<van-popup v-model="parentShowPicker" position="bottom">
|
||||
<!-- <div class="close" v-if="showPicker">
|
||||
<div class="close-wrap">
|
||||
<p>职业选择</p>
|
||||
<van-icon name="cross" @click="cancel" />
|
||||
</div>
|
||||
</div> -->
|
||||
<occupation @chooseOccupation="chooseOccupation" :code="code" :name="name"></occupation>
|
||||
</van-popup>
|
||||
</div>
|
||||
|
||||
@@ -275,50 +275,90 @@ export default {
|
||||
let formdata = new FormData()
|
||||
formdata.append('imgPath', that.dataURLtoFile(that.file, that.imgName))
|
||||
|
||||
uploadImg(formdata).then(res => {
|
||||
if (res.result == '0') {
|
||||
this.$toast.clear()
|
||||
let imageInfoType = ''
|
||||
let subBusinessType = ''
|
||||
let name = ''
|
||||
uploadImg(formdata).then(
|
||||
res => {
|
||||
if (res.result == '0') {
|
||||
this.$toast.clear()
|
||||
let imageInfoType = ''
|
||||
let subBusinessType = ''
|
||||
let name = ''
|
||||
|
||||
if (that.type == 'fileListBank01') {
|
||||
//身份证正面
|
||||
name = 'fileListBank01'
|
||||
imageInfoType = '1'
|
||||
subBusinessType = '3'
|
||||
} else if (that.type == 'fileListBank03') {
|
||||
//学历
|
||||
name = 'fileListBank03'
|
||||
imageInfoType = '12'
|
||||
subBusinessType = '3'
|
||||
} else if (that.type == 'fileListBank04') {
|
||||
//免冠
|
||||
name = 'fileListBank04'
|
||||
imageInfoType = '13'
|
||||
subBusinessType = '3'
|
||||
} else if (that.type == 'fileListBank05') {
|
||||
//银行卡
|
||||
name = 'fileListBank05'
|
||||
imageInfoType = '3'
|
||||
subBusinessType = '3'
|
||||
} else if (that.type == 'fileListBank06') {
|
||||
//担保人
|
||||
name = 'fileListBank06'
|
||||
imageInfoType = '1'
|
||||
subBusinessType = '4'
|
||||
}
|
||||
if (that.type == 'fileListBank01') {
|
||||
//身份证正面
|
||||
name = 'fileListBank01'
|
||||
imageInfoType = '1'
|
||||
subBusinessType = '3'
|
||||
} else if (that.type == 'fileListBank03') {
|
||||
//学历
|
||||
name = 'fileListBank03'
|
||||
imageInfoType = '12'
|
||||
subBusinessType = '3'
|
||||
} else if (that.type == 'fileListBank04') {
|
||||
//免冠
|
||||
name = 'fileListBank04'
|
||||
imageInfoType = '13'
|
||||
subBusinessType = '3'
|
||||
} else if (that.type == 'fileListBank05') {
|
||||
//银行卡
|
||||
name = 'fileListBank05'
|
||||
imageInfoType = '3'
|
||||
subBusinessType = '3'
|
||||
} else if (that.type == 'fileListBank06') {
|
||||
//担保人
|
||||
name = 'fileListBank06'
|
||||
imageInfoType = '1'
|
||||
subBusinessType = '4'
|
||||
}
|
||||
|
||||
let obj = {
|
||||
name: name,
|
||||
imageInfoType: imageInfoType,
|
||||
subBusinessType: subBusinessType,
|
||||
fileName: that.imgName,
|
||||
rgssUrl: encodeURI(res.path).replace(/\+/g, '%2B')
|
||||
let obj = {
|
||||
name: name,
|
||||
imageInfoType: imageInfoType,
|
||||
subBusinessType: subBusinessType,
|
||||
fileName: that.imgName,
|
||||
rgssUrl: encodeURI(res.path).replace(/\+/g, '%2B')
|
||||
}
|
||||
that.list.push(obj)
|
||||
} else {
|
||||
switch (that.type) {
|
||||
case 'fileListBank01':
|
||||
this.fileListBank01.pop()
|
||||
break
|
||||
case 'fileListBank03': //学历
|
||||
this.fileListBank03 = []
|
||||
break
|
||||
case 'fileListBank04': //免冠
|
||||
this.fileListBank04 = []
|
||||
break
|
||||
case 'fileListBank05':
|
||||
this.fileListBank05.pop()
|
||||
break
|
||||
case 'fileListBank06':
|
||||
this.fileListBank06.pop()
|
||||
break
|
||||
}
|
||||
}
|
||||
},
|
||||
error => {
|
||||
that.$toast('网络环境不佳,图片上传失败,请切换移动网络或稍后重试')
|
||||
switch (that.type) {
|
||||
case 'fileListBank01':
|
||||
this.fileListBank01.pop()
|
||||
break
|
||||
case 'fileListBank03': //学历
|
||||
this.fileListBank03 = []
|
||||
break
|
||||
case 'fileListBank04': //免冠
|
||||
this.fileListBank04 = []
|
||||
break
|
||||
case 'fileListBank05':
|
||||
this.fileListBank05.pop()
|
||||
break
|
||||
case 'fileListBank06':
|
||||
this.fileListBank06.pop()
|
||||
break
|
||||
}
|
||||
that.list.push(obj)
|
||||
}
|
||||
})
|
||||
)
|
||||
},
|
||||
// 删除图片
|
||||
deleteImg(file, nameList) {
|
||||
|
||||
@@ -285,7 +285,16 @@
|
||||
</van-radio-group>
|
||||
</div>
|
||||
<div class="bg-white bottom-btn">
|
||||
<van-button type="danger" class="attachmentManagement-next" size="large" :disabled="isDisabled" @click="next" @touchstart="beforeNext(isDisabled)" v-no-more-click="1000">下一步</van-button>
|
||||
<van-button
|
||||
type="danger"
|
||||
class="attachmentManagement-next"
|
||||
size="large"
|
||||
:disabled="isDisabled"
|
||||
@click="next"
|
||||
@touchstart="beforeNext(isDisabled)"
|
||||
v-no-more-click="1000"
|
||||
>下一步</van-button
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
@@ -722,228 +731,269 @@ export default {
|
||||
})
|
||||
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()
|
||||
// res.responseObject.imgList.map(item => {
|
||||
if (
|
||||
that.type == 'fileListIdFront' ||
|
||||
that.type == 'fileListIdBack' ||
|
||||
that.type == 'fileLIstImg' ||
|
||||
that.type == 'fileListBank' ||
|
||||
// that.type == 'fileListBankBack' ||
|
||||
that.type == 'saleInsuredInfoOther'
|
||||
) {
|
||||
// 是投保人
|
||||
// console.log(that.file)
|
||||
// 证件类型
|
||||
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'
|
||||
imageInfoType = '1'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '1') {
|
||||
//身份证反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '2'
|
||||
} else if (that.type == 'fileListIdFront' && that.id == '2') {
|
||||
//户口本正面
|
||||
name = 'fileListIdFront'
|
||||
imageInfoType = '5'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '2') {
|
||||
//户口本反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '6'
|
||||
} else if (that.type == 'fileListIdFront' && that.id == '3') {
|
||||
//出生证正面
|
||||
name = 'fileListIdFront'
|
||||
imageInfoType = '7'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '3') {
|
||||
//出生证反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '12'
|
||||
} else if (that.type == 'fileLIstImg' && that.id == '4') {
|
||||
//护照面
|
||||
name = 'fileLIstImg'
|
||||
imageInfoType = '8'
|
||||
} else if (that.type == 'fileListIdFront' && that.id == '5') {
|
||||
//港澳居民来往内地通行证正面
|
||||
name = 'fileListIdFront'
|
||||
imageInfoType = '9'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '5') {
|
||||
//港澳居民来往内地通行证反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '13'
|
||||
} else if (that.type == 'fileListIdFront' && that.id == '6') {
|
||||
//台湾居民来往大陆通行证正面
|
||||
name = 'fileListIdFront'
|
||||
imageInfoType = '10'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '6') {
|
||||
//台湾居民来往大陆通行证反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '14'
|
||||
} else if (that.type == 'fileListIdFront' && that.id == '8') {
|
||||
//外国人永久居留身份证正面
|
||||
name = 'fileListIdFront'
|
||||
imageInfoType = '15'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '8') {
|
||||
//外国人永久居留身份证反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '16'
|
||||
} else if (that.type == 'fileListIdFront' && that.id == '9') {
|
||||
//港澳台居民居住证正面
|
||||
name = 'fileListIdFront'
|
||||
imageInfoType = '17'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '9') {
|
||||
//港澳台居民居住证反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '18'
|
||||
} else if (that.type == 'fileListBank') {
|
||||
//银行卡正面
|
||||
name = 'fileListBank'
|
||||
imageInfoType = '3'
|
||||
// } else if (that.type == 'fileListBankBack') {
|
||||
// //银行卡反面
|
||||
// imageInfoType = '19'
|
||||
}
|
||||
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
|
||||
}
|
||||
that.list.push(obj)
|
||||
} else if (
|
||||
that.type == 'fileListIdFrontInsured' ||
|
||||
that.type == 'fileListIdBackInsured' ||
|
||||
that.type == 'fileListBankInsured' ||
|
||||
that.type == 'fileLIstImgInsured' ||
|
||||
that.type == 'saleInsuredPersonInfoOther'
|
||||
) {
|
||||
// 是被保险人
|
||||
// 证件类型
|
||||
uploadImg(formdata).then(
|
||||
res => {
|
||||
// console.log(res)
|
||||
if (res.result == '0') {
|
||||
this.$toast.clear()
|
||||
// res.responseObject.imgList.map(item => {
|
||||
if (
|
||||
that.type == 'fileListIdFront' ||
|
||||
that.type == 'fileListIdBack' ||
|
||||
that.type == 'fileLIstImg' ||
|
||||
that.type == 'fileListBank' ||
|
||||
// that.type == 'fileListBankBack' ||
|
||||
that.type == 'saleInsuredInfoOther'
|
||||
) {
|
||||
// 是投保人
|
||||
// console.log(that.file)
|
||||
// 证件类型
|
||||
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'
|
||||
imageInfoType = '1'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '1') {
|
||||
//身份证反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '2'
|
||||
} else if (that.type == 'fileListIdFront' && that.id == '2') {
|
||||
//户口本正面
|
||||
name = 'fileListIdFront'
|
||||
imageInfoType = '5'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '2') {
|
||||
//户口本反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '6'
|
||||
} else if (that.type == 'fileListIdFront' && that.id == '3') {
|
||||
//出生证正面
|
||||
name = 'fileListIdFront'
|
||||
imageInfoType = '7'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '3') {
|
||||
//出生证反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '12'
|
||||
} else if (that.type == 'fileLIstImg' && that.id == '4') {
|
||||
//护照面
|
||||
name = 'fileLIstImg'
|
||||
imageInfoType = '8'
|
||||
} else if (that.type == 'fileListIdFront' && that.id == '5') {
|
||||
//港澳居民来往内地通行证正面
|
||||
name = 'fileListIdFront'
|
||||
imageInfoType = '9'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '5') {
|
||||
//港澳居民来往内地通行证反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '13'
|
||||
} else if (that.type == 'fileListIdFront' && that.id == '6') {
|
||||
//台湾居民来往大陆通行证正面
|
||||
name = 'fileListIdFront'
|
||||
imageInfoType = '10'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '6') {
|
||||
//台湾居民来往大陆通行证反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '14'
|
||||
} else if (that.type == 'fileListIdFront' && that.id == '8') {
|
||||
//外国人永久居留身份证正面
|
||||
name = 'fileListIdFront'
|
||||
imageInfoType = '15'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '8') {
|
||||
//外国人永久居留身份证反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '16'
|
||||
} else if (that.type == 'fileListIdFront' && that.id == '9') {
|
||||
//港澳台居民居住证正面
|
||||
name = 'fileListIdFront'
|
||||
imageInfoType = '17'
|
||||
} else if (that.type == 'fileListIdBack' && that.id == '9') {
|
||||
//港澳台居民居住证反面
|
||||
name = 'fileListIdBack'
|
||||
imageInfoType = '18'
|
||||
} else if (that.type == 'fileListBank') {
|
||||
//银行卡正面
|
||||
name = 'fileListBank'
|
||||
imageInfoType = '3'
|
||||
// } else if (that.type == 'fileListBankBack') {
|
||||
// //银行卡反面
|
||||
// imageInfoType = '19'
|
||||
}
|
||||
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
|
||||
}
|
||||
that.list.push(obj)
|
||||
} else if (
|
||||
that.type == 'fileListIdFrontInsured' ||
|
||||
that.type == 'fileListIdBackInsured' ||
|
||||
that.type == 'fileListBankInsured' ||
|
||||
that.type == 'fileLIstImgInsured' ||
|
||||
that.type == 'saleInsuredPersonInfoOther'
|
||||
) {
|
||||
// 是被保险人
|
||||
// 证件类型
|
||||
|
||||
let imageInfoType = ''
|
||||
let name = ''
|
||||
let imageInfoType = ''
|
||||
let name = ''
|
||||
|
||||
if (that.type == 'fileListIdFrontInsured' && that.id == '1') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '1'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '1') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '2'
|
||||
} else if (that.type == 'fileListIdFrontInsured' && that.id == '2') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '5'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '2') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '6'
|
||||
} else if (that.type == 'fileListIdFrontInsured' && that.id == '3') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '7'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '3') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '12'
|
||||
} else if (that.type == 'fileLIstImgInsured' && that.id == '4') {
|
||||
name = 'fileLIstImgInsured'
|
||||
imageInfoType = '8'
|
||||
} else if (that.type == 'fileListIdFrontInsured' && that.id == '5') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '9'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '5') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '13'
|
||||
} else if (that.type == 'fileListIdFrontInsured' && that.id == '6') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '10'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '6') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '14'
|
||||
} else if (that.type == 'fileListIdFrontInsured' && that.id == '8') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '15'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '8') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '16'
|
||||
} else if (that.type == 'fileListIdFrontInsured' && that.id == '9') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '17'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '9') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '18'
|
||||
if (that.type == 'fileListIdFrontInsured' && that.id == '1') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '1'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '1') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '2'
|
||||
} else if (that.type == 'fileListIdFrontInsured' && that.id == '2') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '5'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '2') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '6'
|
||||
} else if (that.type == 'fileListIdFrontInsured' && that.id == '3') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '7'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '3') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '12'
|
||||
} else if (that.type == 'fileLIstImgInsured' && that.id == '4') {
|
||||
name = 'fileLIstImgInsured'
|
||||
imageInfoType = '8'
|
||||
} else if (that.type == 'fileListIdFrontInsured' && that.id == '5') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '9'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '5') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '13'
|
||||
} else if (that.type == 'fileListIdFrontInsured' && that.id == '6') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '10'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '6') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '14'
|
||||
} else if (that.type == 'fileListIdFrontInsured' && that.id == '8') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '15'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '8') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '16'
|
||||
} else if (that.type == 'fileListIdFrontInsured' && that.id == '9') {
|
||||
name = 'fileListIdFrontInsured'
|
||||
imageInfoType = '17'
|
||||
} else if (that.type == 'fileListIdBackInsured' && that.id == '9') {
|
||||
name = 'fileListIdBackInsured'
|
||||
imageInfoType = '18'
|
||||
}
|
||||
|
||||
let obj = {
|
||||
name: name,
|
||||
businessNo: that.orderNo,
|
||||
businessType: '',
|
||||
imageInfoType: imageInfoType,
|
||||
rgssUrl: encodeURI(res.path).replace(/\+/g, '%2B'),
|
||||
subBusinessType: '1',
|
||||
subBusinessNo: that.saleInsuredPersonInfo.insuredId,
|
||||
fileName: that.imgName
|
||||
}
|
||||
|
||||
that.list.push(obj)
|
||||
} else if (that.type == 'fileListOther') {
|
||||
// 是其他
|
||||
let type = '2'
|
||||
let name = 'fileListOther'
|
||||
let obj = {
|
||||
name: name,
|
||||
businessNo: that.orderNo,
|
||||
businessType: name,
|
||||
imageInfoType: '11',
|
||||
rgssUrl: encodeURI(res.path).replace(/\+/g, '%2B'),
|
||||
subBusinessType: type,
|
||||
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)
|
||||
}
|
||||
|
||||
let obj = {
|
||||
name: name,
|
||||
businessNo: that.orderNo,
|
||||
businessType: '',
|
||||
imageInfoType: imageInfoType,
|
||||
rgssUrl: encodeURI(res.path).replace(/\+/g, '%2B'),
|
||||
subBusinessType: '1',
|
||||
subBusinessNo: that.saleInsuredPersonInfo.insuredId,
|
||||
fileName: that.imgName
|
||||
} else {
|
||||
switch (that.type) {
|
||||
case 'fileListIdFront':
|
||||
that.fileListIdFront = []
|
||||
break
|
||||
case 'fileListIdBack':
|
||||
that.fileListIdBack = []
|
||||
break
|
||||
case 'fileLIstImg':
|
||||
that.fileLIstImg = []
|
||||
break
|
||||
case 'fileListBank':
|
||||
that.fileListBank = []
|
||||
break
|
||||
case 'fileListOther':
|
||||
that.fileListOther = []
|
||||
break
|
||||
case 'fileListIdFrontInsured':
|
||||
that.fileListIdFrontInsured = []
|
||||
break
|
||||
case 'fileListIdBackInsured':
|
||||
that.fileListIdBackInsured = []
|
||||
break
|
||||
case 'fileListBankInsured':
|
||||
that.fileListBankInsured = []
|
||||
break
|
||||
case 'fileLIstImgInsured':
|
||||
that.fileLIstImgInsured = []
|
||||
break
|
||||
case 'saleInsuredInfoOther':
|
||||
that.saleInsuredInfoOther = []
|
||||
break
|
||||
case 'saleInsuredPersonInfoOther':
|
||||
that.saleInsuredPersonInfoOther = []
|
||||
break
|
||||
}
|
||||
|
||||
that.list.push(obj)
|
||||
} else if (that.type == 'fileListOther') {
|
||||
// 是其他
|
||||
let type = '2'
|
||||
let name = 'fileListOther'
|
||||
let obj = {
|
||||
name: name,
|
||||
businessNo: that.orderNo,
|
||||
businessType: name,
|
||||
imageInfoType: '11',
|
||||
rgssUrl: encodeURI(res.path).replace(/\+/g, '%2B'),
|
||||
subBusinessType: type,
|
||||
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)
|
||||
this.$toast.clear()
|
||||
this.$toast(res.resultMessage)
|
||||
}
|
||||
} else {
|
||||
},
|
||||
error => {
|
||||
switch (that.type) {
|
||||
case 'fileListIdFront':
|
||||
that.fileListIdFront = []
|
||||
@@ -957,9 +1007,6 @@ export default {
|
||||
case 'fileListBank':
|
||||
that.fileListBank = []
|
||||
break
|
||||
// case 'fileListBankBack':
|
||||
// that.fileListBankBack = []
|
||||
// break
|
||||
case 'fileListOther':
|
||||
that.fileListOther = []
|
||||
break
|
||||
@@ -982,13 +1029,12 @@ export default {
|
||||
that.saleInsuredPersonInfoOther = []
|
||||
break
|
||||
}
|
||||
this.$toast.clear()
|
||||
this.$toast(res.resultMessage)
|
||||
this.$toast('网络环境不佳,图片上传失败,请切换移动网络或稍后重试')
|
||||
}
|
||||
})
|
||||
)
|
||||
},
|
||||
beforeNext(isDis){
|
||||
if(isDis && this.fileListBank.length > 0 && this.fileListIdBack.length > 0 && this.fileListIdFront.length > 0){
|
||||
beforeNext(isDis) {
|
||||
if (isDis && this.fileListBank.length > 0 && this.fileListIdBack.length > 0 && this.fileListIdFront.length > 0) {
|
||||
this.$toast('请勾选确认销售人员已见证各证件原件并拍照上传')
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user