Commit d5ef3d13 authored by 沈翠玲's avatar 沈翠玲

生产排产增加取消排产按钮

parent ccaf510f
......@@ -64,6 +64,14 @@ export function getProtask(taskId) {
});
}
// 取消排产
export function unschedule(arrangeCode) {
return request({
url: "/mes/pro/protask/unschedule/" + arrangeCode,
method: "get",
});
}
// 新增生产任务
export function addProtask(data) {
return request({
......
......@@ -182,6 +182,15 @@
@click="handleVirtualReporting"
>虚拟报工</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="primary"
plain
size="mini"
:disabled='single'
@click="handleUnschedule"
>取消排产</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
......@@ -638,7 +647,7 @@ import {
getworkstationList,
gettaskWorkunitList,
getdefaultWorkCenterList} from '@/api/mes/pro/scheduleList'
import {putProtaskSplit, splitWorkstation, deleteTask, updateProTaskWorkunitApi} from '@/api/mes/pro/protask'
import {putProtaskSplit, splitWorkstation, deleteTask, unschedule, updateProTaskWorkunitApi} from '@/api/mes/pro/protask'
import BrandSelect from "@/components/TmTool/index.vue";
import shiftSelectMixin from '@/utils/shiftSelectMixin'
import OrderList from './orderList.vue'
......@@ -837,6 +846,18 @@ export default {
});
})
},
handleUnschedule(){
this.$modal
.confirm('是否取消排产')
.then( ()=> {
unschedule(this.selectedRows[0].arrangeCode).then(response => {
if(response.code === 200) {
this.$modal.msgSuccess("取消成功");
this.getList();
}
});
})
},
handleVirtualReporting() {
const params = {
taskWorkunitId: this.selectedRows[0].taskWorkunitId,
......
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