From e65bfa1d46d255f307eaa057665f01c8bde0e122 Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期二, 16 六月 2026 11:14:36 +0800
Subject: [PATCH] 君歌 1.端口修改

---
 src/views/productionManagement/workOrderEdit/index.vue |   52 +++++++++++++++++++++++++++++++++++++++++++---------
 1 files changed, 43 insertions(+), 9 deletions(-)

diff --git a/src/views/productionManagement/workOrderEdit/index.vue b/src/views/productionManagement/workOrderEdit/index.vue
index 64fd087..e215fdb 100644
--- a/src/views/productionManagement/workOrderEdit/index.vue
+++ b/src/views/productionManagement/workOrderEdit/index.vue
@@ -47,16 +47,16 @@
                label-width="120px">
         <el-form-item label="璁″垝寮�濮嬫椂闂�">
           <el-date-picker v-model="editrow.planStartTime"
-                          type="date"
+                          type="datetime"
                           placeholder="璇烽�夋嫨"
-                          value-format="YYYY-MM-DD"
+                          value-format="YYYY-MM-DD HH:mm:ss"
                           style="width: 300px" />
         </el-form-item>
         <el-form-item label="璁″垝缁撴潫鏃堕棿">
           <el-date-picker v-model="editrow.planEndTime"
-                          type="date"
+                          type="datetime"
                           placeholder="璇烽�夋嫨"
-                          value-format="YYYY-MM-DD"
+                          value-format="YYYY-MM-DD HH:mm:ss"
                           style="width: 300px" />
         </el-form-item>
       </el-form>
@@ -73,6 +73,18 @@
                title="鎸囧畾鎶ュ伐浜�"
                width="800px">
       <div class="assign-reporter-content">
+        <div class="search-box">
+          <el-input
+            v-model="employeeSearchKeyword"
+            placeholder="鎼滅储浜哄憳濮撳悕"
+            clearable
+            @input="handleEmployeeSearch"
+            style="width: 350px">
+            <template #prefix>
+              <i class="el-icon-search"></i>
+            </template>
+          </el-input>
+        </div>
         <div class="selected-tags-box"
              v-if="selectedEmployeeIds.length > 0">
           <div class="tags-label">宸查�夋嫨锛�</div>
@@ -90,7 +102,7 @@
              v-loading="employeeTableLoading">
           <el-checkbox-group v-model="selectedEmployeeIds">
             <div class="employee-grid">
-              <div v-for="item in employeeTableData"
+              <div v-for="item in filteredEmployeeList"
                    :key="item.userId"
                    class="employee-item">
                 <el-checkbox :label="item.userId"
@@ -103,9 +115,9 @@
               </div>
             </div>
           </el-checkbox-group>
-          <div v-if="employeeTableData.length === 0"
+          <div v-if="filteredEmployeeList.length === 0"
                class="empty-text">
-            鏆傛棤鍖归厤浜哄憳
+            {{ employeeSearchKeyword ? '鏃犲尮閰嶄汉鍛�' : '鏆傛棤浜哄憳鏁版嵁' }}
           </div>
         </div>
       </div>
@@ -121,7 +133,7 @@
 </template>
 
 <script setup>
-  import { getCurrentInstance, onMounted, reactive, ref, toRefs } from "vue";
+  import { getCurrentInstance, onMounted, reactive, ref, toRefs, computed } from "vue";
   import { ElMessageBox } from "element-plus";
   import {
     productWorkOrderPage,
@@ -253,8 +265,24 @@
   const employeeSearchForm = reactive({
     staffName: "",
   });
+  const employeeSearchKeyword = ref("");
   const selectedEmployeeIds = ref([]);
   const currentWorkOrder = ref(null);
+
+  const filteredEmployeeList = computed(() => {
+    const keyword = employeeSearchKeyword.value.trim().toLowerCase();
+    if (!keyword) {
+      return employeeTableData.value;
+    }
+    return employeeTableData.value.filter(item => {
+      const name = (item.nickName || "").toLowerCase();
+      const dept = (item.dept?.deptName || "").toLowerCase();
+      return name.includes(keyword) || dept.includes(keyword);
+    });
+  });
+
+  const handleEmployeeSearch = () => {
+  };
 
   const data = reactive({
     searchForm: {
@@ -269,7 +297,7 @@
     if (!Number.isFinite(n)) return 0;
     if (n <= 0) return 0;
     if (n >= 100) return 100;
-    return Math.round(n);
+    return parseFloat(n.toFixed(2));
   };
 
   const progressColor = percentage => {
@@ -416,6 +444,12 @@
   }
 
   .assign-reporter-content {
+    .search-box {
+      margin-bottom: 16px;
+      display: flex;
+      justify-content: center;
+    }
+
     .selected-tags-box {
       margin-bottom: 16px;
       padding: 12px;

--
Gitblit v1.9.3