|
|
@ -21,13 +21,19 @@ |
|
|
<el-form ref="form" :model="form" label-width="80px" :rules="rules" size="medium"> |
|
|
<el-form ref="form" :model="form" label-width="80px" :rules="rules" size="medium"> |
|
|
<el-row> |
|
|
<el-row> |
|
|
<el-col :span="5"> |
|
|
<el-col :span="5"> |
|
|
<el-form-item label="单位名称" prop="customerOrgId"> |
|
|
|
|
|
|
|
|
<el-form-item label="单位名称" prop="customerOrgName"> |
|
|
|
|
|
<el-input placeholder="请选择单位" v-model="form.customerOrgName" size="small" disabled> |
|
|
|
|
|
<el-button slot="append" icon="el-icon-search" @click="report.dialogCusOrgOCX = true" |
|
|
|
|
|
style="font-size: 20px;"></el-button> |
|
|
|
|
|
</el-input> |
|
|
|
|
|
<!-- |
|
|
<el-cascader v-model="form.customerOrgId" :options="patientRegister.customerOrgTreeAll" |
|
|
<el-cascader v-model="form.customerOrgId" :options="patientRegister.customerOrgTreeAll" |
|
|
:style="'width:' + Math.floor((window.pageWidth - 510) / 4.8) + 'px;'" filterable |
|
|
:style="'width:' + Math.floor((window.pageWidth - 510) / 4.8) + 'px;'" filterable |
|
|
popper-class="example" :show-all-levels="false" @change="changeCustomerOrgId" |
|
|
popper-class="example" :show-all-levels="false" @change="changeCustomerOrgId" |
|
|
:props="{ checkStrictly: true, expandTrigger: 'hover', ...customerOrg.treeprops, }" |
|
|
:props="{ checkStrictly: true, expandTrigger: 'hover', ...customerOrg.treeprops, }" |
|
|
:disabled="(form.completeFlag == '3' || isDoctor != '1') ? true : false" size="small"> |
|
|
:disabled="(form.completeFlag == '3' || isDoctor != '1') ? true : false" size="small"> |
|
|
</el-cascader> |
|
|
</el-cascader> |
|
|
|
|
|
--> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-col> |
|
|
</el-col> |
|
|
<el-col :span="5"> |
|
|
<el-col :span="5"> |
|
|
@ -562,6 +568,8 @@ export default { |
|
|
patientId: "00000000-0000-0000-0000-000000000000", //档案号ID 选择了档案就传档案号,未选就传00000-0000... |
|
|
patientId: "00000000-0000-0000-0000-000000000000", //档案号ID 选择了档案就传档案号,未选就传00000-0000... |
|
|
patientNo: "", //档案号 |
|
|
patientNo: "", //档案号 |
|
|
customerOrgId: ["00000000-0000-0000-0000-000000000001"], //单位编号 默认个人 |
|
|
customerOrgId: ["00000000-0000-0000-0000-000000000001"], //单位编号 默认个人 |
|
|
|
|
|
customerOrgParentId: "", |
|
|
|
|
|
customerOrgName: "", |
|
|
customerOrgRegisterId: "00000000-0000-0000-0000-000000000001", //默认单位体检次数 |
|
|
customerOrgRegisterId: "00000000-0000-0000-0000-000000000001", //默认单位体检次数 |
|
|
customerOrgGroupId: null, //分组 |
|
|
customerOrgGroupId: null, //分组 |
|
|
medicalPackageId: null, //套餐 |
|
|
medicalPackageId: null, //套餐 |
|
|
@ -722,7 +730,7 @@ export default { |
|
|
dddw, moment, checkPagePriv, |
|
|
dddw, moment, checkPagePriv, |
|
|
|
|
|
|
|
|
btnTest() { |
|
|
btnTest() { |
|
|
console.log('form', this.form) |
|
|
|
|
|
|
|
|
// console.log('form', this.form) |
|
|
}, |
|
|
}, |
|
|
//数据初始化 |
|
|
//数据初始化 |
|
|
dictInit() { |
|
|
dictInit() { |
|
|
@ -827,7 +835,7 @@ export default { |
|
|
// } |
|
|
// } |
|
|
// }); |
|
|
// }); |
|
|
|
|
|
|
|
|
// console.log("dict", this.dict); |
|
|
|
|
|
|
|
|
// // console.log("dict", this.dict); |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -843,13 +851,14 @@ export default { |
|
|
|
|
|
|
|
|
} else { |
|
|
} else { |
|
|
// let res = await getapi(`/api/app/patient-register/${patientRegisterId}`) |
|
|
// let res = await getapi(`/api/app/patient-register/${patientRegisterId}`) |
|
|
let res = await postapi(`/api/app/patientregister/getinfoorpatient?PatientRegisterId=${patientRegisterId}`) |
|
|
|
|
|
|
|
|
let res = await postapi('/api/app/patientregister/getinfoorpatient', { patientRegisterId }) |
|
|
// this.form = res.data 这种方式,会造成 checkbox 值变化不响应,故取消 |
|
|
// this.form = res.data 这种方式,会造成 checkbox 值变化不响应,故取消 |
|
|
objCopy(res.data, this.form) |
|
|
objCopy(res.data, this.form) |
|
|
} |
|
|
} |
|
|
this.initBox(); |
|
|
this.initBox(); |
|
|
this.getPeoplePhoto(this.form.photo) |
|
|
this.getPeoplePhoto(this.form.photo) |
|
|
this.dataTransOpts.refresh.register_check_asbitem.D++ //触发所选组合项目刷新 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// this.dataTransOpts.refresh.register_check_asbitem.D++ //触发所选组合项目刷新 |
|
|
|
|
|
|
|
|
// 单位/个人 的分组与套餐处理 |
|
|
// 单位/个人 的分组与套餐处理 |
|
|
this.changeCustomerOrgId(this.form.customerOrgId) |
|
|
this.changeCustomerOrgId(this.form.customerOrgId) |
|
|
@ -859,7 +868,7 @@ export default { |
|
|
|
|
|
|
|
|
//快速选择组合项目时,调整可按拼间简码及简称查找 |
|
|
//快速选择组合项目时,调整可按拼间简码及简称查找 |
|
|
filterMethod(keyWords) { |
|
|
filterMethod(keyWords) { |
|
|
//console.log('filterMethod',this.asbItemQuick) |
|
|
|
|
|
|
|
|
//// console.log('filterMethod',this.asbItemQuick) |
|
|
if (keyWords) { |
|
|
if (keyWords) { |
|
|
this.nation = []; |
|
|
this.nation = []; |
|
|
this.dict.nation.forEach(item => { |
|
|
this.dict.nation.forEach(item => { |
|
|
@ -875,7 +884,7 @@ export default { |
|
|
|
|
|
|
|
|
//选择单位 |
|
|
//选择单位 |
|
|
async changeCustomerOrgId(v) { |
|
|
async changeCustomerOrgId(v) { |
|
|
// console.log('changeCustomerOrgId',v) |
|
|
|
|
|
|
|
|
// // console.log('changeCustomerOrgId',v) |
|
|
let customerOrgId = "" |
|
|
let customerOrgId = "" |
|
|
if (Array.isArray(v) && v.length > 0) { |
|
|
if (Array.isArray(v) && v.length > 0) { |
|
|
customerOrgId = v[v.length - 1] |
|
|
customerOrgId = v[v.length - 1] |
|
|
@ -928,7 +937,7 @@ export default { |
|
|
let res = await getapi(`/api/app/customer-org/parent/${customerOrgId}`) |
|
|
let res = await getapi(`/api/app/customer-org/parent/${customerOrgId}`) |
|
|
if (res.code != -1) customerOrgParentId = res.data |
|
|
if (res.code != -1) customerOrgParentId = res.data |
|
|
} catch (error) { |
|
|
} catch (error) { |
|
|
console.log('获取顶级单位ID出错:', error) |
|
|
|
|
|
|
|
|
// console.log('获取顶级单位ID出错:', error) |
|
|
} |
|
|
} |
|
|
} else if (customerOrgId.length > 0) { |
|
|
} else if (customerOrgId.length > 0) { |
|
|
customerOrgParentId = customerOrgId[0] |
|
|
customerOrgParentId = customerOrgId[0] |
|
|
@ -942,7 +951,7 @@ export default { |
|
|
getapi(`/api/app/customerorgregister/getlistincustomerorgid?CustomerOrgId=${customerOrgParentId}`) |
|
|
getapi(`/api/app/customerorgregister/getlistincustomerorgid?CustomerOrgId=${customerOrgParentId}`) |
|
|
.then(res => { |
|
|
.then(res => { |
|
|
if (res.code > - 1) { |
|
|
if (res.code > - 1) { |
|
|
console.log('获取单位体检次数', this.form.customerOrgRegisterId, res.data) |
|
|
|
|
|
|
|
|
// console.log('获取单位体检次数', this.form.customerOrgRegisterId, res.data) |
|
|
this.customerOrgRegisterList = res.data |
|
|
this.customerOrgRegisterList = res.data |
|
|
if (!this.form.customerOrgRegisterId) { |
|
|
if (!this.form.customerOrgRegisterId) { |
|
|
let customerOrgRegisterList = arrayFilter(res.data, 'isComplete', 'N') //不显示已完成的体检次数 |
|
|
let customerOrgRegisterList = arrayFilter(res.data, 'isComplete', 'N') //不显示已完成的体检次数 |
|
|
@ -967,7 +976,7 @@ export default { |
|
|
return |
|
|
return |
|
|
} |
|
|
} |
|
|
this.$peisAPI.peopleIcCard().then(res => { |
|
|
this.$peisAPI.peopleIcCard().then(res => { |
|
|
console.log('peopleIcCard', res) |
|
|
|
|
|
|
|
|
// console.log('peopleIcCard', res) |
|
|
let lres = JSON.parse(res) |
|
|
let lres = JSON.parse(res) |
|
|
if (lres.code >= -1) { |
|
|
if (lres.code >= -1) { |
|
|
let idNos = parsIcCardtoLocal(lres.data, this.dict.sex, this.dict.nation) |
|
|
let idNos = parsIcCardtoLocal(lres.data, this.dict.sex, this.dict.nation) |
|
|
@ -1125,7 +1134,7 @@ export default { |
|
|
//编辑的时候不查重 |
|
|
//编辑的时候不查重 |
|
|
if (this.form.id || !param) return; |
|
|
if (this.form.id || !param) return; |
|
|
|
|
|
|
|
|
//console.log(`/api/app/patient/in-filter?Filter=${param}`) |
|
|
|
|
|
|
|
|
//// console.log(`/api/app/patient/in-filter?Filter=${param}`) |
|
|
let body = { |
|
|
let body = { |
|
|
filter: param, |
|
|
filter: param, |
|
|
maxResultCount: 500 |
|
|
maxResultCount: 500 |
|
|
@ -1133,7 +1142,7 @@ export default { |
|
|
|
|
|
|
|
|
postapi('/api/app/patient/getlistinfilter', body).then((res) => { |
|
|
postapi('/api/app/patient/getlistinfilter', body).then((res) => { |
|
|
if (res.code > -1) { |
|
|
if (res.code > -1) { |
|
|
console.log("查重 ", res); //有数据才显示 |
|
|
|
|
|
|
|
|
// console.log("查重 ", res); //有数据才显示 |
|
|
if (res.data && res.data.length > 0) { |
|
|
if (res.data && res.data.length > 0) { |
|
|
this.patientList = res.data; |
|
|
this.patientList = res.data; |
|
|
this.dialogVisible = true; |
|
|
this.dialogVisible = true; |
|
|
@ -1224,7 +1233,7 @@ export default { |
|
|
} else { |
|
|
} else { |
|
|
this.form[type] = 'N'; |
|
|
this.form[type] = 'N'; |
|
|
} |
|
|
} |
|
|
console.log('Box-type', this.form[type + 'Box'], this.form[type]) |
|
|
|
|
|
|
|
|
// console.log('Box-type', this.form[type + 'Box'], this.form[type]) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
initBox() { |
|
|
initBox() { |
|
|
@ -1261,8 +1270,8 @@ export default { |
|
|
madePrBody() { |
|
|
madePrBody() { |
|
|
//赋值 |
|
|
//赋值 |
|
|
let body = deepCopy(this.form); |
|
|
let body = deepCopy(this.form); |
|
|
// console.log('this.form',this.form) |
|
|
|
|
|
// console.log('body',body) |
|
|
|
|
|
|
|
|
// // console.log('this.form',this.form) |
|
|
|
|
|
// // console.log('body',body) |
|
|
if (this.form.birthDate) { |
|
|
if (this.form.birthDate) { |
|
|
try { |
|
|
try { |
|
|
body.birthDate = moment(body.birthDate).format("yyyy-MM-DD") |
|
|
body.birthDate = moment(body.birthDate).format("yyyy-MM-DD") |
|
|
@ -1279,7 +1288,7 @@ export default { |
|
|
} else { |
|
|
} else { |
|
|
body.age = Number(body.age) |
|
|
body.age = Number(body.age) |
|
|
} |
|
|
} |
|
|
// console.log('body',body) |
|
|
|
|
|
|
|
|
// // console.log('body',body) |
|
|
// Invalid date |
|
|
// Invalid date |
|
|
|
|
|
|
|
|
delete body.registerManType; |
|
|
delete body.registerManType; |
|
|
@ -1308,7 +1317,7 @@ export default { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
//日期转换 日期控件增加格式 |
|
|
//日期转换 日期控件增加格式 |
|
|
// console.log("body.birthDate", body.birthDate); |
|
|
|
|
|
|
|
|
// // console.log("body.birthDate", body.birthDate); |
|
|
// if (body.birthDate) { |
|
|
// if (body.birthDate) { |
|
|
// body.birthDate = moment(new Date(body.birthDate)).format( |
|
|
// body.birthDate = moment(new Date(body.birthDate)).format( |
|
|
// "yyyy-MM-DD" |
|
|
// "yyyy-MM-DD" |
|
|
@ -1320,7 +1329,7 @@ export default { |
|
|
//提交 |
|
|
//提交 |
|
|
btnSubmit(formName, msgTip) { |
|
|
btnSubmit(formName, msgTip) { |
|
|
this.$refs[formName].validate((valid, fields) => { |
|
|
this.$refs[formName].validate((valid, fields) => { |
|
|
console.log('fields', fields) |
|
|
|
|
|
|
|
|
// console.log('fields', fields) |
|
|
if (!valid) { |
|
|
if (!valid) { |
|
|
this.$message.warning({ showClose: true, message: fields[Object.keys(fields)[0]][0].message }); |
|
|
this.$message.warning({ showClose: true, message: fields[Object.keys(fields)[0]][0].message }); |
|
|
return false |
|
|
return false |
|
|
@ -1347,7 +1356,7 @@ export default { |
|
|
} else { |
|
|
} else { |
|
|
delete body.id; |
|
|
delete body.id; |
|
|
} |
|
|
} |
|
|
// console.log(`/api/patientregister/createreturninfo`, body); |
|
|
|
|
|
|
|
|
// // console.log(`/api/patientregister/createreturninfo`, body); |
|
|
postapi(`/api/PatientRegister/CreatePatientRegister`, body) |
|
|
postapi(`/api/PatientRegister/CreatePatientRegister`, body) |
|
|
.then(res => { |
|
|
.then(res => { |
|
|
if (res.code == 1) { |
|
|
if (res.code == 1) { |
|
|
@ -1419,7 +1428,7 @@ export default { |
|
|
e.isCharge = 'N' |
|
|
e.isCharge = 'N' |
|
|
e.isLock = 'N' |
|
|
e.isLock = 'N' |
|
|
}); |
|
|
}); |
|
|
// console.log('this.patientRegister.patientRegisterAbs',this.patientRegister.patientRegisterAbs) |
|
|
|
|
|
|
|
|
// // console.log('this.patientRegister.patientRegisterAbs',this.patientRegister.patientRegisterAbs) |
|
|
this.$message.info({ showClose: true, message: "操作成功,请记得点保存" }); |
|
|
this.$message.info({ showClose: true, message: "操作成功,请记得点保存" }); |
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
@ -1429,7 +1438,7 @@ export default { |
|
|
deletapi( |
|
|
deletapi( |
|
|
`/api/app/customer-org/${this.customerOrg.customerOrgRd.id}` |
|
|
`/api/app/customer-org/${this.customerOrg.customerOrgRd.id}` |
|
|
).then((res) => { |
|
|
).then((res) => { |
|
|
console.log("删除 操作成功"); |
|
|
|
|
|
|
|
|
// console.log("删除 操作成功"); |
|
|
this.setData({ key: "customerOrg.customerOrgRd", value: { id: "" } }); |
|
|
this.setData({ key: "customerOrg.customerOrgRd", value: { id: "" } }); |
|
|
this.getCustomerOrgTree(); |
|
|
this.getCustomerOrgTree(); |
|
|
}); |
|
|
}); |
|
|
@ -1456,7 +1465,7 @@ export default { |
|
|
} |
|
|
} |
|
|
this.$peisAPI.photoGrah() |
|
|
this.$peisAPI.photoGrah() |
|
|
.then(res => { |
|
|
.then(res => { |
|
|
console.log('this.$peisAPI.photoGrah 原始返回结果', res) |
|
|
|
|
|
|
|
|
// console.log('this.$peisAPI.photoGrah 原始返回结果', res) |
|
|
let lres = JSON.parse(res) |
|
|
let lres = JSON.parse(res) |
|
|
if (lres.code > -1) { |
|
|
if (lres.code > -1) { |
|
|
let uploadPhoto = { |
|
|
let uploadPhoto = { |
|
|
@ -1475,17 +1484,17 @@ export default { |
|
|
patientRegisterId: this.form.id, |
|
|
patientRegisterId: this.form.id, |
|
|
photo: res.data, |
|
|
photo: res.data, |
|
|
}; |
|
|
}; |
|
|
console.log(body); |
|
|
|
|
|
|
|
|
// console.log(body); |
|
|
return postapi(`/api/app/patient-register/update-photo`, body); |
|
|
return postapi(`/api/app/patient-register/update-photo`, body); |
|
|
} |
|
|
} |
|
|
}).then(res => { |
|
|
}).then(res => { |
|
|
if (res && res.code > -1) { |
|
|
if (res && res.code > -1) { |
|
|
//console.log('拍照',res.data) |
|
|
|
|
|
|
|
|
//// console.log('拍照',res.data) |
|
|
this.patientRegister.patientRegisterRd.photo = res.data.photo |
|
|
this.patientRegister.patientRegisterRd.photo = res.data.photo |
|
|
console.log("操作成功"); |
|
|
|
|
|
|
|
|
// console.log("操作成功"); |
|
|
} |
|
|
} |
|
|
}).catch(err => { |
|
|
}).catch(err => { |
|
|
console.log('this.$peisAPI.photoGrah', err) |
|
|
|
|
|
|
|
|
// console.log('this.$peisAPI.photoGrah', err) |
|
|
this.$message.error({ showClose: true, message: `照片操作错误 ${err}` }) |
|
|
this.$message.error({ showClose: true, message: `照片操作错误 ${err}` }) |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
@ -1526,7 +1535,7 @@ export default { |
|
|
.then((res) => { |
|
|
.then((res) => { |
|
|
if (res.code != -1) { |
|
|
if (res.code != -1) { |
|
|
toOutShell.ReportTable = res.data; |
|
|
toOutShell.ReportTable = res.data; |
|
|
console.log('JSON.stringify(toOutShell)', JSON.stringify(toOutShell)); |
|
|
|
|
|
|
|
|
// console.log('JSON.stringify(toOutShell)', JSON.stringify(toOutShell)); |
|
|
return this.$peisAPI.printPre(JSON.stringify(toOutShell)); |
|
|
return this.$peisAPI.printPre(JSON.stringify(toOutShell)); |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
@ -1536,13 +1545,13 @@ export default { |
|
|
*/ |
|
|
*/ |
|
|
this.$peisAPI.printPre(JSON.stringify(toOutShell)) |
|
|
this.$peisAPI.printPre(JSON.stringify(toOutShell)) |
|
|
.then(res => { |
|
|
.then(res => { |
|
|
console.log('this.$peisAPI.printPre', res) |
|
|
|
|
|
|
|
|
// console.log('this.$peisAPI.printPre', res) |
|
|
if (JSON.parse(res).code < 0) { |
|
|
if (JSON.parse(res).code < 0) { |
|
|
this.$message.warning({ showClose: true, message: JSON.parse(res).message }); |
|
|
this.$message.warning({ showClose: true, message: JSON.parse(res).message }); |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
.catch((err) => { |
|
|
.catch((err) => { |
|
|
console.log('打印指引单错误', err) |
|
|
|
|
|
|
|
|
// console.log('打印指引单错误', err) |
|
|
this.$message.warning({ showClose: true, message: `${err}` }); |
|
|
this.$message.warning({ showClose: true, message: `${err}` }); |
|
|
}); |
|
|
}); |
|
|
} else { |
|
|
} else { |
|
|
@ -1551,7 +1560,7 @@ export default { |
|
|
// .then((res) => { |
|
|
// .then((res) => { |
|
|
// if (res.code != -1) { |
|
|
// if (res.code != -1) { |
|
|
// toOutShell.ReportTable = res.data; |
|
|
// toOutShell.ReportTable = res.data; |
|
|
// console.log('JSON.stringify(toOutShell)', JSON.stringify(toOutShell)); |
|
|
|
|
|
|
|
|
// // console.log('JSON.stringify(toOutShell)', JSON.stringify(toOutShell)); |
|
|
// return this.$peisAPI.print(JSON.stringify(toOutShell)); |
|
|
// return this.$peisAPI.print(JSON.stringify(toOutShell)); |
|
|
// } |
|
|
// } |
|
|
// }) |
|
|
// }) |
|
|
@ -1598,7 +1607,7 @@ export default { |
|
|
|
|
|
|
|
|
try { |
|
|
try { |
|
|
res = await postapi(`/api/app/lisrequest/setlisrequest?PatientRegisterId=${this.form.id}`); |
|
|
res = await postapi(`/api/app/lisrequest/setlisrequest?PatientRegisterId=${this.form.id}`); |
|
|
console.log(`/api/app/lisrequest/setlisrequest?PatientRegisterId=${this.form.id}`, res) |
|
|
|
|
|
|
|
|
// console.log(`/api/app/lisrequest/setlisrequest?PatientRegisterId=${this.form.id}`, res) |
|
|
} catch (error) { |
|
|
} catch (error) { |
|
|
return; |
|
|
return; |
|
|
} |
|
|
} |
|
|
@ -1655,26 +1664,26 @@ export default { |
|
|
{ Name: 'hisLog', Value: 'pic/hisLog.jpg' }, |
|
|
{ Name: 'hisLog', Value: 'pic/hisLog.jpg' }, |
|
|
], |
|
|
], |
|
|
}; |
|
|
}; |
|
|
console.log('this.$peisAPI.print', toOutShell) |
|
|
|
|
|
|
|
|
// console.log('this.$peisAPI.print', toOutShell) |
|
|
if (isPreview) { |
|
|
if (isPreview) { |
|
|
this.$peisAPI.printPre(JSON.stringify(toOutShell)) |
|
|
this.$peisAPI.printPre(JSON.stringify(toOutShell)) |
|
|
.then(res => { |
|
|
.then(res => { |
|
|
let lres = JSON.parse(res) |
|
|
let lres = JSON.parse(res) |
|
|
console.log('this.$peisAPI.printPre', lres) |
|
|
|
|
|
|
|
|
// console.log('this.$peisAPI.printPre', lres) |
|
|
if (lres.code < 0) { |
|
|
if (lres.code < 0) { |
|
|
console.log('打印检验条码错误', lres.message) |
|
|
|
|
|
|
|
|
// console.log('打印检验条码错误', lres.message) |
|
|
this.$message.warning({ showClose: true, message: lres.message }); |
|
|
this.$message.warning({ showClose: true, message: lres.message }); |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
.catch((err) => { |
|
|
.catch((err) => { |
|
|
console.log('打印检验条码错误', err) |
|
|
|
|
|
|
|
|
// console.log('打印检验条码错误', err) |
|
|
this.$message.warning({ showClose: true, message: `${err}` }); |
|
|
this.$message.warning({ showClose: true, message: `${err}` }); |
|
|
}); |
|
|
}); |
|
|
} else { |
|
|
} else { |
|
|
this.$peisAPI.print(JSON.stringify(toOutShell)) |
|
|
this.$peisAPI.print(JSON.stringify(toOutShell)) |
|
|
.then(res => { |
|
|
.then(res => { |
|
|
let lres = JSON.parse(res) |
|
|
let lres = JSON.parse(res) |
|
|
console.log('打印检验条码', lres) |
|
|
|
|
|
|
|
|
// console.log('打印检验条码', lres) |
|
|
if (res && lres.code > -1) { |
|
|
if (res && lres.code > -1) { |
|
|
return postapi('/api/app/lisrequest/updatelisrequestisprint', { operateType: 1, patientRegisterId: this.form.id }) |
|
|
return postapi('/api/app/lisrequest/updatelisrequestisprint', { operateType: 1, patientRegisterId: this.form.id }) |
|
|
} else { |
|
|
} else { |
|
|
@ -1811,10 +1820,10 @@ export default { |
|
|
triggerHeadSave() { |
|
|
triggerHeadSave() { |
|
|
//id不为空则编辑 api/patientregister/updatepatientregister |
|
|
//id不为空则编辑 api/patientregister/updatepatientregister |
|
|
let body = this.madePrBody() |
|
|
let body = this.madePrBody() |
|
|
// console.log(`/api/patientregister/updatepatientregister?PatientRegisterId=${this.form.id}`, body); |
|
|
|
|
|
|
|
|
// // console.log(`/api/patientregister/updatepatientregister?PatientRegisterId=${this.form.id}`, body); |
|
|
postapi(`/api/patientregister/updatepatientregister?PatientRegisterId=${this.form.id}`, body).then((res) => { |
|
|
postapi(`/api/patientregister/updatepatientregister?PatientRegisterId=${this.form.id}`, body).then((res) => { |
|
|
if (res.code != -1) { |
|
|
if (res.code != -1) { |
|
|
console.log("操作成功"); |
|
|
|
|
|
|
|
|
// console.log("操作成功"); |
|
|
//一般读身份证照片时,会出现这种情况 |
|
|
//一般读身份证照片时,会出现这种情况 |
|
|
if (this.patientRegister.photo && this.patientRegister.photo.indexOf("data:image") > -1) savePeoplePhoto(this.form.id, this.patientRegister.photo); |
|
|
if (this.patientRegister.photo && this.patientRegister.photo.indexOf("data:image") > -1) savePeoplePhoto(this.form.id, this.patientRegister.photo); |
|
|
objCopy(this.form, this.patientRegister.patientRegisterRd); |
|
|
objCopy(this.form, this.patientRegister.patientRegisterRd); |
|
|
@ -1827,7 +1836,7 @@ export default { |
|
|
|
|
|
|
|
|
// 新增保存基本信息产生新的ID,等明细保存后,再更新表单form.id |
|
|
// 新增保存基本信息产生新的ID,等明细保存后,再更新表单form.id |
|
|
refreshFormId() { |
|
|
refreshFormId() { |
|
|
console.log('refreshFormId', this.prAsbOpraOpts.formId) |
|
|
|
|
|
|
|
|
// console.log('refreshFormId', this.prAsbOpraOpts.formId) |
|
|
this.form.id = this.prAsbOpraOpts.formId |
|
|
this.form.id = this.prAsbOpraOpts.formId |
|
|
this.prAsbOpraOpts.formId = '' //清空 |
|
|
this.prAsbOpraOpts.formId = '' //清空 |
|
|
|
|
|
|
|
|
@ -1846,14 +1855,14 @@ export default { |
|
|
enterToTab() { |
|
|
enterToTab() { |
|
|
this.$nextTick(() => { |
|
|
this.$nextTick(() => { |
|
|
let inputs = document.querySelectorAll("form input"); //用数组可以读取多个标签的元素 //.inline-input |
|
|
let inputs = document.querySelectorAll("form input"); //用数组可以读取多个标签的元素 //.inline-input |
|
|
//console.log('inputs',inputs); |
|
|
|
|
|
|
|
|
//// console.log('inputs',inputs); |
|
|
// 为每个输入框添加键盘事件监听器 |
|
|
// 为每个输入框添加键盘事件监听器 |
|
|
inputs.forEach((input, i) => { |
|
|
inputs.forEach((input, i) => { |
|
|
|
|
|
|
|
|
input.addEventListener('keydown', (event) => { |
|
|
input.addEventListener('keydown', (event) => { |
|
|
|
|
|
|
|
|
// 如果按下的是回车键 |
|
|
// 如果按下的是回车键 |
|
|
// console.log('data-ismultiline',input.getAttribute('data-ismultiline')); |
|
|
|
|
|
|
|
|
// // console.log('data-ismultiline',input.getAttribute('data-ismultiline')); |
|
|
|
|
|
|
|
|
if (event.keyCode === 13) { |
|
|
if (event.keyCode === 13) { |
|
|
// 阻止回车键的默认行为(换行) |
|
|
// 阻止回车键的默认行为(换行) |
|
|
@ -1880,14 +1889,14 @@ export default { |
|
|
"dataTransOpts.refresh.patient_register.S": { |
|
|
"dataTransOpts.refresh.patient_register.S": { |
|
|
// immediate: true, |
|
|
// immediate: true, |
|
|
async handler(newVal, oldVal) { |
|
|
async handler(newVal, oldVal) { |
|
|
console.log(`watch 人员登记 newVal:${newVal} oldVal:${oldVal} registerCheckId: ${this.dataTransOpts.tableS.patient_register.id}`); |
|
|
|
|
|
|
|
|
// console.log(`watch 人员登记 newVal:${newVal} oldVal:${oldVal} registerCheckId: ${this.dataTransOpts.tableS.patient_register.id}`); |
|
|
if (newVal != oldVal) await this.initFormData(this.dataTransOpts.tableS.patient_register.id) |
|
|
if (newVal != oldVal) await this.initFormData(this.dataTransOpts.tableS.patient_register.id) |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
//拍照触发 |
|
|
//拍照触发 |
|
|
// "form.photo"(newVal, oldVal) { |
|
|
// "form.photo"(newVal, oldVal) { |
|
|
// //console.log('patientRegister.patientRegisterRd.id newVal:',newVal,' oldVal:',oldVal) |
|
|
|
|
|
|
|
|
// //// console.log('patientRegister.patientRegisterRd.id newVal:',newVal,' oldVal:',oldVal) |
|
|
// if (newVal != oldVal) { |
|
|
// if (newVal != oldVal) { |
|
|
// this.getPeoplePhoto(newVal) |
|
|
// this.getPeoplePhoto(newVal) |
|
|
// } |
|
|
// } |
|
|
@ -1898,7 +1907,7 @@ export default { |
|
|
// // immediate:true, |
|
|
// // immediate:true, |
|
|
// // // deep:true, |
|
|
// // // deep:true, |
|
|
// handler(newVal, oldVal) { |
|
|
// handler(newVal, oldVal) { |
|
|
// //console.log('patientRegister.patientRegisterRd.id newVal:',newVal,' oldVal:',oldVal) |
|
|
|
|
|
|
|
|
// //// console.log('patientRegister.patientRegisterRd.id newVal:',newVal,' oldVal:',oldVal) |
|
|
// if (newVal != oldVal) { |
|
|
// if (newVal != oldVal) { |
|
|
// this.changeCustomerOrgId(newVal) |
|
|
// this.changeCustomerOrgId(newVal) |
|
|
// } |
|
|
// } |
|
|
@ -1908,12 +1917,12 @@ export default { |
|
|
// 从体检人员登记列表 点登记,触发 |
|
|
// 从体检人员登记列表 点登记,触发 |
|
|
// 清空查询条件 |
|
|
// 清空查询条件 |
|
|
"dataTransOpts.plus.clearPatientRegisterQuery": { |
|
|
"dataTransOpts.plus.clearPatientRegisterQuery": { |
|
|
immediate: true, |
|
|
|
|
|
|
|
|
// immediate: true, |
|
|
handler(newVal, oldVal) { |
|
|
handler(newVal, oldVal) { |
|
|
console.log('从体检人员登记列表 点登记,触发', newVal, oldVal) |
|
|
|
|
|
|
|
|
// console.log('从体检人员登记列表 点登记,触发', newVal, oldVal) |
|
|
if (newVal != oldVal) { |
|
|
if (newVal != oldVal) { |
|
|
this.preCustomerOrgId = this.patientRegister.query.customerOrgId |
|
|
this.preCustomerOrgId = this.patientRegister.query.customerOrgId |
|
|
console.log('this.preCustomerOrgId', this.preCustomerOrgId) |
|
|
|
|
|
|
|
|
// console.log('this.preCustomerOrgId', this.preCustomerOrgId) |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
@ -1922,6 +1931,10 @@ export default { |
|
|
}; |
|
|
}; |
|
|
</script> |
|
|
</script> |
|
|
<style scoped> |
|
|
<style scoped> |
|
|
|
|
|
::v-deep .el-icon-search:before { |
|
|
|
|
|
color: #00F; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
.btn { |
|
|
.btn { |
|
|
margin-top: 5px; |
|
|
margin-top: 5px; |
|
|
} |
|
|
} |
|
|
|