Преглед изворни кода

fix(frontend): 根据配置信息控制错误提示的显示

- 引入 config 模块以获取应用模式信息
- 在 showError 函数中添加条件判断,在仅抠图的情况下,不显示错误弹出框
panqiuyao пре 5 месеци
родитељ
комит
68960c063f
1 измењених фајлова са 4 додато и 1 уклоњено
  1. 4 1
      frontend/src/composables/userCheck.ts

+ 4 - 1
frontend/src/composables/userCheck.ts

@@ -1,5 +1,8 @@
 
 
 import { ElMessageBox  } from 'element-plus';
 import { ElMessageBox  } from 'element-plus';
+
+import  configInfo  from '@/stores/modules/config';
+const configInfoStore = configInfo();
 export function useCheckInfo() {
 export function useCheckInfo() {
 
 
         if(localStorage.getItem('check') === 'false'){
         if(localStorage.getItem('check') === 'false'){
@@ -11,7 +14,7 @@ export function useCheckInfo() {
             }
             }
         })
         })
         function ShowError(){
         function ShowError(){
-
+            if(configInfoStore.appModel === 2)  return;
             ElMessageBox({
             ElMessageBox({
                 title:"连接出错!",
                 title:"连接出错!",
                 message:'设备连接出错,请在主窗口中重新连接设备后,在重新打开此窗口后进行操作',
                 message:'设备连接出错,请在主窗口中重新连接设备后,在重新打开此窗口后进行操作',