Commit c9970636 authored by 张海景's avatar 张海景

update:修改生产排产新增编排单详情功能

parent bd842f5d
...@@ -34,3 +34,12 @@ export function makeSchedule(query) { ...@@ -34,3 +34,12 @@ export function makeSchedule(query) {
data: query, data: query,
}); });
} }
// 查询任务工作单元列表
export function taskWorkunitList(query) {
return request({
url: "/mes/pro/taskWorkunit/workorderList",
method: "post",
data: query,
});
}
<template>
<div>
<el-table
v-loading="loading"
:data="itemList"
>
<!-- <el-table-column type="selection" width="55" align="center"/> -->
<el-table-column label="生产工单号" width="180" prop="workorderCode"/>
<el-table-column label="产品编号" width="180" prop="productCode"/>
<el-table-column label="产品名称" prop="productName"/>
<el-table-column label="规格" width="140" prop="productSpc"/>
<el-table-column label="需求日期" width="140" prop="requestDate"/>
</el-table>
</div>
</template>
<script>
import {
taskWorkunitList
} from "@/api/mes/pro/scheduleList";
export default {
name: "arrangCodeList",
components: { },
data() {
return {
showFlag: false,
// 选中数组
ids: [],
selectedRows: [],
// 非单个禁用
single: true,
// 非多个禁用
multiple: true,
// 显示搜索条件
showSearch: true,
// 物料产品表格数据
itemList: null,
loading: false,
};
},
created() {
},
mounted() {
this.getList();
},
methods: {
/** 查询物料编码列表 */
getList() {
this.loading = true;
const params = new FormData()
params.append('taskWorkunitId', this.$attrs.taskWorkunitId)
taskWorkunitList(params).then((response) => {
this.itemList = response;
this.loading = false;
});
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.queryParams.statusArr = ["ORCHESTRATED"]
this.handleQuery();
},
// 多选框选中数据
handleSelectionChange(selection) {
this.ids = selection.map(item => item.workorderId);
this.single = selection.length != 1;
this.multiple = !selection.length;
this.selectedRows = selection;
},
},
};
</script>
...@@ -106,6 +106,16 @@ ...@@ -106,6 +106,16 @@
>{{ scope.row.taskCode }}</el-button >{{ scope.row.taskCode }}</el-button
> >
</template> </template>
</el-table-column>
<el-table-column label="编排单号" width="120" prop="arrangeCode">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
@click="taskWorkunitId= scope.row.taskWorkunitId, arrangCodeVisible = true"
>{{ scope.row.arrangeCode }}</el-button
>
</template>
</el-table-column> </el-table-column>
<!-- <el-table-column <!-- <el-table-column
label="任务单名称" label="任务单名称"
...@@ -361,6 +371,19 @@ ...@@ -361,6 +371,19 @@
</div> </div>
</el-dialog> </el-dialog>
<!-- 排程 -->
<el-dialog
title="详情"
:visible.sync="arrangCodeVisible"
width="1000px"
append-to-body
>
<arrangCodeList v-if="arrangCodeVisible" ref="orderListRef" :taskWorkunitId="taskWorkunitId"></arrangCodeList>
<div slot="footer" class="dialog-footer">
<el-button @click="arrangCodeVisible = false"> </el-button>
</div>
</el-dialog>
</div> </div>
</template> </template>
...@@ -368,12 +391,15 @@ ...@@ -368,12 +391,15 @@
import {getListData, updateList, makeProduction, makeSchedule} from '@/api/mes/pro/scheduleList' import {getListData, updateList, makeProduction, makeSchedule} from '@/api/mes/pro/scheduleList'
import BrandSelect from "@/components/TmTool/index.vue"; import BrandSelect from "@/components/TmTool/index.vue";
import OrderList from './orderList.vue' import OrderList from './orderList.vue'
import arrangCodeList from './arrangCodeList.vue'
export default { export default {
components: {BrandSelect, OrderList}, components: {BrandSelect, OrderList, arrangCodeList},
dicts: ['TASK_STATUS'], dicts: ['TASK_STATUS'],
name: "scheduleList", name: "scheduleList",
data() { data() {
return { return {
taskWorkunitId: null,
arrangCodeVisible: false,
scheduleVisible: false, scheduleVisible: false,
// 遮罩层 // 遮罩层
loading: true, loading: 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