Commit d67f725c by 何为

修改签约提交逻辑

parent e3cefc0a
......@@ -627,7 +627,7 @@ export default {
}
}
this.getOrgInfoFn()
// this.getUserSignInfoFn() // 获取用户签约信息回显
this.getUserSignInfoFn() // 获取用户签约信息回显
},
mounted: function () {
console.log('mounted')
......@@ -961,7 +961,8 @@ export default {
this.saveSignInfoToCookie() // 储存用户签约录入信息
},
BaseValidateIdCard () { // 身份证验证
if (cardid(this.BaseForm.idCard)[0]) {
console.log(cardid(this.BaseForm.idCard)[0])
if (!cardid(this.BaseForm.idCard)[0]) {
this.error.idCard = '请输入有效的女性身份证号'
this.BaseValidate.idCardState = false
console.log('不通过')
......@@ -976,8 +977,8 @@ export default {
this.error.idCard = ''
console.log('通过')
let success = '通过'
return success
this.getManualPriKey()
return success
}
if (this.pageType === 0) {
this.BaseFormIntoTab1()
......@@ -1221,11 +1222,13 @@ export default {
// })
if (parseInt(this.pageType) === 0) {
if (this.signState === '1') { // 已审核通过 跳转至首页
console.log('已审核通过')
this.$router.push({
path: '/home'
})
return
} else if (this.signState === '0') { // 未审核通过 关闭页面
console.log('未审核通过')
this.$toast({
message: '审核周期约三天,请您耐心等待!',
position: 'center',
......@@ -1236,9 +1239,21 @@ export default {
}, 2500)
return
}
if (parseInt(this.noticeCheck[0]) !== 1) {
this.$toast({
message: '请预览签约须知后勾选',
position: 'center',
duration: 3000
})
return false
}
this.SignatureSheetVisible = true
this.modalVisible = true
this.signCanvasW = this.$refs.signCanvasBlock.offsetWidth
return true
}
if (this.pageType === 1) { // 子女
if (parseInt(this.pageType) === 1) { // 子女
let downState = true
for (let i = 0; i < this.childrenArr.length; i++) {
this.tab2Validate(i)
......@@ -1249,23 +1264,33 @@ export default {
if (!downState) {
return false
}
if (parseInt(this.noticeCheck[0]) !== 1) {
this.$toast({
message: '请预览签约须知后勾选',
position: 'center',
duration: 3000
})
return false
}
this.SignatureSheetVisible = true
this.modalVisible = true
this.signCanvasW = this.$refs.signCanvasBlock.offsetWidth
} else if (this.pageType === 0) { // 配偶
if (!this.BaseValidate.nameState || !this.BaseValidate.idCardState || !this.BaseValidate.lastMensesTimeState) {
return false
}
if (parseInt(this.noticeCheck[0]) !== 1) {
this.$toast({
message: '请预览签约须知后勾选',
position: 'center',
duration: 3000
})
return false
}
this.SignatureSheetVisible = true
this.modalVisible = true
this.signCanvasW = this.$refs.signCanvasBlock.offsetWidth
}
if (parseInt(this.noticeCheck[0]) !== 1) {
this.$toast({
message: '请预览签约须知后勾选',
position: 'center',
duration: 3000
})
return false
}
this.SignatureSheetVisible = true
this.modalVisible = true
this.signCanvasW = this.$refs.signCanvasBlock.offsetWidth
},
closeSignPopup () {
this.SignatureSheetVisible = false
......@@ -1290,6 +1315,7 @@ export default {
console.log('submit')
let childrenArr = []
if (this.pageType === 0) {
console.log(this.tab1Form.IdCard.substring(6, 10) + '-' + this.tab1Form.IdCard.substring(10, 12) + '-' + this.tab1Form.IdCard.substring(12, 14))
childrenArr = [
{
birth: this.tab1Form.IdCard.substring(6, 10) + '-' + this.tab1Form.IdCard.substring(10, 12) + '-' + this.tab1Form.IdCard.substring(12, 14),
......@@ -1330,6 +1356,7 @@ export default {
'xngBm': this.addressForm.StreetCode,
'villageBm': this.addressForm.VillagesCode,
'voucherUserId': this.userId,
'doctorId': this.$route.query.doctorId,
'dq': 'wd'
}
console.log(params)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment