Ben Lin
2024-10-22 e4f79a7e36214e5836cb0e667b3ffbd3db45456d
src/views/tigerprojects/system/lowcode/entityts/WoRouteBinding.ts
@@ -4,7 +4,7 @@
 * @version:
 * @Date: 2024-06-19 20:34:27
 * @LastEditors: Ben Lin
 * @LastEditTime: 2024-10-22 01:00:21
 * @LastEditTime: 2024-10-22 23:36:24
 */
import { Ref, h, ref, render, unref } from 'vue';
@@ -32,11 +32,14 @@
import { buildUUID } from '/@/utils/uuid';
import { mesApi } from '/@/api/tigerapi/mes/mesApi';
import { useProdRouteStore } from '/@/store/modules/prodRoute';
import { useWebSocketStore } from '/@/store/modules/websocket';
import { useGlobSetting } from '/@/hooks/setting';
const { t } = useI18n();
const { createErrorModal } = useMessage();
const useProdRoute = useProdRouteStore();
const { getLocale } = useLocale();
const globSetting = useGlobSetting();
function _default() {
  /* 定义变量 */
  const isNormal = (type: number) => type === 0;
@@ -874,7 +877,25 @@
              param.values['WORK_ORDER'] = param.others['WORK_ORDER'];
              param.values['ID'] = buildUUID();
              await AddOrEditLabelVarByWorkOrder(param.values as unknown as BAS_LABEL_VAR_WO);
              const apiaction = await AddOrEditLabelVarByWorkOrder(
                param.values as unknown as BAS_LABEL_VAR_WO,
              );
              if (apiaction.IsSuccessed) {
                const webSocketStore = useWebSocketStore();
                if (webSocketStore.GetSocketState == 1) {
                  webSocketStore.sendMessage(
                    `wsGetNew ${param.values['LABEL_ID']}_#_${ param.values['WORK_ORDER']}`,
                  );
                }
              }
            case 'delete':
              const webSocketStore = useWebSocketStore();
              if (webSocketStore.GetSocketState == 1) {
                webSocketStore.sendMessage(
                  `wsGetNew ${param.values['LABEL_ID']}_#_${ param.values['WORK_ORDER']}`,
                );
              }
            break;
          }
          resolve('OK');
        } catch (e) {