diff --git a/public/files/检验结果导入模板_横向.xls b/public/files/检验结果导入模板_横向.xls new file mode 100644 index 0000000..e134371 Binary files /dev/null and b/public/files/检验结果导入模板_横向.xls differ diff --git a/public/files/检验结果导入模板_纵向.xls b/public/files/检验结果导入模板_纵向.xls new file mode 100644 index 0000000..e3e8292 Binary files /dev/null and b/public/files/检验结果导入模板_纵向.xls differ diff --git a/src/components/doctorCheck/CheckItemList.vue b/src/components/doctorCheck/CheckItemList.vue index c2bba45..627160c 100644 --- a/src/components/doctorCheck/CheckItemList.vue +++ b/src/components/doctorCheck/CheckItemList.vue @@ -31,7 +31,10 @@
-
+ 选结果模板时自动添加分隔符; +
特殊符号:
-
@@ -49,7 +52,18 @@
-
录入结果:
+
+
录入结果:
+
+
+ + {{ item }} + +
+
+
@@ -70,7 +84,7 @@ import { arrayExistObj, dddw, deepCopy } from '../../utlis/proFunc' export default { components: {}, - props: ["isCheckPicture", "registerCheckId","doctor_check_check_charge"], + props: ["isCheckPicture", "registerCheckId", "doctor_check_check_charge"], data() { return { resultStatus: [], //结果状态提示数据 @@ -103,11 +117,12 @@ export default { result: '', index: 0, // 明细序列 }, //结果模版 - + isSplitChooseResult: 'N', // 选结果时,是否自动加上分隔符 selection: { // 光标位置 start: 0, end: 0 }, symbols: [], //特殊符号 + splitSymbols: [';', '、'], // 分隔符 userId: '', }; }, @@ -380,12 +395,19 @@ export default { this.clickResult(item) this.btnOkResult() }, + // 单击选择结果模版的结果 clickResult(item) { let result = [] if (this.moreResult.result) result = this.moreResult.result.split(';') - if (result.indexOf(item.result) > -1) return - result.push(item.result) + // 不用分隔符时,不判断包含关系 + if (this.isSplitChooseResult == 'Y' && result.indexOf(item.result) > -1) return + if (this.isSplitChooseResult == 'Y' || result.length == 0) { + result.push(item.result) + } else { + result[result.length - 1] = result[result.length - 1] + item.result + } + let ret = '' result.forEach((e, i) => { let splitStr = ';' @@ -435,7 +457,7 @@ export default { if (res.code > -1) { this.doctorCheck.RegisterCheckEdit = res.data if (res.data.isCharge != 'Y' && this.doctor_check_check_charge == 'Y') { - this.$message.warning({showClose:true,message:`该体检人员未缴清费用!`}) + this.$message.warning({ showClose: true, message: `该体检人员未缴清费用!` }) } if (this.doctorCheck.RegisterCheckEdit.completeFlag == '0') { this.doctorCheck.RegisterCheckEdit.checkDoctorId = this.userId @@ -689,5 +711,3 @@ export default { font-family: "Microsoft YaHei"; } - - diff --git a/src/components/patientRegister/PatientRegisterList.vue b/src/components/patientRegister/PatientRegisterList.vue index 8fb7595..7249c7d 100644 --- a/src/components/patientRegister/PatientRegisterList.vue +++ b/src/components/patientRegister/PatientRegisterList.vue @@ -1144,10 +1144,19 @@ export default { this.loadOpts.totalCount = res.data.totalCount let curLoad = res.data.items // let oldCount = 0 + // 处理分组/套餐 排序混乱的问题 + curLoad.forEach(e => { + if(e.customerOrgId == this.dict.personOrgId){ + e.groupPack = e.medicalPackageId + }else{ + e.groupPack = e.customerOrgGroupId + } + }); if (body.skipCount == 0) { //查询 this.tableData = []; } + this.tableData = this.tableData.concat(curLoad) // else { // // 懒加载 ,原数据集不用清空 diff --git a/src/router/index.js b/src/router/index.js index 2517a46..6d911b2 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -459,6 +459,12 @@ const routes = [{ name: "批量导入图片", component: () => import ("../views/doctorCheck/checkPicImport.vue"), + }, + { + path: "/lisResultImport", + name: "从文件导入检验结果", + component: () => + import ("../views/doctorCheck/lisResultImport.vue"), }, //---------------------- 体 检 end ---------------------- //---------------------- 体检查询 start ---------------------- diff --git a/src/views/customerOrg/patientRegisterImport.vue b/src/views/customerOrg/patientRegisterImport.vue index 6ef9e74..6fea375 100644 --- a/src/views/customerOrg/patientRegisterImport.vue +++ b/src/views/customerOrg/patientRegisterImport.vue @@ -93,7 +93,7 @@
-
导入Excel时,Excel的格式必须符合一定规范,该格式的模板文件放在程序的执行目录下,文件名为:"单位体检人员名单导入模板.xls" +
导入Excel时,Excel的格式必须符合一定规范,该格式的模板文件可通过下载模板获取。
注意事项如下:
1、姓名不能为空,其余数据可根据实际情况选择是否填写。 @@ -138,11 +138,12 @@ :close-on-click-modal="false">
- 1、按住 Ctr1 或 Shift 键可进行多选,在标题列右击鼠标可设置列名,即:标题列有√;
+ 1、在标题列右击鼠标可设置列名,即:标题列有 √ 的,才参与数据导入;
2、身份证号有值且合法时,将以身份证号为主自动换算性别、出生日期及年龄;
+ 3、按住 Ctr1 或 Shift 键可进行多选。
- diff --git a/src/views/doctorCheck/checkPicImport.vue b/src/views/doctorCheck/checkPicImport.vue index 76ce097..ce0f22e 100644 --- a/src/views/doctorCheck/checkPicImport.vue +++ b/src/views/doctorCheck/checkPicImport.vue @@ -65,20 +65,38 @@
-
+
+ 条码方式: +
+ + 人员条码 + 检验条码 + 检查条码 + +
+
+ + + +
+
+
+ 条码号: - + - - +
@@ -121,12 +139,16 @@ export default { routeUrlorPageName: 'patientRegisterBatch', //当前页面归属路由或归属页面权限名称 privs: [] // 页面权限 }, + upPic: { visible: false, + barcodeMode: '0', + asbitemId: '', getCheckNoMode: '3', - startLen: null, - endLen: null + startLen: 1, + endLen: 6 }, + asbitems: [], tableData: [], dialogImageUrl: '', dialogVisible: false, @@ -140,9 +162,6 @@ export default { //获取用户当前页面的权限 let userPriv = window.sessionStorage.getItem('userPriv') if (userPriv) this.pagePriv.privs = deepCopy(getPagePriv(this.pagePriv.routeUrlorPageName)) - - - }, //页面挂载完成,一般页面渲染数据放在这里 @@ -169,6 +188,72 @@ export default { }, + // 获取检查项目 + getAsbitems() { + if (!(this.fileList && typeof this.fileList == 'object' && this.fileList.length > 0)) { + this.$message.warning({ showClose: true, message: "请选择要上传的文件!" }) + return + } + let err = '' + let file = this.fileList[0] + let fileName = "" + let dotIndex = file.name.lastIndexOf('.'); + if (dotIndex > -1) fileName = file.name.substring(0, dotIndex); + + let barcodeName = '人员' + + switch (this.upPic.barcodeMode) { + case '1': + barcodeName = "检验" + break; + case '2': + barcodeName = "检查" + break; + default: + break; + } + + let barcode = fileName + switch (this.upPic.getCheckNoMode) { + case '1': + barcode = fileName.substring(0, this.upPic.startLen) + if (barcode.length != this.upPic.startLen) err = `从 ${fileName} 截取的 ${barcodeName}条码号 长度不够` + break; + case '2': + barcode = fileName.substring(fileName.length - this.upPic.startLen) + if (barcode.length != this.upPic.startLen) err = `从 ${fileName} 截取的 ${barcodeName}条码号 长度不够` + break; + case '3': + barcode = fileName.substring(this.upPic.startLen - 1, this.upPic.endLen) + if (barcode.length != Number(this.upPic.endLen - this.upPic.startLen) + Number(1)) err = `从 ${fileName} 截取的 ${barcodeName}条码号 长度不够` + break; + default: + break; + } + if (err) { + this.$message.warning({ showClose: true, message: err }) + return + } + + this.upPic.asbitemId = '' + this.asbitems = [] + switch (this.upPic.barcodeMode) { + case "0": + postapi('/api/app/RegisterCheck/GetRegisterCheckAsbitemsByPatientRegisterNos', { patientRegisterNos: [barcode] }) + .then(res => { + if (res.code > -1) this.asbitems = res.data + }) + break; + case "1": + + break; + default: + break; + } + + + }, + // 导入完后,状态统计 getSummaries(param) { const { columns, data } = param; @@ -222,6 +307,7 @@ export default { this.$message.warning({ showClose: true, message: "请选择要上传的文件!" }) return } + let checkSize = [] this.fileList.forEach(e => { if (e.size > 1024 * 1024 * 20) checkSize.push(e.name) @@ -232,6 +318,11 @@ export default { return; } + if (this.upPic.barcodeMode != '2' && !this.upPic.asbitemId) { + this.$message.error({ showClose: true, message: `请选择检查项目` }) + return; + } + let that = this; let count = 0, err = ''; console.log('this.fileList', this.fileList) @@ -239,7 +330,7 @@ export default { let file = this.fileList[i] console.log('file', file) let reader = new FileReader(); - + // 定义读取文件 reader.onload = (event) => { let fileName = "" @@ -265,35 +356,52 @@ export default { break; } count++; - if (err) { + if (err) { that.tableData.push({ - importState:'导入失败', - importDes:err, + importState: '导入失败', + importDes: err, fileName, - }) - } else { + }) + } else { let rd = { - importState:'导入失败', - importDes:err, + importState: '导入失败', + importDes: err, fileName, - } + } + + let body = { - checkRequestNo, + checkRequestNo, // 检查条码 pictureName: fileName, - pictureBase64: data + pictureBase64: data, + patientRegisterNo: checkRequestNo, // 人员条码 + asbitemId: this.upPic.asbitemId + } + + let url = '/api/app/RegisterCheckPicture/ImportRegisterCheckPicture' + + switch (this.upPic.barcodeMode) { + case '0': + url = '/api/app/RegisterCheckPicture/ImportRegisterCheckPictureByPatientRegisterNo' + break; + case '1': + url = '/api/app/RegisterCheckPicture/ImportRegisterCheckPictureByLisRequestNo' + break; + default: + break; } - postapi('/api/app/RegisterCheckPicture/ImportRegisterCheckPicture', body) - .then(res => { - if (res.code > -1) { + postapi(url, body) + .then(res => { + if (res.code > -1) { rd.importState = "导入成功" - rd.importDes = "" + rd.importDes = "" } else { - rd.importDes = res.message + rd.importDes = res.message } }) .catch(error => { - rd.importDes = `${error}` + rd.importDes = `${error}` }) .finally(() => { that.tableData.push(rd) @@ -316,27 +424,13 @@ export default { }; }, - closePicUpload(){ + closePicUpload() { this.upPic.visible = false }, - - - - - - - - - - - - - - //导入完后,导入状态显示 importRowClassName({ row, rowIndex }) { if (row.importState == '导入失败') { @@ -470,4 +564,22 @@ input[type="number"]::-webkit-outer-spin-button { ::v-deep .menu_item { line-height: 24px; } + +::v-deep .el-upload--picture-card { + width: 148px; + height: 148px; + line-height: 146px; +} + +::v-deep .el-upload-list--item-thumbnail { + width: 72px; + height: 72px; + line-height: 72px; +} + +::v-deep .el-upload-list--item-actions { + width: 72px; + height: 72px; + line-height: 72px; +} diff --git a/src/views/doctorCheck/lisResultImport.vue b/src/views/doctorCheck/lisResultImport.vue new file mode 100644 index 0000000..5b3077a --- /dev/null +++ b/src/views/doctorCheck/lisResultImport.vue @@ -0,0 +1,1294 @@ + + +