[FIX]证件截止日期与长期修改

This commit is contained in:
zhouna
2019-12-30 17:17:52 +08:00
parent b7242cef8c
commit 3deffc5b11
4 changed files with 33 additions and 13 deletions

View File

@@ -26,7 +26,7 @@ export default {
maxDate: {
type: Date,
default: () => {
return new Date('2039-12-31')
return new Date('2040-12-31')
}
},
disabled: {

View File

@@ -623,8 +623,13 @@ export default {
this.userInfo.idType = data.customerIdType //证件类型
this.userInfo.idNo = data.customerIdNumber //证件号码
// this.userInfo.certificateValidate = data.idEffectStartDate //证件起始日期
// this.userInfo.certiexpiredate = data.idEffectEndDate //证件截止日期
// this.userInfo.effectiveDateType = data.idEffectEndDate == '9999-01-01' //是否长期
if (data.idEffectEndDate == '9999-01-01') {
this.userInfo.effectiveDateType = true //是否长期
} else {
this.userInfo.certiexpiredate = data.idEffectEndDate //证件截止日期
this.userInfo.effectiveDateType = data.idEffectEndDate == '9999-01-01' //是否长期
}
this.userInfo.occupationCode = data.occupationCode //职业类别编码
this.userInfo.occupationName = data.occupationName //职业类别名称
this.userInfo.lifeGrade = data.lifeGrade //寿险等级
@@ -645,7 +650,7 @@ export default {
//数据是否从客户列表拉取
this.fromCustomer = true
this.getRelatedData(this.userInfo.idNo)
this.getRelatedData(this.userInfo.idNo, '1')
},
nextStep() {
// 计算年龄
@@ -989,7 +994,7 @@ export default {
day = day.toString().padStart(2, '0')
return `${year}-${month}-${day}`
},
getRelatedData(val) {
getRelatedData(val, from) {
if (this.userInfo.idType != '1') {
return
}
@@ -1017,6 +1022,9 @@ export default {
// this.idLimit = true
// this.isRequired = false
// this.userInfo.effectiveDateType = true
if (from) {
this.userInfo.effectiveDateType = true
}
this.effectiveDateTypeAble = false
} else {
// this.idLimit = false

View File

@@ -691,8 +691,11 @@ export default {
this.userInfo.idType = data.customerIdType //证件类型
this.userInfo.idNo = data.customerIdNumber //证件类别
// this.userInfo.certificateValidate = data.idEffectStartDate //证件起始日期
if (data.idEffectEndDate == '9999-01-01') {
this.userInfo.effectiveDateType = true //是否长期
} else {
this.userInfo.certiexpiredate = data.idEffectEndDate //证件截止日期
this.userInfo.effectiveDateType = data.idEffectEndDate == '9999-01-01' //是否长期
}
this.userInfo.occupationCode = data.occupationCode //职业类别编码
this.userInfo.occupationName = data.occupationName //职业类别名称
this.userInfo.salarySource = data.salarySource //收入来源
@@ -741,7 +744,7 @@ export default {
// 长期按钮是否禁用
this.effectiveDateTypeAble = age <= 45
this.getRelatedData(this.userInfo.idNo)
this.getRelatedData(this.userInfo.idNo, '1')
},
nextStep() {
// console.log(this.userInfo.idType)
@@ -1085,7 +1088,7 @@ export default {
return this.$toast('体重输入有误')
}
},
getRelatedData(val) {
getRelatedData(val,source) {
if (this.userInfo.idType != '1') {
return
}
@@ -1099,7 +1102,9 @@ export default {
this.userInfo.birthday = idToData(val).birthday
this.userInfo.sex = idToData(val).sex
if (idToData(val).age > 45) {
//this.userInfo.effectiveDateType = true
if(source){
this.userInfo.effectiveDateType = true
}
this.effectiveDateTypeAble = false
} else {
// this.userInfo.effectiveDateType = false

View File

@@ -1038,8 +1038,13 @@ export default {
this.userInfo.idType = data.customerIdType //证件类型
this.userInfo.idNo = data.customerIdNumber //证件号码
// this.userInfo.certificateValidate = data.idEffectStartDate //证件起始日期
// this.userInfo.certiexpiredate = data.idEffectEndDate //证件截止日期
// this.userInfo.effectiveDateType = data.idEffectEndDate == '9999-01-01' //是否长期
if (data.idEffectEndDate == '9999-01-01') {
this.userInfo.effectiveDateType = true //是否长期
} else {
this.userInfo.certiexpiredate = data.idEffectEndDate //证件截止日期
this.userInfo.effectiveDateType = data.idEffectEndDate == '9999-01-01' //是否长期
}
this.userInfo.occupationCode = data.occupationCode //职业类别编码
this.userInfo.occupationName = data.occupationName //职业类别名称
this.userInfo.salarySource = data.salarySource //收入来源
@@ -1489,7 +1494,9 @@ export default {
if (idToData(val).age > 45) {
// this.idLimit = true
// this.isRequired = false
// this.userInfo.effectiveDateType = true
if (from) {
this.userInfo.effectiveDateType = true
}
this.effectiveDateTypeAble = false
} else {
// this.idLimit = false