From 5a813f3b28f3cbf1db3a3657ccf83267c6e0d315 Mon Sep 17 00:00:00 2001
From: Ben Lin <maobin001@msn.com>
Date: 星期四, 24 十月 2024 11:22:02 +0800
Subject: [PATCH] 工艺路线相关优化

---
 src/views/tigerprojects/system/lowcode/entityts/BIZ_MES_WO.ts |   31 ++++++++++++++++++++++++++++---
 1 files changed, 28 insertions(+), 3 deletions(-)

diff --git a/src/views/tigerprojects/system/lowcode/entityts/BIZ_MES_WO.ts b/src/views/tigerprojects/system/lowcode/entityts/BIZ_MES_WO.ts
index a3c71f8..85c5dc0 100644
--- a/src/views/tigerprojects/system/lowcode/entityts/BIZ_MES_WO.ts
+++ b/src/views/tigerprojects/system/lowcode/entityts/BIZ_MES_WO.ts
@@ -4,7 +4,7 @@
  * @version:
  * @Date: 2024-06-19 20:34:27
  * @LastEditors: Ben Lin
- * @LastEditTime: 2024-09-11 22:41:44
+ * @LastEditTime: 2024-10-23 20:48:14
  */
 
 import { Ref, h, ref, render, unref } from 'vue';
@@ -20,8 +20,8 @@
 import { CustModalParams, FunctionType } from '/@/api/tigerapi/model/systemModel';
 import { SaveMesBatchWo } from '/@/api/tigerapi/mes/wo';
 import { useForm } from '/@/components/Form/index';
-import { SP_MES_PROD2WO } from '/@/api/tigerapi/mes/router';
 import { cloneDeep } from 'lodash-es';
+import { useProdRouteStore } from '/@/store/modules/prodRoute';
 
 const { t } = useI18n();
 const { createErrorModal } = useMessage();
@@ -66,6 +66,10 @@
           x.onClick = handleRelease.bind(null, args, params);
           x.tooltip = '涓嬪彂';
         }
+        // if (x.name == 'handleTemplate') {
+        //   x.onClick = handleTemplate.bind(null, args, params);
+        //   x.tooltip = '妯℃澘缁存姢';
+        // }
       });
       return data;
     },
@@ -88,6 +92,14 @@
           showActionButtonGroup: false,
         }),
         prodinfo: useForm({
+          labelWidth: 120,
+          schemas: prodCfgformSchema,
+          actionColOptions: {
+            span: 24,
+          },
+          showActionButtonGroup: false,
+        }),
+        tmpinfo: useForm({
           labelWidth: 120,
           schemas: prodCfgformSchema,
           actionColOptions: {
@@ -336,6 +348,7 @@
               ACT_END_TIME: wo.ACT_END_TIME,
               BATCH_NO: '',
             },
+            IfToCust: form.IfToCust
           };
           SaveMesBatchWo(input).then((action) => {
             resolve(action);
@@ -402,6 +415,9 @@
     // 灏嗗璞¤浆鎹负JSON瀛楃涓插苟淇濆瓨鍒皊essionStorage
     sessionStorage.removeItem(`${id.SessionName}_params`);
     sessionStorage.setItem(`${id.SessionName}_params`, encodeURI(JSON.stringify(id)));
+    /* 璁剧疆鏍囧織锛屼互鏍规嵁缂撳瓨鏁版嵁鍙栨暟鎹� */
+    const useProdRoute = useProdRouteStore();
+    useProdRoute.setChangeToCPPage(true);
     go(`/WoRouteBinding/CP/${encodeURI(JSON.stringify({ sName: id.SessionName, Name: id.Name }))}`);
   }
 
@@ -426,7 +442,6 @@
     });
   }
 
-  /* 涓嬪彂鐣岄潰涓殑琛ㄥ崟鍒楄〃 */
   const woformSchema: FormSchema[] = [
     {
       field: 'PLAN_QTY',
@@ -465,6 +480,16 @@
         valueField: 'LINE_CODE',
       },
     },
+    {
+      field: 'IfToCust',
+      component: 'Switch',
+      label: '鏄惁淇濆瓨宸ヨ壓璺嚎鍒板鎴�',
+      defaultValue: true,
+      colProps: {
+        span: 8,
+      },
+      labelWidth: 200,
+    },
     // {
     //   label: '宸ヨ壓璺嚎',
     //   field: 'ROUTE_CODE',

--
Gitblit v1.9.3