From cd8b52bdf89a4d1101f72e0ece9f4df22a3d3f7a Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期四, 15 十月 2026 16:03:32 +0800
Subject: [PATCH] feat(mdm): 物料列表隐藏辅单位与销售价列

---
 src/views/basicData/mdm/data.ts |  105 +++++++++++++++++++++++++++++++++-------------------
 1 files changed, 67 insertions(+), 38 deletions(-)

diff --git a/src/views/basicData/mdm/data.ts b/src/views/basicData/mdm/data.ts
index a9d6ca9..051a99c 100644
--- a/src/views/basicData/mdm/data.ts
+++ b/src/views/basicData/mdm/data.ts
@@ -333,6 +333,17 @@
       },
     },
     {
+      component: 'Switch',
+      fieldName: 'syncMes',
+      label: '鍚屾鍒癕ES',
+      defaultValue: true,
+      componentProps: {
+        checkedChildren: '鏄�',
+        unCheckedChildren: '鍚�',
+      },
+      rules: z.boolean().default(true),
+    },
+    {
       component: "RadioGroup",
       fieldName: "status",
       label: "鐘舵��",
@@ -540,52 +551,46 @@
       title: "鍗曚綅",
       minWidth: 80,
     },
-    {
-      field: "unitMeasureName2",
-      title: "杈呭崟浣�1",
-      minWidth: 80,
-    },
-    {
-      field: "unitMeasureRate1",
-      title: "杈呭崟浣�1鎹㈢畻姣旂巼",
-      minWidth: 130,
-    },
-    {
-      field: "unitMeasureName3",
-      title: "杈呭崟浣�2",
-      minWidth: 80,
-    },
-    {
-      field: "unitMeasureRate2",
-      title: "杈呭崟浣�2鎹㈢畻姣旂巼",
-      minWidth: 130,
-    },
+    // 杈呭崟浣�1/杈呭崟浣�1鎹㈢畻姣旂巼/杈呭崟浣�2/杈呭崟浣�2鎹㈢畻姣旂巼锛氱墿鏂欏垪琛ㄤ笉鍐嶅睍绀猴紙琛ㄥ崟閲屼粛鍙淮鎶わ級锛岄渶瑕佹仮澶嶅氨鍙栨秷娉ㄩ噴
+    // {
+    //   field: "unitMeasureName2",
+    //   title: "杈呭崟浣�1",
+    //   minWidth: 80,
+    // },
+    // {
+    //   field: "unitMeasureRate1",
+    //   title: "杈呭崟浣�1鎹㈢畻姣旂巼",
+    //   minWidth: 130,
+    // },
+    // {
+    //   field: "unitMeasureName3",
+    //   title: "杈呭崟浣�2",
+    //   minWidth: 80,
+    // },
+    // {
+    //   field: "unitMeasureRate2",
+    //   title: "杈呭崟浣�2鎹㈢畻姣旂巼",
+    //   minWidth: 130,
+    // },
     {
       field: "warehouseName",
       title: "榛樿浠撳簱",
       minWidth: 100,
     },
-    {
-      field: "purchasePrice",
-      title: "閲囪喘浠�",
-      minWidth: 100,
-      formatter: ({ cellValue }) => {
-        return cellValue != null ? `楼${Number(cellValue).toFixed(2)}` : "";
-      },
-    },
-    {
-      field: "salesPrice",
-      title: "閿�鍞环",
-      minWidth: 100,
-      formatter: ({ cellValue }) => {
-        return cellValue != null ? `楼${Number(cellValue).toFixed(2)}` : "";
-      },
-    },
+    // 閿�鍞环锛氱墿鏂欏垪琛ㄤ笉鍐嶅睍绀猴紝闇�瑕佹仮澶嶅氨鍙栨秷娉ㄩ噴
+    // {
+    //   field: "salesPrice",
+    //   title: "閿�鍞环",
+    //   minWidth: 100,
+    //   formatter: ({ cellValue }) => {
+    //     return cellValue != null ? `楼${Number(cellValue).toFixed(2)}` : "";
+    //   },
+    // },
     {
       field: "createTime",
       title: "鍒涘缓鏃堕棿",
       minWidth: 180,
-      formatter: "formatDateTime",
+      formatter: 'formatDate',
     },
     {
       field: "isBatchManaged",
@@ -597,7 +602,7 @@
     {
       field: "syncedMes",
       title: "鍚屾鐘舵��",
-      width: 90,
+      width: 100,
       fixed: "right",
       slots: { default: "syncedMes" },
     },
@@ -619,3 +624,27 @@
     },
   ];
 }
+
+/** 鐗╂枡瀵煎叆鐨勮〃鍗� */
+export function useImportFormSchema(): VbenFormSchema[] {
+  return [
+    {
+      fieldName: 'file',
+      label: '鐗╂枡鏁版嵁',
+      component: 'Upload',
+      rules: 'required',
+      help: '浠呭厑璁稿鍏� xls銆亁lsx 鏍煎紡鏂囦欢',
+    },
+    {
+      fieldName: 'updateSupport',
+      label: '鏄惁瑕嗙洊',
+      component: 'Switch',
+      componentProps: {
+        checkedChildren: '鏄�',
+        unCheckedChildren: '鍚�',
+      },
+      rules: z.boolean().default(false),
+      help: '鏄惁鏇存柊宸茬粡瀛樺湪鐨勭墿鏂欐暟鎹�',
+    },
+  ];
+}

--
Gitblit v1.9.3