Browse Source

djseo

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

42
src/components/patientRegister/PatientRegisterEdit.vue

@ -1017,26 +1017,23 @@ export default {
//
async changeCustomerOrgId(v) {
console.log('changeCustomerOrgId', v, this.form.customerOrgParentId)
let customerOrgId = ""
let customerOrgId = "", customerOrgParentId = ""
if (Array.isArray(v) && v.length > 0) {
customerOrgId = v[v.length - 1]
this.form.customerOrgParentId = v[0]
customerOrgParentId = v[0]
} else {
customerOrgId = v // ID
let pids = getTreePids(this.patientRegister.customerOrgTreeAll, "treeChildren", "parentId", "id", customerOrgId)
if (Array.isArray(pids) && pids.length > 0) {
if (pids.length == 1) {
this.form.customerOrgParentId = customerOrgId
customerOrgParentId = customerOrgId
} else {
this.form.customerOrgParentId = pids[1]
customerOrgParentId = pids[1]
}
}
}
this.preCustomerOrgId = customerOrgId
// let customerOrgParentId = await this.getParentCustomerOrgId(customerOrgId)
let customerOrgParentId = this.form.customerOrgParentId
if (customerOrgParentId) {
if (customerOrgParentId == this.dict.personOrgId) {
@ -1046,24 +1043,25 @@ export default {
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()
}
}
}
},

Loading…
Cancel
Save