From 1f4e7d0f73a73e7350cf5a1df279d5f30904c5d5 Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期三, 06 十二月 2023 08:41:32 +0800
Subject: [PATCH] bug

---
 web_standard/src/views/business/workPlans.vue |   42 +++++++++++++++++++++++++++++++++++-------
 1 files changed, 35 insertions(+), 7 deletions(-)

diff --git a/web_standard/src/views/business/workPlans.vue b/web_standard/src/views/business/workPlans.vue
index 222ae5d..7dfff6f 100644
--- a/web_standard/src/views/business/workPlans.vue
+++ b/web_standard/src/views/business/workPlans.vue
@@ -1,7 +1,7 @@
 <template>
   <TableLayout :permissions="['ext:workplans:query']">
     <!-- 鎼滅储琛ㄥ崟 -->
-    <el-form ref="searchForm" slot="search-form" label-suffix="锛�" :model="searchForm" label-width="90px" inline>
+    <el-form ref="searchForm" slot="search-form" label-suffix="锛�" :model="searchForm" label-width="110px" inline>
       <el-form-item label="鐗╂枡鍚嶇О" prop="materialName">
         <el-input v-model="searchForm.materialName" placeholder="璇疯緭鍏�" @keypress.enter.native="search"></el-input>
       </el-form-item>
@@ -26,8 +26,16 @@
       <el-form-item label="鎵规鍙�" prop="batch">
         <el-input v-model="searchForm.batch" placeholder="璇疯緭鍏�" @keypress.enter.native="search"></el-input>
       </el-form-item>
-      <el-form-item label="璁″垝鏃ユ湡" prop="planDate">
-        <el-date-picker style="width: 300px;" @change="changeDate" v-model="searchForm.planDate" type="datetimerange"
+      <el-form-item label="閿�鍞崟鍙�" prop="salesorder">
+        <el-input v-model="searchForm.salesorder" placeholder="璇疯緭鍏�" @keypress.enter.native="search"></el-input>
+      </el-form-item>
+      <el-form-item label="璁″垝寮�濮嬫棩鏈�" prop="startDate">
+        <el-date-picker style="width: 300px;" @change="changeStartDate" v-model="startDate" type="daterange"
+          value-format="yyyy-MM-dd" range-separator="鑷�" start-placeholder="寮�濮嬫棩鏈�" end-placeholder="缁撴潫鏃ユ湡">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="璁″垝瀹屾垚鏃ユ湡" prop="planDate">
+        <el-date-picker style="width: 300px;" @change="changeDate" v-model="planDate" type="daterange"
           value-format="yyyy-MM-dd" range-separator="鑷�" start-placeholder="寮�濮嬫棩鏈�" end-placeholder="缁撴潫鏃ユ湡">
         </el-date-picker>
       </el-form-item>
@@ -45,7 +53,7 @@
           <ImportButton
             text="瀵煎叆"
             template-name="workplans_import_template.xlsx"
-            template-path="template/workplans_import_template.xlsx"
+            template-path="/template/workplans_import_template.xlsx"
             action="/business/workPlans/importBatch"
             @success="search"
           />
@@ -57,11 +65,12 @@
       </ul>
       <el-table v-loading="isWorking.search" :data="tableData.list" border stripe @selection-change="handleSelectionChange">
         <el-table-column type="selection" width="55"></el-table-column>
-        <el-table-column prop="planCode" label="鎴愬搧璁″垝缂栫爜" min-width="150px">
+        <el-table-column prop="planCode" label="鎴愬搧璁″垝缂栫爜" min-width="190px">
           <template slot-scope="{row}">
             <el-button type="text" @click="$refs.plannedProgress.open('璁″垝鎵ц杩涘害', row)">
               <span class="long-title-style">{{ row.planCode }}</span>
             </el-button>
+            <el-tag type="danger" size="mini" v-if="row.hasExpire">寤舵湡</el-tag>
           </template>
         </el-table-column>
         <el-table-column prop="materialName" label="鐗╂枡鍚嶇О" min-width="100px"></el-table-column>
@@ -92,13 +101,13 @@
         </el-table-column>
         <el-table-column label="瀹屽伐鍚堟牸鏁�" min-width="100px">
           <template slot-scope="{row}">
-            <span v-if="row.finishQualifiedNum">{{ row.finishQualifiedNum }}</span>
+            <span class="valid-style" v-if="row.finishQualifiedNum">{{ row.finishQualifiedNum }}</span>
             <span v-else>-</span>
           </template>
         </el-table-column>
         <el-table-column label="瀹屽伐涓嶈壇鏁�" min-width="100px">
           <template slot-scope="{row}">
-            <span v-if="row.finishUnQualifiedNum">{{ row.finishUnQualifiedNum }}</span>
+            <span class="unvalid-style" v-if="row.finishUnQualifiedNum">{{ row.finishUnQualifiedNum }}</span>
             <span v-else>-</span>
           </template>
         </el-table-column>
@@ -181,13 +190,18 @@
         materialCode: '',
         planDateStart: '',
         planDateEnd: '',
+        startDateEnd: '',
+        startDateStart: '',
         factoryId: '',
         materialId: '',
         batch: '',
+        salesorder: '',
         planStatus: '',
         planCode: ''
       },
       ids: [],
+      planDate: [],
+      startDate: [],
       statusList: [
         { label: '宸茬敓鎴�', value: 0 },
         { label: '鎵ц涓�', value: 1 },
@@ -340,9 +354,23 @@
       }
       this.search()
     },
+    changeStartDate(e) {
+      if (e) {
+        this.searchForm.startDateStart = e[0]
+        this.searchForm.startDateEnd = e[1]
+      } else {
+        this.searchForm.startDateStart = ''
+        this.searchForm.startDateEnd = ''
+      }
+      this.search()
+    },
     resets() {
       this.searchForm.planDateStart = ''
       this.searchForm.planDateEnd = ''
+      this.searchForm.startDateStart = ''
+      this.searchForm.startDateEnd = ''
+      this.planDate = []
+      this.startDate = []
       this.reset()
     }
   }

--
Gitblit v1.9.3