mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-11 17:56:43 +08:00
按照产品规定的年龄,证件类型枚举身份证、户口本,默认户口本,且户口本证件截止日期默认长期
This commit is contained in:
@@ -91,7 +91,7 @@
|
|||||||
v-validate="'required|mobile'"
|
v-validate="'required|mobile'"
|
||||||
maxlength="11"
|
maxlength="11"
|
||||||
/>
|
/>
|
||||||
<van-field v-model="userInfo.email" required label="邮箱" name="邮箱" placeholder="请输入" v-validate="'required|email'" clearable />
|
<van-field v-model="userInfo.email" label="邮箱" name="邮箱" placeholder="如需电子保单,请填写" v-validate="'required|email'" clearable />
|
||||||
<!-- <van-field v-model="userInfo.workcompany" required label="工作单位" name="工作单位" placeholder="请输入" v-validate="'required'" maxlength="50" clearable /> -->
|
<!-- <van-field v-model="userInfo.workcompany" required label="工作单位" name="工作单位" placeholder="请输入" v-validate="'required'" maxlength="50" clearable /> -->
|
||||||
<van-field
|
<van-field
|
||||||
v-validate="'required'"
|
v-validate="'required'"
|
||||||
@@ -219,7 +219,7 @@
|
|||||||
:maxDate="insuredMaxDate"
|
:maxDate="insuredMaxDate"
|
||||||
></FieldDatePicter>
|
></FieldDatePicter>
|
||||||
<van-field
|
<van-field
|
||||||
required
|
v-if="isLessEighteen"
|
||||||
v-model="insuredInfo.mobile"
|
v-model="insuredInfo.mobile"
|
||||||
clearable
|
clearable
|
||||||
label="手机号码"
|
label="手机号码"
|
||||||
@@ -228,7 +228,7 @@
|
|||||||
v-validate="'required|mobile'"
|
v-validate="'required|mobile'"
|
||||||
maxlength="11"
|
maxlength="11"
|
||||||
/>
|
/>
|
||||||
<van-field v-model="insuredInfo.email" required label="邮箱" name="邮箱" placeholder="请输入" v-validate="'required|email'" clearable />
|
<van-field v-if="isLessEighteen" v-model="insuredInfo.email" label="邮箱" name="邮箱" placeholder="请输入" v-validate="'required|email'" clearable />
|
||||||
<van-field
|
<van-field
|
||||||
required
|
required
|
||||||
@click="openOccupation('2')"
|
@click="openOccupation('2')"
|
||||||
@@ -295,6 +295,10 @@
|
|||||||
@click="areaSelect('2')"
|
@click="areaSelect('2')"
|
||||||
/>
|
/>
|
||||||
<van-field v-model="insuredInfo.homeAddress" label name="详细地址" placeholder="请输入详细地址" clearable maxlength="30" />
|
<van-field v-model="insuredInfo.homeAddress" label name="详细地址" placeholder="请输入详细地址" clearable maxlength="30" />
|
||||||
|
|
||||||
|
<div class="pl10 pt10 pb10 pr10 address fs14 redRadioCheckbox">
|
||||||
|
<van-checkbox v-model="withRootUser.value">同投保人</van-checkbox>
|
||||||
|
</div>
|
||||||
</van-cell-group>
|
</van-cell-group>
|
||||||
<van-cell-group class="mt10" v-else>
|
<van-cell-group class="mt10" v-else>
|
||||||
<p style="border-bottom: 1px solid #ebedf0" class="fs15 fwb pl10 pv12">被保人信息</p>
|
<p style="border-bottom: 1px solid #ebedf0" class="fs15 fwb pl10 pv12">被保人信息</p>
|
||||||
@@ -459,7 +463,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="van-cell van-field" v-show="showField" style="border-bottom: 1px solid rgb(235, 237, 240)">
|
<div class="van-cell van-field" v-show="showField || showFirstOr" style="border-bottom: 1px solid rgb(235, 237, 240)">
|
||||||
<van-cell >
|
<van-cell >
|
||||||
<van-radio-group v-model="firstOr" >
|
<van-radio-group v-model="firstOr" >
|
||||||
<van-row>
|
<van-row>
|
||||||
@@ -487,7 +491,7 @@
|
|||||||
>
|
>
|
||||||
</van-checkbox-group> -->
|
</van-checkbox-group> -->
|
||||||
<!-- <div class="tips" v-if="cvaliDate.length > 0">注:2020年04月03日0时至2021年04月02日24时止。</div> -->
|
<!-- <div class="tips" v-if="cvaliDate.length > 0">注:2020年04月03日0时至2021年04月02日24时止。</div> -->
|
||||||
<div class="tips" v-if="this.itemProductDTOS.productCode === 'GFRS_M0048'||this.itemProductDTOS.productCode === 'GFRS_M0049'||this.itemProductDTOS.productCode === 'GFRS_M0050'">注:为未成年子女投保的人身保险,在被保险人成年之前,因被保险人身故给付的保险金总和不得超过国务院保险监督管理机构规定的限额,身故给付的保险金额总和的约定也不得超过前述限额。但航空意外死亡保险金额及重大自然灾害意外死亡保险金额不计算在上述规定限额之中。</div>
|
<div class="tips" v-if="this.itemProductDTOS.productCode === 'GFRS_M0048'||this.itemProductDTOS.productCode === 'GFRS_M0049'||this.itemProductDTOS.productCode === 'GFRS_M0050'||this.itemProductDTOS.productCode === 'GFRS_M0052'">注:为未成年子女投保的人身保险,在被保险人成年之前,因被保险人身故给付的保险金总和不得超过国务院保险监督管理机构规定的限额,身故给付的保险金额总和的约定也不得超过前述限额。但航空意外死亡保险金额及重大自然灾害意外死亡保险金额不计算在上述规定限额之中。</div>
|
||||||
<van-goods-action style="z-index: 99">
|
<van-goods-action style="z-index: 99">
|
||||||
<van-button type="default" style="width: 50%; font-size: 14px; height: 40px; background: white"
|
<van-button type="default" style="width: 50%; font-size: 14px; height: 40px; background: white"
|
||||||
>总保费:<span style="color: red; font-weight: bold; font-size: 18px; font-weight: 400">{{ allPrice }}</span
|
>总保费:<span style="color: red; font-weight: bold; font-size: 18px; font-weight: 400">{{ allPrice }}</span
|
||||||
@@ -574,6 +578,7 @@ export default {
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
isLessEighteen:true, //是否小于18周岁(不含)
|
||||||
averageAnnualIncomeFlag:false, // 20210730 年收入不展示且默认为0 核心对年收入有非空校验
|
averageAnnualIncomeFlag:false, // 20210730 年收入不展示且默认为0 核心对年收入有非空校验
|
||||||
idLimit: false, //截止日期是否可编辑
|
idLimit: false, //截止日期是否可编辑
|
||||||
idLimitInsured: false, //截止日期是否可编辑--被保人
|
idLimitInsured: false, //截止日期是否可编辑--被保人
|
||||||
@@ -673,6 +678,7 @@ export default {
|
|||||||
healthGrade: '', //健康等级
|
healthGrade: '', //健康等级
|
||||||
nativeplace: '', //国家地区
|
nativeplace: '', //国家地区
|
||||||
marriageStatus: '', //婚姻状况
|
marriageStatus: '', //婚姻状况
|
||||||
|
marriage:'',
|
||||||
homeProvince: '', //家庭省
|
homeProvince: '', //家庭省
|
||||||
homeCity: '', //家庭市
|
homeCity: '', //家庭市
|
||||||
homeArea: '450101', //家庭区
|
homeArea: '450101', //家庭区
|
||||||
@@ -701,9 +707,15 @@ export default {
|
|||||||
itemProductDTOS: JSON.parse(CacheUtils.getLocItem('itemProductDTOS')), //
|
itemProductDTOS: JSON.parse(CacheUtils.getLocItem('itemProductDTOS')), //
|
||||||
// showDialog:false,
|
// showDialog:false,
|
||||||
showField:false,
|
showField:false,
|
||||||
|
//GFRS-2641 保留首次投保、保险期间届满重新投保,默认首次投保
|
||||||
|
showFirstOr: false,
|
||||||
medical:'0',
|
medical:'0',
|
||||||
firstOr:'0',
|
firstOr:'0',
|
||||||
chooseKind:''
|
chooseKind:'',
|
||||||
|
withRootUser: {
|
||||||
|
load: false, //防止重复请求
|
||||||
|
value: false,
|
||||||
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
@@ -732,6 +744,15 @@ export default {
|
|||||||
this.userInfo.relationToInsured = "";
|
this.userInfo.relationToInsured = "";
|
||||||
this.showField=true;
|
this.showField=true;
|
||||||
}
|
}
|
||||||
|
//GFRS-2641 少儿安康
|
||||||
|
if(this.itemProductDTOS.productCode === 'GFRS_M0052'){
|
||||||
|
this.userInfo.relationToInsured = '3'
|
||||||
|
//GFRS-2641 保留首次投保、保险期间届满重新投保,默认首次投保
|
||||||
|
this.showFirstOr = true
|
||||||
|
//GFRS-2641 被保险人去掉电子邮箱、手机号码字段
|
||||||
|
this.isLessEighteen = false
|
||||||
|
}
|
||||||
|
this.userInfo.homeName = getAreaName([{ code: 450000 }, { code: 450100 }, { code: 620201 }]) //家庭地址
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
// 2516--除万福卡,投保人、被保险人年收入,默认为0,允许修改
|
// 2516--除万福卡,投保人、被保险人年收入,默认为0,允许修改
|
||||||
@@ -978,7 +999,9 @@ export default {
|
|||||||
} else if (pickerType == '8') {
|
} else if (pickerType == '8') {
|
||||||
this.columns = DataDictionary.salarySource
|
this.columns = DataDictionary.salarySource
|
||||||
} else if (pickerType == '9') {
|
} else if (pickerType == '9') {
|
||||||
if(this.itemProductDTOS.productCode === 'GFRS_M0048'||this.itemProductDTOS.productCode === 'GFRS_M0049'){
|
//与被保人关系限定为:父母 (不可选,枚举值只有一个)
|
||||||
|
if(this.itemProductDTOS.productCode === 'GFRS_M0048'||this.itemProductDTOS.productCode === 'GFRS_M0049' ||
|
||||||
|
this.itemProductDTOS.productCode === 'GFRS_M0052'){
|
||||||
this.columns = DataDictionary.relationToAppnt.slice(2,3);
|
this.columns = DataDictionary.relationToAppnt.slice(2,3);
|
||||||
}else if(this.itemProductDTOS.productCode === 'GFRS_M0050'){
|
}else if(this.itemProductDTOS.productCode === 'GFRS_M0050'){
|
||||||
this.columns = DataDictionary.relationToAppnt.slice(0,1).concat(DataDictionary.relationToAppnt.slice(2,3));
|
this.columns = DataDictionary.relationToAppnt.slice(0,1).concat(DataDictionary.relationToAppnt.slice(2,3));
|
||||||
@@ -1010,7 +1033,8 @@ export default {
|
|||||||
} else if (pickerType == '22') {
|
} else if (pickerType == '22') {
|
||||||
//2516--三个学平险--被保险人身份信息选择仅保留“身份证、户口本”,目前选择户口本仍要填写身份证到期
|
//2516--三个学平险--被保险人身份信息选择仅保留“身份证、户口本”,目前选择户口本仍要填写身份证到期
|
||||||
//时间,如果选择户口本项,默认为长期。
|
//时间,如果选择户口本项,默认为长期。
|
||||||
if(this.itemProductDTOS.productCode == 'GFRS_M0048' || this.itemProductDTOS.productCode == 'GFRS_M0049'|| this.itemProductDTOS.productCode == 'GFRS_M0050'){
|
//GFRS-2641--少儿安康,证件类型枚举“身份证、户口本”
|
||||||
|
if(this.itemProductDTOS.productCode == 'GFRS_M0048' || this.itemProductDTOS.productCode == 'GFRS_M0049'|| this.itemProductDTOS.productCode == 'GFRS_M0050' || this.itemProductDTOS.productCode == 'GFRS_M0052'){
|
||||||
this.columns = DataDictionary.insuredIdTypeSpecial
|
this.columns = DataDictionary.insuredIdTypeSpecial
|
||||||
}else{
|
}else{
|
||||||
this.columns = DataDictionary.insuredIdType
|
this.columns = DataDictionary.insuredIdType
|
||||||
@@ -1180,6 +1204,22 @@ export default {
|
|||||||
this.$refs.insuredBirthday.date = ''
|
this.$refs.insuredBirthday.date = ''
|
||||||
return this.$toast('出生日期不晚于当日')
|
return this.$toast('出生日期不晚于当日')
|
||||||
}
|
}
|
||||||
|
//GFRS-2641-- 被保险人年龄小于18周岁(不含),前端需隐藏手机号码、电子邮箱;
|
||||||
|
//GFRS-2641--被保险人大于等于18周岁(含),前端需展示手机号码、电子邮箱,且非必填
|
||||||
|
let age = utilsAge.getAge(val, new Date())
|
||||||
|
if(this.itemProductDTOS.productCode != 'GFRS_M0052'){
|
||||||
|
if(age <= 17){
|
||||||
|
this.isLessEighteen = false //是否小于18周岁(不含)
|
||||||
|
}else{
|
||||||
|
this.isLessEighteen = true //是否小于18周岁(不含)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//GFRS-2641--被保险人年龄小于20周岁(不含),婚姻状况默认为未婚;
|
||||||
|
if(age < 20){
|
||||||
|
this.insuredInfo.marriage = '2'
|
||||||
|
}else{
|
||||||
|
this.insuredInfo.marriage = ''
|
||||||
|
}
|
||||||
}
|
}
|
||||||
break
|
break
|
||||||
case '6':
|
case '6':
|
||||||
@@ -1367,12 +1407,12 @@ export default {
|
|||||||
if (!this.insuredInfo.birthday) {
|
if (!this.insuredInfo.birthday) {
|
||||||
return this.$toast('被保人出生日期不能为空')
|
return this.$toast('被保人出生日期不能为空')
|
||||||
}
|
}
|
||||||
if (!this.insuredInfo.mobile) {
|
// if (!this.insuredInfo.mobile) {
|
||||||
return this.$toast('被保人手机号不能为空')
|
// return this.$toast('被保人手机号不能为空')
|
||||||
}
|
// }
|
||||||
if (!this.insuredInfo.email) {
|
// if (!this.insuredInfo.email) {
|
||||||
return this.$toast('被保人邮箱不能为空')
|
// return this.$toast('被保人邮箱不能为空')
|
||||||
}
|
// }
|
||||||
if (!this.insuredInfo.occupationName) {
|
if (!this.insuredInfo.occupationName) {
|
||||||
return this.$toast('被保人职业不能为空')
|
return this.$toast('被保人职业不能为空')
|
||||||
}
|
}
|
||||||
@@ -1602,6 +1642,11 @@ export default {
|
|||||||
if(insuredInfoAge<15||insuredInfoAge>40){
|
if(insuredInfoAge<15||insuredInfoAge>40){
|
||||||
return this.$toast('被保险人年龄应为15岁-40岁,请重新选择。')
|
return this.$toast('被保险人年龄应为15岁-40岁,请重新选择。')
|
||||||
}
|
}
|
||||||
|
}else if (this.itemProductDTOS.productCode === 'GFRS_M0052') {
|
||||||
|
//GFRS-2641--少儿安康:17岁≤被保险人
|
||||||
|
if(insuredInfoAge>17){
|
||||||
|
return this.$toast('被保险人年龄应为0岁-17岁,请重新选择。')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (this.userInfo.relationToInsured == '4') {
|
if (this.userInfo.relationToInsured == '4') {
|
||||||
//投被保人关系是子女
|
//投被保人关系是子女
|
||||||
@@ -1866,15 +1911,22 @@ export default {
|
|||||||
}
|
}
|
||||||
this.insuredInfo.birthday = idToData(val).birthday
|
this.insuredInfo.birthday = idToData(val).birthday
|
||||||
this.insuredInfo.sex = idToData(val).sex
|
this.insuredInfo.sex = idToData(val).sex
|
||||||
//被保险人证件类型枚举“身份证、户口本”,默认户口本,且户口本证件截止日期默认长期(如果后期还有被保险人年龄为0-17周岁的,都同该规则)
|
//GFRS-2641-- 被保险人年龄小于18周岁(不含),前端需隐藏手机号码、电子邮箱;
|
||||||
let age = utilsAge.getAge(this.insuredInfo.birthday, new Date())
|
//GFRS-2641--被保险人大于等于18周岁(含),前端需展示手机号码、电子邮箱,且非必填
|
||||||
if(age <= 17){
|
if(this.insuredInfo.birthday){
|
||||||
|
let age = utilsAge.getAge(this.insuredInfo.birthday, new Date())
|
||||||
}
|
if(age <= 17){
|
||||||
//GFRS-2641--被保险人年龄小于20周岁(不含),婚姻状况默认为未婚;
|
this.isLessEighteen = false //是否小于18周岁(不含)
|
||||||
if(age < 20){
|
}else{
|
||||||
this.insuredInfo.marriage = '2'
|
this.isLessEighteen = true //是否小于18周岁(不含)
|
||||||
}
|
}
|
||||||
|
//GFRS-2641--被保险人年龄小于20周岁(不含),婚姻状况默认为未婚;
|
||||||
|
if(age < 20){
|
||||||
|
this.insuredInfo.marriage = '2'
|
||||||
|
}else{
|
||||||
|
this.insuredInfo.marriage = ''
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -1914,6 +1966,7 @@ export default {
|
|||||||
email: '', //电子邮箱
|
email: '', //电子邮箱
|
||||||
effectiveDateType:false //是否长期
|
effectiveDateType:false //是否长期
|
||||||
}
|
}
|
||||||
|
|
||||||
// 2516--三款学平险-- 0048义务教育 0049 幼儿园 0050 高中
|
// 2516--三款学平险-- 0048义务教育 0049 幼儿园 0050 高中
|
||||||
// GFRS-2641--被保险人职业:幼儿园版默认学龄前儿童,义务教育、高中/高等教育默认一般学生
|
// GFRS-2641--被保险人职业:幼儿园版默认学龄前儿童,义务教育、高中/高等教育默认一般学生
|
||||||
// 被保险人婚姻默认未婚,允许修改
|
// 被保险人婚姻默认未婚,允许修改
|
||||||
@@ -1928,6 +1981,14 @@ export default {
|
|||||||
this.insuredInfo.occupationCode = '2099908'
|
this.insuredInfo.occupationCode = '2099908'
|
||||||
this.insuredInfo.occupationName = '学龄前儿童'
|
this.insuredInfo.occupationName = '学龄前儿童'
|
||||||
}
|
}
|
||||||
|
// GFRS-2641--少儿安康,默认户口本,且户口本证件截止日期默认长期
|
||||||
|
if(this.itemProductDTOS.productCode == 'GFRS_M0052'){
|
||||||
|
this.insuredInfo.idType = '2'
|
||||||
|
this.insuredInfo.certiexpiredate = ''
|
||||||
|
this.insuredInfo.effectiveDateType = true
|
||||||
|
this.insuredInfo.occupationName = '一般学生'
|
||||||
|
this.insuredInfo.marriage = '2'
|
||||||
|
}
|
||||||
|
|
||||||
// 2516--除万福卡,投保人、被保险人年收入,默认为0,允许修改
|
// 2516--除万福卡,投保人、被保险人年收入,默认为0,允许修改
|
||||||
if(this.itemProductDTOS.productCode !='GFRS_M0032'){
|
if(this.itemProductDTOS.productCode !='GFRS_M0032'){
|
||||||
@@ -1964,6 +2025,17 @@ export default {
|
|||||||
immediate: true,
|
immediate: true,
|
||||||
deep: true
|
deep: true
|
||||||
},
|
},
|
||||||
|
async 'withRootUser.value'(n) {
|
||||||
|
this.insuredInfo.homeName = getAreaName([
|
||||||
|
{ code: this.userInfo.homeProvince },
|
||||||
|
{ code: this.userInfo.homeCity },
|
||||||
|
{ code: this.userInfo.homeArea },
|
||||||
|
])
|
||||||
|
this.insuredInfo.homeProvince = this.userInfo.homeProvince
|
||||||
|
this.insuredInfo.homeCity = this.userInfo.homeCity
|
||||||
|
this.insuredInfo.homeArea = this.userInfo.homeArea
|
||||||
|
this.insuredInfo.homeAddress = this.userInfo.homeAddress
|
||||||
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
@@ -1989,4 +2061,8 @@ export default {
|
|||||||
color: #333;
|
color: #333;
|
||||||
padding: 15px;
|
padding: 15px;
|
||||||
}
|
}
|
||||||
|
.address {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row-reverse;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
Reference in New Issue
Block a user