From aadc91f6723a6eafac893bd5a2dd7d021a5e58d5 Mon Sep 17 00:00:00 2001 From: wwl <xchao828@163.com> Date: 星期五, 09 五月 2025 14:44:32 +0800 Subject: [PATCH] zongjian --- src/views/doctor/checkAll/index.vue | 283 ++++++++++++++++++++++++++++++++------------------------ 1 files changed, 163 insertions(+), 120 deletions(-) diff --git a/src/views/doctor/checkAll/index.vue b/src/views/doctor/checkAll/index.vue index 11a9d47..052218c 100644 --- a/src/views/doctor/checkAll/index.vue +++ b/src/views/doctor/checkAll/index.vue @@ -425,7 +425,7 @@ </el-table> </div> </template> - <template v-if="wenzhen"> + <template v-if="status1 == 3"> <div class="hist3"> <span class="txt">闂瘖淇℃伅</span> <el-form ref="form" :model="formobj" label-width="100px" :inline="true" size="mini"> @@ -851,7 +851,6 @@ jianqians: false, sex: true, activeName: "1", - wenzhen: false, hosproy: true, remarks: "", remark: "", @@ -1331,59 +1330,76 @@ getRowKeys(row) { return row.orderDetailId; }, - xiangmuqingkuang() { - cSWebGetPro(this.tjNumber).then((res) => { - this.status1 = 1; - this.wenzhen = false - this.statusList = res.data; - - if (this.statusList.length == 0) { - this.$message.msgSuccess("鏆傛棤椤圭洰鎯呭喌"); - } - }); - }, + this.loading = true; + cSWebGetPro(this.tjNumber) + .then((res) => { + this.status1 = 1; + this.statusList = res.data; + if (this.statusList.length == 0) { + this.$message.success("鏆傛棤椤圭洰鎯呭喌"); + } + }) + .catch((error) => { + console.error('鑾峰彇椤圭洰鎯呭喌澶辫触:', error); + this.$message.error('鑾峰彇椤圭洰鎯呭喌澶辫触'); + }) + .finally(() => { + this.loading = false; + }); +}, guanbi() { this.drawer = false; }, yichangjieguo() { - this.status1 = 0; - let _this = this; - yichang({ - tjNum: this.tjNumber, - }).then((res) => { - this.yichangList = res.data; - - this.yichangList.forEach((item) => { - item.sone.forEach((soneItem) => { - if (!Array.isArray(soneItem.advices) || soneItem.advices.length === 0) { - soneItem.advices = [{ bt: "", nr: "" }]; - } - }); + this.loading = true; + this.status1 = 0; + yichang({ + tjNum: this.tjNumber, + }) + .then((res) => { + this.yichangList = res.data; + this.yichangList.forEach((item) => { + item.sone.forEach((soneItem) => { + if (!Array.isArray(soneItem.advices) || soneItem.advices.length === 0) { + soneItem.advices = [{ bt: "", nr: "" }]; + } }); - - if (!this.yichangList) { - _this.$message({ - type: "warning", - message: "鏆傛棤寮傚父鎶ュ憡", - }); - } }); - }, - - fuchaxiangmu() { - this.status1 = 2; - this.wenzhen = false - let data = { - tjNum: this.tjNumber, - type: 1 + if (!this.yichangList) { + this.$message.warning("鏆傛棤寮傚父鎶ュ憡"); } - getFcList(data).then(res => { - this.fcList = res.data - }) - }, + }) + .catch((error) => { + console.error('鑾峰彇寮傚父缁撴灉澶辫触:', error); + this.$message.error('鑾峰彇寮傚父缁撴灉澶辫触'); + }) + .finally(() => { + this.loading = false; + }); +}, + +fuchaxiangmu() { + this.loading = true; + this.status1 = 2; + let data = { + tjNum: this.tjNumber, + type: 1 + }; + getFcList(data) + .then((res) => { + this.fcList = res.data; + }) + .catch((error) => { + console.error('鑾峰彇澶嶆煡椤圭洰澶辫触:', error); + this.$message.error('鑾峰彇澶嶆煡椤圭洰澶辫触'); + }) + .finally(() => { + this.loading = false; + }); +}, getdate() { getNewDateList().then((res) => { @@ -1499,83 +1515,111 @@ }, Graphicreport() { - let dictType = "dict_ageunit"; - getDicts(dictType).then((res) => { - if (res.code == 200) { - res.data.forEach((item) => { - if (this.tableAll.age_unit == item.dictValue) { - this.tableAll.age_unit = item.dictLabel; - } - }); - let dictTypes = "sys_user_sex"; - getDicts(dictTypes).then((res) => { - if (res.code == 200) { - res.data.forEach((item) => { - if (this.tableAll.cusSex == item.dictValue) { - this.tableAll.cusSex = item.dictLabel; - } - }); - let data = { - patname: this.tableAll.cusName, - sex: this.tableAll.cusSex, - patage: this.tableAll.age, - patagename: this.tableAll.age_unit, - patbirth: this.tableAll.cusBrithday, - }; - getTjYxjcList(data).then((res) => { - this.baogao = res.data; - }); - this.$refs.bbb.open = true; - this.$refs.bbb.title = "鎶ュ憡瀛楀吀"; - } - }); - } - }); - }, + this.loading = true; + let dictType = "dict_ageunit"; + getDicts(dictType) + .then((res) => { + if (res.code == 200) { + res.data.forEach((item) => { + if (this.tableAll.age_unit == item.dictValue) { + this.tableAll.age_unit = item.dictLabel; + } + }); + let dictTypes = "sys_user_sex"; + return getDicts(dictTypes); + } else { + throw new Error('鑾峰彇骞撮緞鍗曚綅瀛楀吀澶辫触'); + } + }) + .then((res) => { + if (res.code == 200) { + res.data.forEach((item) => { + if (this.tableAll.cusSex == item.dictValue) { + this.tableAll.cusSex = item.dictLabel; + } + }); + let data = { + patname: this.tableAll.cusName, + sex: this.tableAll.cusSex, + patage: this.tableAll.age, + patagename: this.tableAll.age_unit, + patbirth: this.tableAll.cusBrithday, + }; + return getTjYxjcList(data); + } else { + throw new Error('鑾峰彇鎬у埆瀛楀吀澶辫触'); + } + }) + .then((res) => { + this.baogao = res.data; + this.$refs.bbb.open = true; + this.$refs.bbb.title = "鎶ュ憡瀛楀吀"; + }) + .catch((error) => { + console.error('鐢熸垚鍥炬枃鎶ュ憡澶辫触:', error); + this.$message.error('鐢熸垚鍥炬枃鎶ュ憡澶辫触'); + }) + .finally(() => { + this.loading = false; + }); +}, historicalreport() { - this.loading = true; - this.wenzhen = false; - this.hosproy = true; - let data = { - cusId: this.tableAll.cusId, - }; - reportHistory(data).then((res) => { - this.loading = false; - if (res.data[0] != null) { - this.reportHistorydata = res.data; - } else { - this.reportHistorydata = []; - } - }); - }, + this.loading = true; + let data = { + cusId: this.tableAll.cusId, + }; + reportHistory(data) + .then((res) => { + if (res.data[0] != null) { + this.reportHistorydata = res.data; + } else { + this.reportHistorydata = []; + } + }) + .catch((error) => { + console.error('鑾峰彇鍘嗗彶鎶ュ憡澶辫触:', error); + this.$message.error('鑾峰彇鍘嗗彶鎶ュ憡澶辫触'); + }) + .finally(() => { + this.loading = false; + }); +}, - medicalhistory() { - this.wenzhen = true; - this.hosproy = false; - let tjNumber = this.tableAll.tjNumber; - getInfoById(tjNumber).then((response) => { - this.formobj = response.data; - if (this.formobj.xiyan == null) { - this.formobj.xiyan = "1"; - } - if (this.formobj.xiyanpinlv == null) { - this.formobj.xiyanpinlv = "0"; - } - if (this.formobj.xiyanyear == null) { - this.formobj.xiyanyear = "0"; - } - if (this.formobj.yinjiu == null) { - this.formobj.yinjiu = "1"; - } - if (this.formobj.yinjiupinlv == null) { - this.formobj.yinjiupinlv = "0"; - } - if (this.formobj.yinjiuyear == null) { - this.formobj.yinjiuyear = "0"; - } - }); - }, +medicalhistory() { + this.loading = true; + this.status1 = 3; + let tjNumber = this.tableAll.tjNumber; + getInfoById(tjNumber) + .then((response) => { + this.formobj = response.data; + if (this.formobj.xiyan == null) { + this.formobj.xiyan = "1"; + } + if (this.formobj.xiyanpinlv == null) { + this.formobj.xiyanpinlv = "0"; + } + if (this.formobj.xiyanyear == null) { + this.formobj.xiyanyear = "0"; + } + if (this.formobj.yinjiu == null) { + this.formobj.yinjiu = "1"; + } + if (this.formobj.yinjiupinlv == null) { + this.formobj.yinjiupinlv = "0"; + } + if (this.formobj.yinjiuyear == null) { + this.formobj.yinjiuyear = "0"; + } + }) + .catch((error) => { + console.error('鑾峰彇鑱屼笟鐥呭彶澶辫触:', error); + this.$message.error('鑾峰彇鑱屼笟鐥呭彶澶辫触'); + }) + .finally(() => { + this.loading = false; + }); +}, downLoadFileImg(row) { const tjNumber = row.tjNumber; @@ -1897,7 +1941,6 @@ handleClose1(done) { this.jianqians = false; - this.wenzhen = false; this.flags = false; done(); }, -- Gitblit v1.8.0