[IMP]【电投】优化-被保人证件类型为出生证和户口本时,默认为长期;优化-投被保人年龄小于18周岁,默认工作单位为“无”

This commit is contained in:
yuweiqi
2020-05-06 13:15:36 +08:00
parent 252dc20cb0
commit e69b470b77
2 changed files with 19 additions and 9 deletions

View File

@@ -759,8 +759,8 @@ export default {
if (this.userInfo.idType == '1') {
this.effectiveDateTypeAble = !(age > 45)
}
//年龄小于等于16周岁,工作单位默认值为‘无’
if (age <= 16) {
//年龄18周岁,工作单位默认值为‘无’
if (age < 18) {
this.userInfo.workcompany = this.userInfo.workcompany || '无'
}
}
@@ -1294,8 +1294,8 @@ export default {
this.effectiveDateTypeAble = idToData(val).age <= 45
this.userInfo.birthday = idToData(val).birthday
this.userInfo.sex = idToData(val).sex
//年龄小于等于16周岁,工作单位默认值为‘无’
if (idToData(val).age <= 16) {
//年龄小于18周岁,工作单位默认值为‘无’
if (idToData(val).age < 18) {
this.userInfo.workcompany = this.userInfo.workcompany || '无'
}
if (idToData(val).age > 45) {

View File

@@ -82,7 +82,7 @@
:readonly="isAppnt || idLimit"
></FieldDatePicter> -->
<FieldDatePicter
:v-validate="{ required: certiexpiredateRequired }"
v-validate="{ required: certiexpiredateRequired }"
label="证件截止日期"
name="证件截止日期"
:required="isRequired"
@@ -807,6 +807,11 @@ export default {
if (value.id == '1') {
let age = utilsAge.getAge(this.userInfo.birthday, new Date())
this.effectiveDateTypeAble = age <= 45
} else if (value.id == 2 || value.id == 3) {
this.userInfo.effectiveDateType = true
// this.effectiveDateTypeAble = true
this.userInfo.certiexpiredate = ''
this.$refs.certiexpiredate.date = ''
} else {
// else if (value.id == 2 || value.id == 3) {
// this.effectiveDateTypeAble = true
@@ -993,8 +998,8 @@ export default {
}
//长期判断
let age = utilsAge.getAge(this.userInfo.birthday, new Date())
//年龄小于等于16周岁,工作单位默认值为‘无’
if (age <= 16) {
//年龄小于18周岁,工作单位默认值为‘无’
if (age < 18) {
this.userInfo.workcompany = this.userInfo.workcompany || '无'
}
if (this.userInfo.idType == '1') {
@@ -1157,6 +1162,10 @@ export default {
//下一步
async nextStep() {
let valid = await this.$validator.validate()
// console.log('valid', valid)
// console.log('certiexpiredateRequired', this.certiexpiredateRequired)
// console.log('certiexpiredate', this.userInfo.certiexpiredate)
// return
// .then(valid => {
if (true === valid) {
// 职业 学龄前儿童 2099908 离休人员 8000003家庭主妇 4071203无业人员 8000001
@@ -1568,6 +1577,7 @@ export default {
// this.isRequired = true
// this.idLimit = false
}
this.$forceUpdate()
},
//获取身份证扫描信息
getIdentityInfo(data) {
@@ -1644,8 +1654,8 @@ export default {
this.effectiveDateTypeAble = idToData(val).age <= 45
this.userInfo.birthday = idToData(val).birthday
this.userInfo.sex = idToData(val).sex
//年龄小于等于16周岁,工作单位默认值为‘无’
if (idToData(val).age <= 16) {
//年龄小于18周岁,工作单位默认值为‘无’
if (idToData(val).age < 18) {
this.userInfo.workcompany = this.userInfo.workcompany || '无'
}
if (!from) {