From 7e9e0bff3ef15366693648f25810723ec557ed62 Mon Sep 17 00:00:00 2001
From: chengxiangling <291105840@qq.com>
Date: 星期二, 13 五月 2025 08:52:11 +0800
Subject: [PATCH] 提交修改查询样式,工单计划管理等

---
 src/views/mainPlan/sheetMetalOrderManage/index.vue |  122 ++++++++++++++++++++++++++--------------
 1 files changed, 79 insertions(+), 43 deletions(-)

diff --git a/src/views/mainPlan/sheetMetalOrderManage/index.vue b/src/views/mainPlan/sheetMetalOrderManage/index.vue
index 39583be..63584eb 100644
--- a/src/views/mainPlan/sheetMetalOrderManage/index.vue
+++ b/src/views/mainPlan/sheetMetalOrderManage/index.vue
@@ -6,11 +6,12 @@
       ref="queryRef"
       :inline="true"
       v-show="showSearch"
-      :label-width="locale == 'zh' ? '110px' : '200px'"
+      label-position="left"
     >
       <el-row type="flex" justify="left">
         <el-col :span="12">
           <el-form-item
+            :label-width="locale == 'zh' ? '80px' : '160px'"
             :label="$t('plan.query.workOrderNo')"
             prop="workOrderNo"
           >
@@ -27,6 +28,7 @@
         </el-col>
         <el-col :span="12">
           <el-form-item
+            :label-width="locale == 'zh' ? '100px' : '200px'"
             :label="$t('plan.query.requireTraceID')"
             prop="requireTrackId"
           >
@@ -45,6 +47,7 @@
       <el-row type="flex" justify="left">
         <el-col :span="12">
           <el-form-item
+            :label-width="locale == 'zh' ? '80px' : '160px'"
             :label="$t('plan.query.itemNumber')"
             prop="mainPartNumber"
           >
@@ -61,6 +64,7 @@
         </el-col>
         <el-col :span="12">
           <el-form-item
+            :label-width="locale == 'zh' ? '100px' : '200px'"
             :label="$t('plan.table.delayRiskIdentification')"
             prop="hasDelayRisk"
           >
@@ -156,15 +160,15 @@
           link
           @click="handleCheckView(row)"
           v-hasPermi="['ApsPlatOrderPlanManager:requirement:list']"
-          >{{ $t("plan.btns.viewRequirement") }}</el-button
+          >{{ $t("plan.btns.viewRequirement") }}({{row.requireNum}})</el-button
         >
       </template>
     </HxlhTable>
     <el-dialog
       :title="$t('plan.title.viewAssociatedRequirements')"
       v-model="openDialog"
-      width="900px"
-      style="height: 400px; overflow: hidden"
+      width="85%"
+      style="height:90vh; overflow: hidden"
       append-to-body
     >
       <HxlhTable
@@ -172,7 +176,7 @@
         :columns="subGridOptions"
         :data="subList"
         :loading="loadingSub"
-        :height="'280px'"
+        :height="heightSub"
       >
       </HxlhTable>
       <template #footer>
@@ -186,8 +190,8 @@
     <el-dialog
       :title="$t('plan.btns.batchUpdateOrderDate')"
       v-model="openBatchDialog"
-      width="900px"
-      style="min-height: 400px; overflow: hidden"
+      width="85%"
+      style="min-height:90vh; overflow: hidden"
       append-to-body
     >
       <div class="mode_box">
@@ -223,7 +227,7 @@
         :columns="subUpdateGridOptions"
         :data="subUpdateList"
         :loading="loading"
-        :height="'210px'"
+        :height="heightSubUpdate"
       >
       </HxlhTable>
       <HxlhTable
@@ -232,7 +236,7 @@
         :columns="subUpdateCustomGridOptions"
         :data="subUpdateList"
         :loading="loading"
-        :height="'210px'"
+        :height="heightSubUpdate"
       >
       </HxlhTable>
       <template #footer>
@@ -269,6 +273,9 @@
 const { t, locale } = useI18n();
 const basicStore = useBasicStore();
 const { proxy } = getCurrentInstance();
+const { aps_work_order_type } = proxy.useDict("aps_work_order_type");
+const { aps_factory   } = proxy.useDict("aps_factory");
+const { aps_has_risk   } = proxy.useDict("aps_has_risk");
 const delayRiskOptions = ref([]);
 const radio = ref(1);
 const customicDate = ref("");
@@ -310,6 +317,8 @@
 const allShopList = ref([]);
 const processList = ref([]);
 const height = ref(document.documentElement.clientHeight - 320 + "px;");
+const heightSub = ref(document.documentElement.clientHeight - 200 + "px;");
+const heightSubUpdate = ref(document.documentElement.clientHeight - 270 + "px;");
 // 琛ㄦ牸閰嶇疆-鍒楄〃
 const columns = ref([]);
 // 鍒嗛〉灞炴��
@@ -333,12 +342,12 @@
     ];
     columns.value = [
       { type: "checkbox", width: 60, align: "center", fixed: "left" },
-      {
-        title: t("basic.table.requirementID"),
-        field: "requireId",
-        width: 150,
-        align: "center",
-      },
+      // {
+      //   title: t("basic.table.requirementID"),
+      //   field: "requireId",
+      //   width: 150,
+      //   align: "center",
+      // },
       {
         title: t("basic.table.requirementTraceabilityID"),
         field: "requireTrackId",
@@ -362,6 +371,15 @@
         field: "workOrderType",
         width: 200,
         align: "center",
+        formatter: ({ cellValue, row, column }) => {
+          if (cellValue) {
+            for (let i = 0; i < aps_work_order_type.value.length; i++) {
+              if (cellValue === aps_work_order_type.value[i].value) {
+                return aps_work_order_type.value[i].label;
+              }
+            }
+          }
+        },
       },
       {
         title: t("plan.table.itemNumber"),
@@ -394,9 +412,9 @@
         align: "center",
         formatter: ({ cellValue, row, column }) => {
           if (cellValue) {
-            for (let i = 0; i < plantList.value.length; i++) {
-              if (cellValue === plantList.value[i].plantCode) {
-                return plantList.value[i].plantName;
+            for (let i = 0; i < aps_factory.value.length; i++) {
+              if (cellValue === aps_factory.value[i].value) {
+                return aps_factory.value[i].label;
               }
             }
           }
@@ -439,16 +457,16 @@
         align: "center",
         formatter: ({ cellValue, row, column }) => {
           if (cellValue) {
-            for (let i = 0; i < delayRiskOptions.value.length; i++) {
-              if (cellValue === delayRiskOptions.value[i].value) {
-                return delayRiskOptions.value[i].label;
+            for (let i = 0; i < aps_has_risk.value.length; i++) {
+              if (cellValue === aps_has_risk.value[i].value) {
+                return aps_has_risk.value[i].label;
               }
             }
           }
         },
       },
       {
-        title: t("common.common.operate"),
+        title: t("common.common.require"),
         width: 150,
         fixed: "right",
         slots: { default: "buttons" },
@@ -462,12 +480,12 @@
         width: 150,
         align: "center",
       },
-      {
-        title: t("basic.table.requirementTraceabilityID"),
-        field: "requireId",
-        width: 200,
-        align: "center",
-      },
+      // {
+      //   title: t("basic.table.requirementTraceabilityID"),
+      //   field: "requireId",
+      //   width: 200,
+      //   align: "center",
+      // },
       {
         title: t("plan.table.itemNumber"),
         field: "bomLineCode",
@@ -571,9 +589,9 @@
         align: "center",
         formatter: ({ cellValue, row, column }) => {
           if (cellValue) {
-            for (let i = 0; i < delayRiskOptions.value.length; i++) {
-              if (cellValue === delayRiskOptions.value[i].value) {
-                return delayRiskOptions.value[i].label;
+            for (let i = 0; i < aps_has_risk.value.length; i++) {
+              if (cellValue === aps_has_risk.value[i].value) {
+                return aps_has_risk.value[i].label;
               }
             }
           }
@@ -581,12 +599,12 @@
       },
     ];
     subUpdateGridOptions.value = [
-      {
-        title: t("basic.table.requirementID"),
-        field: "requireId",
-        width: 150,
-        align: "center",
-      },
+      // {
+      //   title: t("basic.table.requirementID"),
+      //   field: "requireId",
+      //   width: 150,
+      //   align: "center",
+      // },
       {
         title: t("basic.table.requirementTraceabilityID"),
         field: "requireTrackId",
@@ -610,6 +628,15 @@
         field: "workOrderType",
         width: 200,
         align: "center",
+        formatter: ({ cellValue, row, column }) => {
+          if (cellValue) {
+            for (let i = 0; i < aps_work_order_type.value.length; i++) {
+              if (cellValue === aps_work_order_type.value[i].value) {
+                return aps_work_order_type.value[i].label;
+              }
+            }
+          }
+        },
       },
       {
         title: t("plan.table.itemNumber"),
@@ -643,12 +670,12 @@
       },
     ];
     subUpdateCustomGridOptions.value = [
-      {
-        title: t("basic.table.requirementID"),
-        field: "requireId",
-        width: 150,
-        align: "center",
-      },
+      // {
+      //   title: t("basic.table.requirementID"),
+      //   field: "requireId",
+      //   width: 150,
+      //   align: "center",
+      // },
       {
         title: t("basic.table.requirementTraceabilityID"),
         field: "requireTrackId",
@@ -672,6 +699,15 @@
         field: "workOrderType",
         width: 200,
         align: "center",
+        formatter: ({ cellValue, row, column }) => {
+          if (cellValue) {
+            for (let i = 0; i < aps_work_order_type.value.length; i++) {
+              if (cellValue === aps_work_order_type.value[i].value) {
+                return aps_work_order_type.value[i].label;
+              }
+            }
+          }
+        },
       },
       {
         title: t("plan.table.itemNumber"),

--
Gitblit v1.9.3