Commit 0da0b1e1 authored by 沈翠玲's avatar 沈翠玲

生产排产

parent aa10ea99
...@@ -163,7 +163,7 @@ ...@@ -163,7 +163,7 @@
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row> </el-row>
<el-table v-loading="loading" :data="maintenanceList" @selection-change="handleSelectionChange"> <el-table v-loading="loading" :data="maintenanceList" @selection-change="handleSelectionChange" ref="tableRef">
<el-table-column type="selection" width="55" align="center" /> <el-table-column type="selection" width="55" align="center" />
<el-table-column label="编排单号" width="120" prop="arrangeCode"> <el-table-column label="编排单号" width="120" prop="arrangeCode">
<template slot-scope="scope"> <template slot-scope="scope">
...@@ -526,6 +526,7 @@ import { ...@@ -526,6 +526,7 @@ import {
getdefaultWorkCenterList} from '@/api/mes/pro/scheduleList' getdefaultWorkCenterList} from '@/api/mes/pro/scheduleList'
import {putProtaskSplit} from '@/api/mes/pro/protask' import {putProtaskSplit} from '@/api/mes/pro/protask'
import BrandSelect from "@/components/TmTool/index.vue"; import BrandSelect from "@/components/TmTool/index.vue";
import shiftSelectMixin from '@/utils/shiftSelectMixin'
import OrderList from './orderList.vue' import OrderList from './orderList.vue'
import jobAssign from './jobAssign.vue' import jobAssign from './jobAssign.vue'
import arrangCodeList from './arrangCodeList.vue' import arrangCodeList from './arrangCodeList.vue'
...@@ -536,9 +537,11 @@ export default { ...@@ -536,9 +537,11 @@ export default {
components: {BrandSelect, OrderList, arrangCodeList, WorkuintSelect, jobAssign, taskList}, components: {BrandSelect, OrderList, arrangCodeList, WorkuintSelect, jobAssign, taskList},
dicts: ['TASK_STATUS'], dicts: ['TASK_STATUS'],
name: "scheduleList", name: "scheduleList",
mixins: [shiftSelectMixin],
data() { data() {
return { return {
currentData: {}, currentData: {},
keyValue: 'taskWorkunitId',
currentTask: null, currentTask: null,
workshopList: [], workshopList: [],
workstationList: [], workstationList: [],
...@@ -575,7 +578,7 @@ export default { ...@@ -575,7 +578,7 @@ export default {
title: "", title: "",
// 是否显示弹出层 // 是否显示弹出层
open: false, open: false,
selections: [], selectedRows: [],
workstationId: null, workstationId: null,
// 查询参数 // 查询参数
queryParams: { queryParams: {
...@@ -615,7 +618,7 @@ export default { ...@@ -615,7 +618,7 @@ export default {
this.arrangCodeVisible = true this.arrangCodeVisible = true
}, },
handleSubmitJobAssignment() { handleSubmitJobAssignment() {
let datas = Object.assign({}, this.selections[0]); let datas = Object.assign({}, this.selectedRows[0]);
datas.taskWorkunit = this.Assignform; datas.taskWorkunit = this.Assignform;
delete datas.proWorkorderList; delete datas.proWorkorderList;
putProtaskSplit(datas).then((res) => { putProtaskSplit(datas).then((res) => {
...@@ -664,9 +667,9 @@ export default { ...@@ -664,9 +667,9 @@ export default {
workunitName: null, workunitName: null,
workunitId: null workunitId: null
}; };
this.workstationId = this.selections[0].workstationId this.workstationId = this.selectedRows[0].workstationId
this.taskId = this.selections[0].taskId this.taskId = this.selectedRows[0].taskId
console.log('this.selections[0]', this.selections[0]) console.log('this.selectedRows[0]', this.selectedRows[0])
this.jobAssignmentVisible = true; this.jobAssignmentVisible = true;
}, },
handleChangeWorkStationId(item) { handleChangeWorkStationId(item) {
...@@ -797,14 +800,6 @@ export default { ...@@ -797,14 +800,6 @@ export default {
handleBrandSelect(){ handleBrandSelect(){
this.$refs.brSelect.showFlag = true; this.$refs.brSelect.showFlag = true;
}, },
// 多选框选中数据
handleSelectionChange(selection) {
this.ids = selection.map(item => item.taskWorkunitId)
this.selections = selection
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */ /** 新增按钮操作 */
handleSchedule() { handleSchedule() {
this.scheduleVisible = true this.scheduleVisible = true
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment