Browse Source

djseo

master
pengjun 2 years ago
parent
commit
50f244ebdc
  1. 46
      src/components/patientRegister/PatientRegisterEdit.vue

46
src/components/patientRegister/PatientRegisterEdit.vue

@ -1017,26 +1017,23 @@ export default {
// //
async changeCustomerOrgId(v) { async changeCustomerOrgId(v) {
console.log('changeCustomerOrgId', v, this.form.customerOrgParentId) console.log('changeCustomerOrgId', v, this.form.customerOrgParentId)
let customerOrgId = ""
let customerOrgId = "", customerOrgParentId = ""
if (Array.isArray(v) && v.length > 0) { if (Array.isArray(v) && v.length > 0) {
customerOrgId = v[v.length - 1] customerOrgId = v[v.length - 1]
this.form.customerOrgParentId = v[0]
customerOrgParentId = v[0]
} else { } else {
customerOrgId = v // ID customerOrgId = v // ID
let pids = getTreePids(this.patientRegister.customerOrgTreeAll, "treeChildren", "parentId", "id", customerOrgId) let pids = getTreePids(this.patientRegister.customerOrgTreeAll, "treeChildren", "parentId", "id", customerOrgId)
if (Array.isArray(pids) && pids.length > 0) { if (Array.isArray(pids) && pids.length > 0) {
if (pids.length == 1) { if (pids.length == 1) {
this.form.customerOrgParentId = customerOrgId
customerOrgParentId = customerOrgId
} else { } else {
this.form.customerOrgParentId = pids[1]
customerOrgParentId = pids[1]
} }
} }
} }
this.preCustomerOrgId = customerOrgId this.preCustomerOrgId = customerOrgId
// let customerOrgParentId = await this.getParentCustomerOrgId(customerOrgId) // let customerOrgParentId = await this.getParentCustomerOrgId(customerOrgId)
let customerOrgParentId = this.form.customerOrgParentId
if (customerOrgParentId) { if (customerOrgParentId) {
if (customerOrgParentId == this.dict.personOrgId) { if (customerOrgParentId == this.dict.personOrgId) {
@ -1046,24 +1043,25 @@ export default {
this.getCustomerOrgRegisterList(customerOrgParentId) this.getCustomerOrgRegisterList(customerOrgParentId)
} }
// /
this.form.customerOrgGroupId = null
this.form.medicalPackageId = null
//
this.dataTransOpts.tableM.register_check_asbitem.forEach(e => {
e.isBelongGroupPackage = 'N'
});
// / ID
if (customerOrgParentId != this.form.customerOrgParentId) {
this.form.customerOrgGroupId = null
this.form.medicalPackageId = null
//
this.dataTransOpts.tableM.register_check_asbitem.forEach(e => {
e.isBelongGroupPackage = 'N'
});
if (customerOrgParentId == this.dict.personOrgId) {
this.patientRegister.customerOrgGroup = []
}
if (customerOrgParentId == this.dict.personOrgId) {
this.patientRegister.customerOrgGroup = []
}
if (this.form.customerOrgParentId == this.dict.personOrgId) {
this.changeMedicalPackageId()
} else {
this.changeCustomerOrgGroupId()
if (this.form.customerOrgParentId == this.dict.personOrgId) {
this.changeMedicalPackageId()
} else {
this.changeCustomerOrgGroupId()
}
} }
} }
}, },
@ -1492,12 +1490,12 @@ export default {
this.guidePrint('0001', false) this.guidePrint('0001', false)
this.labelPrint(false) this.labelPrint(false)
})
})
.catch((err) => { .catch((err) => {
// if (err == "cancel") { // if (err == "cancel") {
// this.$message.info({ showClose: true, message: "" }); // this.$message.info({ showClose: true, message: "" });
// } // }
});
});
} }
} }
} }

Loading…
Cancel
Save