From 80f27f1672467e91ff3d4fd7f30a817f6f11d5c0 Mon Sep 17 00:00:00 2001
From: CD配唱片 <CD配唱片>
Date: 星期五, 25 四月 2025 22:55:48 +0800
Subject: [PATCH] Merge branch 'dev' of http://192.168.50.149:8085/r/aps-kj-web into dev

---
 src/views/mainPlan/plateProcessStat/index.vue |   83 +++++++++++++++++++++++++++++++----------
 1 files changed, 63 insertions(+), 20 deletions(-)

diff --git a/src/views/mainPlan/plateProcessStat/index.vue b/src/views/mainPlan/plateProcessStat/index.vue
index f43828a..1c9d002 100644
--- a/src/views/mainPlan/plateProcessStat/index.vue
+++ b/src/views/mainPlan/plateProcessStat/index.vue
@@ -101,7 +101,7 @@
 const multiple = ref(true);
 const total = ref(0);
 const title = ref("");
-const height = ref(document.documentElement.clientHeight - 270 + "px;")
+const height = ref(document.documentElement.clientHeight - 220 + "px;")
 
 
 const data = reactive({
@@ -131,7 +131,7 @@
 
 // 琛ㄦ牸閰嶇疆
 const columns = ref([
-  { type: 'seq', title: '搴忓彿', width: 60 },
+/*  { type: 'seq', title: '搴忓彿', width: 60 },*/
   {
     title: '宸ュ崟鍙�',
     field: 'workOrderNo',
@@ -140,47 +140,50 @@
   {
     title: '宸ュ簭鍚嶇О',
     field: 'processName',
-    width: 250,
   },
   {
     title: '宸ュ簭鍙�',
-    field: 'routeProcessNumber',
-    width: 150,
+    field: 'routeProcessNumberTxt',
+    width: 100,
   },
   {
     title: '褰撳墠宸ュ簭鍙�',
-    field: 'currentProcessNumber',
-    width: 150,
+    field: 'currentProcessNumberTxt',
+    width: 100,
   },
   {
     title: '鐢熶骇鏁伴噺',
     field: 'productionQuantity',
-    width: 100,
+    width: 80,
   },
   {
     title: '鏍囧噯宸ユ椂',
     field: 'standardTime',
-    width: 100,
+    width: 80,
   },
   {
     title: '宸ュ簭鎬诲伐鏃�',
     field: 'processTotalTime',
-    width: 100,
+    width: 80,
+
   },
   {
     title: '璁″垝寮�宸ユ棩',
-    field: 'processPlanStartDay',
-    width: 200,
+    field: 'processPlanStartDaytxt',
+    width: 140,
+    type:'html'
   },
   {
     title: '璁″垝瀹屽伐鏃�',
-    field: 'processPlanEndDay',
-    width: 200,
+    field: 'processPlanEndDaytxt',
+    width: 140,
+    type:'html'
   },
   {
     title: '璁㈠崟瀹屽伐鏃�',
     field: 'orderPlanEndDay',
-    width: 200,
+    width: 120,
+    format: 'YYYY-MM-DD'
   }
 ]);
 
@@ -190,7 +193,16 @@
 function getList() {
   loading.value = true;
   listPlateStat(queryParams.value).then(response => {
-    aps_plate_process_statList.value = response.rows;
+    const listValue = response.rows;
+    listValue.forEach(listItem => {
+      listItem[`processPlanStartDaytxt`]= listItem.warning? `<font color="red">${listItem.processPlanStartDay}</font>`  :listItem.processPlanStartDay;
+      listItem[`processPlanEndDaytxt`]= listItem.warning? `<font color="red">${listItem.processPlanEndDay}</font>`  :listItem.processPlanEndDay;
+      listItem[`routeProcessNumberTxt`]= listItem.routeProcessNumber.toString().padStart(3, '0');
+      listItem[`currentProcessNumberTxt`]= listItem.currentProcessNumber.toString().padStart(3, '0');
+
+
+    });
+    aps_plate_process_statList.value =listValue
     total.value = response.total;
     loading.value = false;
   });
@@ -232,6 +244,7 @@
 
 /** 閲嶇疆鎸夐挳鎿嶄綔 */
 function resetQuery() {
+  queryParams.value.workOrderNo ='';
   proxy.resetForm("queryRef");
   handleQuery();
 }
@@ -255,9 +268,6 @@
   reset();
   updateStat().then(response => {
     form.value = response.data;
-    open.value = true;
-    title.value = "淇敼閽i噾缁熻";
-
     ElMessage({
       message: '鏁版嵁鏇存柊鎴愬姛',
       type: 'success',
@@ -304,6 +314,39 @@
     ...queryParams.value
   }, `aps_plate_process_stat_${new Date().getTime()}.xlsx`)
 }
-
+const headerCellClassName = ({ column }) => {
+  if (column.field === 'name') {
+    return 'col-blue'
+  }
+  return null
+}
+const rowClassName = ({ rowIndex }) => {
+  if ([2, 3, 5].includes(rowIndex)) {
+    return 'row-green'
+  }
+  return null
+}
+const cellClassName = ({ row, column }) => {
+  if (column.field === 'processPlanStartDay'||column.field === 'processPlanEndDay') {
+    if (row.warning) {
+      return 'col-orange'
+    }
+  }
+  return null
+}
 getList();
 </script>
+<style lang="scss" scoped>
+::v-deep(.mytable-style.vxe-table .vxe-body--row.row-green) {
+  background-color: #187;
+  color: #fff;
+}
+::v-deep(.mytable-style.vxe-table .vxe-header--column.col-blue) {
+  background-color: #2db7f5;
+  color: #fff;
+}
+::v-deep(.mytable-style.vxe-table .vxe-body--column.col-red) {
+  background-color: red;
+  color: #fff;
+}
+</style>
\ No newline at end of file

--
Gitblit v1.9.3