From 1cebafe0049c86e75fa369c5c90231fd6c84db39 Mon Sep 17 00:00:00 2001 From: pengjun <158915633@qq.com> Date: Mon, 29 Apr 2024 01:12:01 +0800 Subject: [PATCH] SSS --- public/sysConfig.json | 2 +- .../doctorCheck/RegisterCheckEdit.vue | 6 +- src/components/patientRegister/PatientLis.vue | 362 ++++++------------ .../patientRegister/PatientLisRequest.vue | 120 ++++++ .../patientRegister/PatientRegisterEdit.vue | 45 +-- src/components/sumDoctorCheck/SumPREdit.vue | 6 +- src/store/index.js | 3 + src/views/Home.vue | 2 +- 8 files changed, 268 insertions(+), 278 deletions(-) create mode 100644 src/components/patientRegister/PatientLisRequest.vue diff --git a/public/sysConfig.json b/public/sysConfig.json index 302aef0..b84432d 100644 --- a/public/sysConfig.json +++ b/public/sysConfig.json @@ -1,3 +1,3 @@ { - "apiurl": "http://140.143.162.39:9529" + "apiurl": "http://10.1.12.140:9529" } \ No newline at end of file diff --git a/src/components/doctorCheck/RegisterCheckEdit.vue b/src/components/doctorCheck/RegisterCheckEdit.vue index 698e2a8..709f15b 100644 --- a/src/components/doctorCheck/RegisterCheckEdit.vue +++ b/src/components/doctorCheck/RegisterCheckEdit.vue @@ -5,7 +5,7 @@ 检查医生 - +
@@ -63,9 +63,9 @@ export default { methods: { // 初始化字典数据 dictInit() { - getapi('/api/identity/users/getlist') + getapi('/api/identity/users/getlist?SkipCount=0&MaxResultCount=1000') .then(res => { - if (res.code != -1) { + if (res.code > -1) { this.users = res.data.items } }) diff --git a/src/components/patientRegister/PatientLis.vue b/src/components/patientRegister/PatientLis.vue index 2b2e178..232fb2f 100644 --- a/src/components/patientRegister/PatientLis.vue +++ b/src/components/patientRegister/PatientLis.vue @@ -2,12 +2,12 @@
-
+
- + - - + +
-
-
- 全选 -
-
- 取消全选 -
-
- 预览设置 -
-
- 打印 -
-
- 发送申请 -
-
- 撤消申请 -
-
- -
- 加载中... -
-
-
-
-
- -
- - - -
@@ -156,10 +120,9 @@ import moment from "moment"; import { mapState, mapActions } from "vuex"; import { getapi, postapi, putapi, deletapi } from "@/api/api"; -import { photoParse } from "../../utlis/proApi" import Sortable from "sortablejs"; -import FileSaver from 'file-saver'; -import html2canvas from 'html2canvas'; + + import { getPagePriv, checkPagePriv, @@ -168,13 +131,11 @@ import { } from "../../utlis/proFunc"; - -import ElProgressOCX from "../../components/report/ElProgressOCX.vue"; - +import PatientLisRequest from "./PatientLisRequest.vue"; export default { components: { - ElProgressOCX, + PatientLisRequest, }, data() { return { @@ -192,6 +153,7 @@ export default { multipleSelection: [], //选中的数据列表 tabChoosed: "1", + rClickRow: null, //右击的行 rClickColumn: null, //右击的列(预留) @@ -208,14 +170,7 @@ export default { { label: "姓名", prop: "patientName", minWidth: 80, align: "center" }, { label: "性别", prop: "sexId", minWidth: 55, align: "center" }, { label: "年龄", prop: "age", minWidth: 55, align: "center" }, - - { label: "颜色", prop: "lisrequest", minWidth: 120, align: "center" }, - { label: "容器", prop: "lisrequest", minWidth: 120, align: "center" }, - { label: "项目分组", prop: "lisrequest", minWidth: 120, align: "center" }, - { label: "申请项目", prop: "lisrequest", minWidth: 120, align: "center" }, - { label: "检验码号", prop: "lisrequest", minWidth: 120, align: "center" }, - - { label: "人员条码号", prop: "patientRegisterNo", minWidth: 150, align: "center" }, + { label: "条码号", prop: "patientRegisterNo", minWidth: 150, align: "center" }, { label: "档案号", prop: "patientNo", minWidth: 100, align: "center" }, { label: "体检次数", prop: "medicalTimes", minWidth: 80, align: "center" }, { label: "分组/套餐", prop: "groupPack", minWidth: 150, align: "center" }, @@ -248,17 +203,6 @@ export default { maxResultCount: 100, }, loadOptsInit: {}, - - oneClick: 0, // 1 表示行单击一次 - DbClick: 0, // 1 表示行有单击第二次 - - printPre: 0, - lisLabel: '', // data:application/pdf;base64, - LocalConfig: { - lisLabel: { - MarginTop: 56, // 预览上移像素 px - } - } }; }, @@ -268,17 +212,10 @@ export default { if (userPriv) this.pagePriv.privs = deepCopy(getPagePriv(this.pagePriv.routeUrlorPageName)) this.loadOptsInit = Object.assign({}, this.loadOpts) - let LocalConfig = window.localStorage.getItem("LocalConfig") || null - try { - this.LocalConfig = JSON.parse(LocalConfig) || this.LocalConfig - } catch (error) { - console.log('window.localStorage.getItem("LocalConfig")', error) - } }, //挂载完成 mounted() { - // 初始化可以拖动的列 this.headerCols = deepCopy(this.dropCol) this.dropCol = this.columnDrop(this.dropCol); @@ -297,18 +234,6 @@ export default { "patientRegister", "customerOrg", ]), - - // 照片显示 - peoplePhoto() { - return photoParse(this.tableDataCurrentRow.photo) - }, - - // 表体高度 - tableHeight() { - let fixHeight = this.window.pageHeight < 600 ? 600 : this.window.pageHeight - return Math.floor((fixHeight - 243) * 2 / 3) - } - }, methods: { moment, dddw, deepCopy, checkPagePriv, @@ -325,26 +250,6 @@ export default { } }, - // 全选 取消全选 - btnChooseAll(type) { - if (type == 1) { - // 全选 - this.tableData.forEach(e => { - e.choosed = true; - e.highLightBg = "selected"; - }); - - this.multipleSelection = deepCopy(this.tableData) - } else { - this.tableData.forEach(e => { - e.choosed = false; - e.highLightBg = ""; - }); - this.multipleSelection = [] - this.$refs['info'].setCurrentRow(); - } - }, - // 行选择 rowSelected(rows) { rows.forEach((e) => { @@ -356,8 +261,6 @@ export default { setData(this, item, v) }, - - handleSelectionChange(rows) { //this.multipleSelection = rows; //console.log('this.multipleSelection',this.multipleSelection) @@ -376,89 +279,8 @@ export default { //点击体检次数行 rowClick(row) { - /* - if (this.oneClick == 0) { - this.oneClick = 1; - } else { - this.DbClick = 1; - } - - //双击事件 - if (this.DbClick == 1) { //第一次点击的节点和第二次点击的节点id相同 - this.rowClickRetrieve(row) - return; - } - - setTimeout(() => { //300ms内没有第二次点击,执行单击事件 - if (this.oneClick == 1 && this.DbClick == 0) this.rowClickRetrieve(row) - }, 300) - */ - this.rowClickRetrieve(row) - }, - - rowClickRetrieve(row) { - this.oneClick = 0; - this.DbClick = 0; - - // 按住了shift键 - if (this.window.shift) { - //清除所有选择 - this.tableData.forEach((e, index) => { - e.choosed = false; - e.index = index; - }); - - if (this.startPoint == -1) { - this.tableData[row.index].choosed = true; - this.startPoint = row.index; - } else { - if (this.startPoint > row.index) { - for (let i = row.index; i <= this.startPoint; i++) { - this.tableData[i].choosed = true; - } - } else if (this.startPoint <= row.index) { - for (let i = this.startPoint; i <= row.index; i++) { - this.tableData[i].choosed = true; - } - } - } - } else if (this.window.ctrl) { // 按住了ctrl 键 - this.tableData[row.index].choosed = true; - if (this.startPoint == -1) { - this.startPoint = row.index; - } - } else { - // 未按住了ctrl 、shift 键 - //清除所有选择 - console.log("清除所有选择"); - this.tableData.forEach((e, index) => { - e.choosed = false; - e.index = index; - }); - console.log(this.tableData, row.index); - console.log(this.tableData[row.index].choosed); - - this.tableData[row.index].choosed = true; - this.startPoint = row.index; - } - - //选中了多个点编辑时,排序最前的作为当前选中的 - console.log('row.index <= this.startPoint', row.index, this.startPoint) - let lfind = -1 - for (let i = 0; i < this.tableData.length; i++) { - if (this.tableData[i].choosed) { - lfind = i - break - } - } - - if (lfind > -1) { - // 弹出编辑框,只有在编辑框显示时,才去触发获取数据 - this.dataTransOpts.tableS.patient_register.id = this.tableData[lfind].id - this.tableDataCurrentRow = deepCopy(this.tableData[lfind]) - //触发条码预览 - if (this.$peisAPI) this.lisPrint(this.dataTransOpts.tableS.patient_register.id, "0002", "Y", "Y") - } + this.dataTransOpts.tableS.patient_register = deepCopy(row) + this.dataTransOpts.refresh.lis_request.M++ //触发条码 }, //查询 @@ -468,7 +290,7 @@ export default { this.tableDataCurrentRow = {} // 清除选择 this.tableData = [] setTimeout(() => { - this.dataTransOpts.refresh.register_check_asbitem.M++ //触发所选组合项目刷新 + this.dataTransOpts.refresh.lis_request.M++ //触发所选组合项目刷新 }, 10); this.loadOpts = Object.assign(this.loadOpts, this.loadOptsInit) @@ -481,7 +303,6 @@ export default { await this.getPrList() }, - // 获取列表数据 async getPrList() { @@ -524,12 +345,8 @@ export default { this.patientRegister.query.startDate && this.patientRegister.query.endDate ) { - body.startDate = moment(this.patientRegister.query.startDate).format( - "yyyy-MM-DD" - ); - body.endDate = moment(this.patientRegister.query.endDate).format( - "yyyy-MM-DD" - ); + body.startDate = moment(this.patientRegister.query.startDate).format("yyyy-MM-DD"); + body.endDate = moment(this.patientRegister.query.endDate).format("yyyy-MM-DD"); if (body.startDate > body.endDate) { this.$message.warning({ showClose: true, message: "起始日期不能大于截止日期,数据校验不通过!" }); return; @@ -550,11 +367,11 @@ export default { patientRegisterNo: this.patientRegister.query.patientRegisterNo, }; - console.log("/api/app/LisRequest/GetListInFilter", body); - // /api/app/patientregister/getlistinfilter + console.log("/api/app/patientregister/getlistinfilter", body); + postapi("/api/app/patientregister/getlistinfilter", body) .then(res => { - if (res.code != -1) { + if (res.code > -1) { // 刷新最大记录数 this.loadOpts.totalCount = res.data.totalCount let curLoad = res.data.items @@ -602,28 +419,6 @@ export default { }) }, - // 预览设置 - btnPrintPre() { - - }, - - // 打印 - btnPrint() { - - }, - - // 发送检验申请 - btnSendLis() { - console.log('btnSendLis') - }, - - // 撤消检验申请 - btnUndoLis() { - console.log('btnUndoLis') - }, - - - //检验申请 async lisRequest(prId) { let isPrintLisRequest = false; @@ -645,7 +440,6 @@ export default { return; } if (res.code > -1) { - // this.$message.info("发送检验申请成功!"); isPrintLisRequest = true; } @@ -673,7 +467,7 @@ export default { }, //检验条码打印 - lisPrint(prId, ReportCode, isPreview, IsUploadPdf) { + lisPrint(prId, ReportCode, isPreview) { if (!this.$peisAPI) { this.$message.info({ showClose: true, message: "此功能,需要在壳客户端才可运行!" }); return; @@ -685,7 +479,7 @@ export default { ReportCode, token, isBuildImage: 'N', - IsUploadPdf, + IsUploadPdf: 'N', preViewCanPrint: "N", Parameters: [ { Name: "printer", Value: user }, @@ -695,13 +489,29 @@ export default { }; if (isPreview) { + /* + postapi( + `/api/app/printreport/getlisrequestreport?PatientRegisterId=${prId}` + ) + .then((res) => { + if (res.code != -1) { + toOutShell.ReportTable = { lisRequest: res.data }; + console.log( + "JSON.stringify(toOutShell)", + JSON.stringify(toOutShell) + ); + return this.$peisAPI.printPre(JSON.stringify(toOutShell)); + } + }) + .catch((err) => { + this.$message.warning(err); + }); + */ this.$peisAPI.printPre(JSON.stringify(toOutShell)) .then(res => { - let lres = JSON.parse(res) - if (lres.code < 0) { + console.log('this.$peisAPI.printPre', res) + if (JSON.parse(res).code < 0) { this.$message.warning({ showClose: true, message: JSON.parse(res).message }); - } else if (IsUploadPdf == 'Y') { - this.lisLabel = 'data:application/pdf;base64,' + lres.data } }) .catch((err) => { @@ -710,7 +520,39 @@ export default { }); } else { - + /* + postapi( + `/api/app/printreport/getlisrequestreport?PatientRegisterId=${prId}` + ) + .then((res) => { + if (res.code != -1) { + toOutShell.ReportTable = { lisRequest: res.data }; + console.log( + "JSON.stringify(toOutShell)", + JSON.stringify(toOutShell) + ); + return this.$peisAPI.print(JSON.stringify(toOutShell)); + } + }) + .then((res) => { + //console.log("res", res); + if (JSON.parse(res).code >= 0) { + //更新打印状态 /api/app/lisrequest/updatelisrequestisprint + // { + // "operateType": 0, 操作类型(1.按PatientRegisterId 2.按LisRequestId) + // "patientRegisterId": "3fa85f64-5717-4562-b3fc-2c963f66afa6", + // "lisRequestId": "3fa85f64-5717-4562-b3fc-2c963f66afa6" + // } + return postapi("/api/app/lisrequest/updatelisrequestisprint", { + operateType: 1, + patientRegisterId: prId, + }); + } + }) + .catch((err) => { + this.$message.warning(err); + }); + */ this.$peisAPI.print(JSON.stringify(toOutShell)) .then(res => { if (JSON.parse(res).code < 0) { @@ -737,7 +579,7 @@ export default { //pacs条码打印 pacsPrint(prId, ReportCode, isPreview) { if (!this.$peisAPI) { - this.$message.info("此功能,需要在壳客户端才可运行!"); + this.$message.info({ showClose: true, message: "此功能,需要在壳客户端才可运行!" }); return; } let token = window.sessionStorage.getItem("token"); @@ -756,6 +598,24 @@ export default { }; if (isPreview) { + /* + postapi( + `/api/app/printreport/getpacsnoreport?PatientRegisterId=${prId}` + ) + .then((res) => { + if (res.code != -1) { + toOutShell.ReportTable = { lisRequest: res.data }; + console.log( + "JSON.stringify(toOutShell)", + JSON.stringify(toOutShell) + ); + return this.$peisAPI.printPre(JSON.stringify(toOutShell)); + } + }) + .catch((err) => { + this.$message.warning(err); + }); + */ this.$peisAPI.printPre(JSON.stringify(toOutShell)) .then(res => { if (JSON.parse(res).code < 0) { @@ -767,6 +627,38 @@ export default { this.$message.warning({ showClose: true, message: `${err}` }); }); } else { + /* + postapi( + `/api/app/printreport/getpacsnoreport?PatientRegisterId=${prId}` + ) + .then((res) => { + if (res.code != -1) { + toOutShell.ReportTable = { lisRequest: res.data }; + console.log( + "JSON.stringify(toOutShell)", + JSON.stringify(toOutShell) + ); + return this.$peisAPI.print(JSON.stringify(toOutShell)); + } + }) + .then((res) => { + if (JSON.parse(res).code >= 0) { + //更新打印状态 /api/app/lisrequest/updatelisrequestisprint + // { + // "operateType": 0, 操作类型(1.按PatientRegisterId 2.按LisRequestId) + // "patientRegisterId": "3fa85f64-5717-4562-b3fc-2c963f66afa6", + // "lisRequestId": "3fa85f64-5717-4562-b3fc-2c963f66afa6" + // } + return postapi("/api/app/lisrequest/updatelisrequestisprint", { + operateType: 1, + patientRegisterId: prId, + }); + } + }) + .catch((err) => { + this.$message.warning(err); + }); + */ this.$peisAPI.print(JSON.stringify(toOutShell)) .then(res => { if (JSON.parse(res).code < 0) { diff --git a/src/components/patientRegister/PatientLisRequest.vue b/src/components/patientRegister/PatientLisRequest.vue new file mode 100644 index 0000000..a69e88c --- /dev/null +++ b/src/components/patientRegister/PatientLisRequest.vue @@ -0,0 +1,120 @@ + + + diff --git a/src/components/patientRegister/PatientRegisterEdit.vue b/src/components/patientRegister/PatientRegisterEdit.vue index d3fdb6f..e7ba8ca 100644 --- a/src/components/patientRegister/PatientRegisterEdit.vue +++ b/src/components/patientRegister/PatientRegisterEdit.vue @@ -217,11 +217,11 @@ + :value="item.id" :disabled="item.isComplete == 'Y'" /> @@ -934,16 +934,13 @@ export default { //获取单位体检次数信息 getapi(`/api/app/customerorgregister/getlistincustomerorgid?CustomerOrgId=${customerOrgParentId}`) .then(res => { - if (res.code != - 1) { + if (res.code > - 1) { console.log('获取单位体检次数', this.form.customerOrgRegisterId, res.data) - if (this.form.customerOrgRegisterId) { - let lfind = arrayExistObj(res.data, "id", this.form.customerOrgRegisterId) - if (lfind == -1) this.form.customerOrgRegisterId = '' - } + this.customerOrgRegisterList = res.data if (!this.form.customerOrgRegisterId) { - this.customerOrgRegisterList = arrayFilter(res.data, 'isComplete', 'N') //不显示已完成的体检次数 - if (this.customerOrgRegisterList.length > 0) { - this.form.customerOrgRegisterId = this.customerOrgRegisterList[this.customerOrgRegisterList.length - 1].id + let customerOrgRegisterList = arrayFilter(res.data, 'isComplete', 'N') //不显示已完成的体检次数 + if (customerOrgRegisterList.length > 0) { + this.form.customerOrgRegisterId = customerOrgRegisterList[customerOrgRegisterList.length - 1].id } } if (this.form.customerOrgRegisterId) return getapi(`/api/app/customerorggroup/getlistinfilter?CustomerOrgRegisterId=${this.form.customerOrgRegisterId}`) //获取单位分组 @@ -983,29 +980,7 @@ export default { }) }, - //获取单位体检次数列表,并默认赋最后一次体检次数 - // async getCustomerOrgRegisterList() { - // this.customerOrgRegisterList = [] - // if (this.form.customerOrgId == this.dict.personOrgId) { - // this.form.customerOrgRegisterId = null - // return - // } - // try { - // let res = await getapi(`/api/app/customer-org/parent/${this.form.customerOrgId}`); - // let res1 = await getapi(`/api/app/customerorgregister/getlistincustomerorgid?CustomerOrgId=${res.data}`); - // this.customerOrgRegisterList = arrayFilter(res1.data, 'isComplete', 'N') - - // //要把已完成体检的次数去掉 (查询时不能触发保存) - // // if (this.customerOrgRegisterList.length > 0) { - // // this.form.customerOrgRegisterId = this.customerOrgRegisterList[this.customerOrgRegisterList.length - 1].id - // // //this.changeCustomerOrgGroupId() - // // this.changeMedicalTimes() - // // } - - // } catch (error) { - // console.log(error) - // } - // }, + //修改单位体检次数 changeMedicalTimes() { @@ -1887,9 +1862,9 @@ export default { //人员ID未切换换时 也可以强制刷新数据 "dataTransOpts.refresh.patient_register.S": { // immediate: true, - handler(newVal, oldVal) { + async handler(newVal, oldVal) { console.log(`watch 人员登记 newVal:${newVal} oldVal:${oldVal} registerCheckId: ${this.dataTransOpts.tableS.patient_register.id}`); - if (newVal != oldVal) this.initFormData(this.dataTransOpts.tableS.patient_register.id) + if (newVal != oldVal) await this.initFormData(this.dataTransOpts.tableS.patient_register.id) } }, diff --git a/src/components/sumDoctorCheck/SumPREdit.vue b/src/components/sumDoctorCheck/SumPREdit.vue index 4bd4740..be1cd02 100644 --- a/src/components/sumDoctorCheck/SumPREdit.vue +++ b/src/components/sumDoctorCheck/SumPREdit.vue @@ -14,7 +14,7 @@ - +
@@ -84,9 +84,9 @@ export default { // 初始化字典数据 dictInit() { // 获取用户信息 - getapi('/api/identity/users/getlist') + getapi('/api/identity/users/getlist?SkipCount=0&MaxResultCount=1000') .then(res => { - if (res.code != -1) { + if (res.code > -1) { this.users = res.data.items } }) diff --git a/src/store/index.js b/src/store/index.js index 3776505..c23f62b 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -307,6 +307,7 @@ export default new Vuex.Store({ customer_org_group_detail: { S: 0, M: 0 }, // 单位分组包含的组合项目明细 charge: { S: 0, M: 0 }, // 收费 menu_info: { S: 0, M: 0 }, // 菜单与页面 + lis_request: { S: 0, M: 0 }, // 检验申请(条码) patient_register: { S: 0, M: 0 }, // 体检人员记录 register_check_asbitem: { S: 0, M: 0, D: 0 }, // 体检人员登记的项目(合并前) register_check: { S: 0, M: 0 }, // 体检人员登记的项目(合并后) @@ -329,6 +330,7 @@ export default new Vuex.Store({ customer_org_group_detail: { id: '' }, // 单位分组包含的组合项目明细 charge: { id: '' }, // 收费 menu_info: { id: '' }, // 菜单与页面 + lis_request: { id: '' }, // 检验申请(条码) patient_register: { id: '', patientRegisterNo: ''}, // 体检人员记录 register_check_asbitem: { id: '' }, // 体检人员登记的项目(合并前) register_check: { id: '' }, // 体检人员登记的项目(合并后) @@ -349,6 +351,7 @@ export default new Vuex.Store({ customer_org_group_detail: [], // 单位分组包含的组合项目明细 charge: [], // 收费 menu_info: [], // 菜单与页面 + lis_request: [], // 检验申请(条码) patient_register: [], // 体检人员记录 register_check_asbitem: [], // 体检人员登记的项目(合并前) register_check: [], // 体检人员登记的项目(合并后) diff --git a/src/views/Home.vue b/src/views/Home.vue index 06317c2..441088f 100644 --- a/src/views/Home.vue +++ b/src/views/Home.vue @@ -343,7 +343,7 @@ export default { this.$message.info("此功能,需要在壳客户端才可运行!"); return; } - this.$peisAPI.clientConfigShow(); + this.$peisAPI.toggleDevTools(); }, // 打开客户端设置