Browse Source

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

- 引入 config 模块以获取应用模式信息
- 在 showError 函数中添加条件判断,在仅抠图的情况下,不显示错误弹出框
panqiuyao 5 months ago
parent
commit
68960c063f
1 changed files with 4 additions and 1 deletions
  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  configInfo  from '@/stores/modules/config';
+const configInfoStore = configInfo();
 export function useCheckInfo() {
 
         if(localStorage.getItem('check') === 'false'){
@@ -11,7 +14,7 @@ export function useCheckInfo() {
             }
         })
         function ShowError(){
-
+            if(configInfoStore.appModel === 2)  return;
             ElMessageBox({
                 title:"连接出错!",
                 message:'设备连接出错,请在主窗口中重新连接设备后,在重新打开此窗口后进行操作',