{{ checkTest.title }}
@@ -164,7 +164,7 @@ export default {
},
methods: {
- ...mapMutations('carbasics', ['setRefreshList']),
+ ...mapMutations('carbasics', ['setRefreshList', 'setFirstAidId']),
// 上传图片成功时
successUpload(res) {
const { code, data } = res;
@@ -205,19 +205,24 @@ export default {
this.codeValue[code] = e;
},
// 输入框失去焦点
- iptBlur(code) {
+ iptBlur(e, code) {
+ console.log('e: ', e);
if (code === 'CJBL-idCard') {
- if (this.codeValue['CJBL-idCard']) {
- this.isFit = this.isIdentityId(this.codeValue['CJBL-idCard']);
- const idcard = this.codeValue['CJBL-idCard'];
- if (this.codeValue['CJBL-idCard'].length === 15) {
+ if (e) {
+ this.isFit = this.isIdentityId(e);
+ const idcard = e;
+ if (e.length === 15) {
this.codeValue['CJBL-SEX'] = (idcard[idcard.length - 1] - 0) % 2;
- } else if (this.codeValue['CJBL-idCard'].length === 18) {
+ } else if (e.length === 18) {
this.codeValue['CJBL-SEX'] = (idcard[idcard.length - 2] - 0) % 2;
}
+ this.codeValue[code] = e;
+ console.log(code, this.codeValue[code]);
} else {
this.isFit = true;
}
+ } else {
+ this.codeValue[code] = e;
}
},
// 验证身份证
@@ -315,9 +320,9 @@ export default {
type: 'success',
});
this.firstAidId = data.firstAidId;
+ this.setFirstAidId(data.firstAidId);
this.isSubmit = false;
if (this.role === 'YiSheng') {
- console.log('data: ', data);
// this.visible = true;
this.handleOk(this.globalData.createAuth - 0 === 0 ? 1 : 0);
uni.navigateBack();
diff --git a/src/pages/inner/inner.vue b/src/pages/inner/inner.vue
index fe44422..435fb4a 100644
--- a/src/pages/inner/inner.vue
+++ b/src/pages/inner/inner.vue
@@ -115,10 +115,10 @@ export default {
if (key === value) {
if (Array.isArray(this.codeValue[this.type][key])) {
this.codeValue[this.type][key] = recordList[value];
-
break;
} else {
this.codeValue[this.type][key] = recordList[value][0];
+ console.log(key, this.codeValue[this.type][key]);
break;
}
}
@@ -151,6 +151,9 @@ export default {
const itemN = itemK[m].itemList[n];
// console.log('itemN: ', itemN);
itemK[m].itemIsChecked[n].checked = this.getCheckedStatus(itemN, itemK[m].value);
+ if (itemK[m].code === 'JMRS-BFZ') {
+ console.log('itemK[m].itemIsChecked[n].checked: ', itemK[m].itemIsChecked[n].checked);
+ }
}
}
}
diff --git a/src/pages/patient/patient.vue b/src/pages/patient/patient.vue
index f74187f..f015660 100644
--- a/src/pages/patient/patient.vue
+++ b/src/pages/patient/patient.vue
@@ -247,7 +247,7 @@ export default {
param.idcard = e;
}
if (questionCode !== 'CJBL-idCard' || (questionCode === 'CJBL-idCard' && e.length === 18)) {
- this.updateData(param);
+ this.updateData(param, 1);
}
},
// 验证身份证
@@ -323,13 +323,15 @@ export default {
return errorMsg;
},
// 修改患者信息
- async updateData(param) {
+ async updateData(param, type) {
try {
await this.$u.api.updatePatient(param);
- this.$refs.uToast.show({
- title: '修改成功',
- type: 'ssuccess',
- });
+ if (!type) {
+ this.$refs.uToast.show({
+ title: '修改成功',
+ type: 'ssuccess',
+ });
+ }
} catch (error) {
this.$refs.uToast.show({
title: '修改失败',
diff --git a/src/pages/patientLine/patientLine.vue b/src/pages/patientLine/patientLine.vue
index 2e409d9..2702c9b 100644
--- a/src/pages/patientLine/patientLine.vue
+++ b/src/pages/patientLine/patientLine.vue
@@ -116,7 +116,6 @@ export default {
methods: {
...mapMutations('carbasics', ['setInputCode']),
jump(code, path) {
- console.log('path: ', path);
this.setInputCode(code ? code : 'RYPG');
uni.navigateTo({ url: path });
},