Przeglądaj źródła

病案首页未通过检验也可以打印

lighter 2 miesięcy temu
rodzic
commit
b2ccacb41e

+ 12 - 12
src/views/hospitalization/case-front-sheet/AllCaseFrontSheet.vue

@@ -1171,18 +1171,18 @@ const beforePrint = flag => {
   if (nullPatient()) return;
   executePrintVerify({
     sheet: sheet.value,
-  })
-    .then(() => {
-      execPrint(flag);
-    })
-    .catch(e => {
-      forceVerifies.value = e.data.force;
-      adviceVerifies.value = e.data.advice;
-      showMessageDrawer.value = true;
-      if (e.data.force.length === 0) {
-        execPrint(flag);
-      }
-    });
+  }).then(() => {
+    execPrint(flag);
+  }).catch(e => {
+    forceVerifies.value = e.data.force;
+    adviceVerifies.value = e.data.advice;
+    showMessageDrawer.value = true;
+    ElMessageBox.confirm('病案首页检验未通过,是否继续打印?', '提示', {
+      type: "warning",
+    }).then(() => {
+      execPrint(flag)
+    }).catch(() => {})
+  });
 };
 const execPrint = flag => {
   const LODOP = getLodop();

+ 6 - 2
src/views/hospitalization/case-front-sheet/FillCaseFrontSheet.vue

@@ -2407,7 +2407,7 @@ import {
 } from "@/api/case-front-sheet";
 import maleIcon from "@/assets/male-icon.png";
 import femaleIcon from "@/assets/female-icon.png";
-import { ElMessage } from "element-plus";
+import {ElMessage, ElMessageBox} from "element-plus";
 import { shortcuts } from "@/data/shortcuts";
 import {
   formatDate,
@@ -3364,7 +3364,11 @@ const beforePrint = page => {
     if (res.approved > 0) {
       execPrint(page);
     } else {
-      xcMessage.error("病案首页质控审核未通过,无法打印。");
+      ElMessageBox.confirm('病案首页质控审核未通过,是否继续打印?', '提示', {
+        type: "warning",
+      }).then(() => {
+        execPrint(page)
+      }).catch(() => {})
     }
   });
 };

+ 6 - 0
src/views/hospitalization/case-front-sheet/trdtnl-chns/FillChnsSheet.vue

@@ -2013,6 +2013,7 @@ import {useUserStore} from "@/pinia/user-store";
 import env from "../../../../utils/setting";
 import {getSheetInfo, saveTcmSheet, verifySheet} from "@/api/case-front-sheet/tcm-sheet.js";
 import Search from '@/components/search/Index.vue'
+import {ElMessageBox} from "element-plus";
 
 const userStore = useUserStore();
 const userWards = ref([]);
@@ -2543,6 +2544,11 @@ function beforePrint(page) {
     }).catch(e => {
       forceVerifies.value = e.data;
       showMessageDrawer.value = true;
+      ElMessageBox.confirm('病案首页检验未通过,是否继续打印?', '提示', {
+        type: "warning",
+      }).then(() => {
+        execPrint(page)
+      }).catch(() => {})
     });
   } else {
     execPrint(page)