Commit d67f725c by 何为

修改签约提交逻辑

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