pengjun 2 years ago
parent
commit
62b0a2d5cc
  1. 4
      src/components/patientRegister/PatientRegisterEdit.vue
  2. 25
      src/components/patientRegister/PatientRegisterList.vue

4
src/components/patientRegister/PatientRegisterEdit.vue

@ -1299,12 +1299,12 @@ export default {
if (res.code == 1) {
//
this.prAsbOpraOpts.formId = res.data.id
this.dataTransOpts.tableS.patient_register.id = res.data.id
this.dataTransOpts.tableS.patient_register = deepCopy(res.data)
let temp = Object.assign({}, res.data, { id: '' })
objCopy(temp, this.form)
//
this.refreshRegister(Object.assign({}, res.data))
// this.refreshRegister(Object.assign({}, res.data))
//
if (this.patientRegister.photo && this.patientRegister.photo.indexOf("data:image") > -1) savePeoplePhoto(res.data.id, this.patientRegister.photo);

25
src/components/patientRegister/PatientRegisterList.vue

@ -666,20 +666,21 @@ export default {
if(!id) return
this.dataTransOpts.tableS.patient_register.id = id
// let res = await postapi(`/api/app/patientregister/getinfoorpatient?PatientRegisterId=${this.dataTransOpts.tableS.patient_register.id}`)
// if (res.code != 1) return
let res = await postapi(`/api/app/patientregister/getinfoorpatient?PatientRegisterId=${this.dataTransOpts.tableS.patient_register.id}`)
if (res.code != 1) return
let currentRow = res.data
// this.tableData.forEach(e => {
// e.choosed = false
// });
let lfind = arrayExistObj(this.tableData, 'id', this.dataTransOpts.tableS.patient_register.id)
if (lfind > -1) {
objCopy(this.tableDataCurrentRow,this.tableData[lfind])
objCopy(currentRow,this.tableData[lfind])
} else {
lfind = this.tableData.length
this.tableDataCurrentRow.index = lfind
this.tableDataCurrentRow.choosed = true
this.tableData.push(this.tableDataCurrentRow)
currentRow.index = lfind
currentRow.choosed = true
this.tableData.push(currentRow)
}
// register_check_asbitem
@ -744,9 +745,13 @@ export default {
.then((res) => {
if (res.code != -1) {
console.log("操作成功");
arrayReduce(this.tableData, this.multipleSelection, 'id=id')
this.setForm(this.patientRegister.patientRegisterRdInit)
this.getPatientRegisterAbs();
this.dataTransOpts.tableS.patient_register.id = ''
setTimeout(() => {
this.dataTransOpts.refresh.register_check_asbitem.M++
}, 10);
arrayReduce(this.tableData, this.multipleSelection, 'id=id') //
// this.setForm(this.patientRegister.patientRegisterRdInit)
// this.getPatientRegisterAbs();
}
})
.catch((err) => {

Loading…
Cancel
Save