ysy 2 tahun lalu
induk
melakukan
059057f822

+ 10 - 0
src/api/workforceManagement/team.js

@@ -88,4 +88,14 @@ export async function settingTeamTime(data) {
         return res.data.message;
         return res.data.message;
     }
     }
     return Promise.reject(new Error(res.data.message));
     return Promise.reject(new Error(res.data.message));
+}
+
+// 根据班组ids查所有人信息
+export async function listUserByIds(data) {
+    const res = await request.post(`/main/team/listUserByIds`, data);
+    console.log(res.data.code == 0)
+    if (res.data.code == 0) {
+        return res.data.data        ;
+    }
+    return Promise.reject(new Error(res.data.message));
 }
 }

+ 1 - 1
src/views/technology/production/components/user-setting.vue

@@ -6,7 +6,7 @@
     :append-to-body="true"
     :append-to-body="true"
     :close-on-click-modal="true"
     :close-on-click-modal="true"
     custom-class="ele-dialog-form"
     custom-class="ele-dialog-form"
-    :title="`给工序【${this.data?.code}${this.data?.name}】配置参数`"
+    :title="`给工序配置参数`"
     @update:visible="updateVisible"
     @update:visible="updateVisible"
   >
   >
     <div class="ele-body">
     <div class="ele-body">

+ 1 - 1
src/views/technology/route/components/production/components/user-setting.vue

@@ -6,7 +6,7 @@
     :append-to-body="true"
     :append-to-body="true"
     :close-on-click-modal="true"
     :close-on-click-modal="true"
     custom-class="ele-dialog-form"
     custom-class="ele-dialog-form"
-    :title="`给工序【${this.data?.code}${this.data?.name}】配置参数`"
+    :title="`给工序配置参数`"
     @update:visible="updateVisible"
     @update:visible="updateVisible"
   >
   >
     <div class="ele-body">
     <div class="ele-body">

+ 37 - 4
src/views/workforceManagement/schedule/components/SchedulingGroup.vue

@@ -18,6 +18,8 @@
           placeholder="请选择"
           placeholder="请选择"
           style="width: 100%"
           style="width: 100%"
           multiple
           multiple
+          filterable
+          @change="changeTeam"
         >
         >
           <el-option
           <el-option
             v-for="item in options"
             v-for="item in options"
@@ -28,6 +30,26 @@
           </el-option>
           </el-option>
         </el-select>
         </el-select>
       </el-form-item>
       </el-form-item>
+
+
+      <el-form-item label="姓名"  style="margin-bottom: 22px">
+        <el-select
+          v-model="form.checkedUserIds"
+          placeholder="请选择"
+          style="width: 100%"
+          multiple
+         filterable
+        >
+          <el-option
+            v-for="item in userOptions"
+            :key="item.id"
+            :label="item.name"
+            :value="item.id"
+          >
+          </el-option>
+        </el-select>
+      </el-form-item>
+
     </el-form>
     </el-form>
     <template v-slot:footer>
     <template v-slot:footer>
       <el-button @click="handleClose">取消</el-button>
       <el-button @click="handleClose">取消</el-button>
@@ -39,13 +61,14 @@
 </template>
 </template>
   
   
   <script>
   <script>
-import { getteampage } from '@/api/workforceManagement/team';
+import { getteampage, listUserByIds } from '@/api/workforceManagement/team';
 import { teamqueuesave } from '@/api/workforceManagement/schedule';
 import { teamqueuesave } from '@/api/workforceManagement/schedule';
 export default {
 export default {
   data() {
   data() {
     const defaultForm = {
     const defaultForm = {
       name: '',
       name: '',
-      teamIds: []
+      teamIds: [],
+      checkedUserIds: []
     };
     };
     return {
     return {
       defaultForm,
       defaultForm,
@@ -58,7 +81,8 @@ export default {
       },
       },
       visible: false,
       visible: false,
       loading: false,
       loading: false,
-      options: []
+      options: [],
+      userOptions: []
     };
     };
   },
   },
   methods: {
   methods: {
@@ -105,7 +129,16 @@ export default {
       getteampage().then((res) => {
       getteampage().then((res) => {
         this.options = res.list;
         this.options = res.list;
       });
       });
-    }
+    },
+
+    changeTeam() {
+      console.log()
+
+      listUserByIds( this.form.teamIds).then(res => {
+
+        this.userOptions = res
+      })
+    },
   }
   }
 };
 };
 </script>
 </script>