野心家
2025-01-02 6213126dce8a83f41caf973adf70fbd13fc171f0
src/main/webapp/views/taskWrk/taskWrk.html
@@ -52,7 +52,8 @@
                        <el-dropdown @command="(command)=>{handleCommand(command, scope.row)}">
                           <el-button icon="el-icon-more" size="mini" type="primary"></el-button>
                           <el-dropdown-menu slot="dropdown">
                              <el-dropdown-item command="showCommand">查看指令</el-dropdown-item>
                                <!--                              <el-dropdown-item command="showCommand">查看指令</el-dropdown-item>-->
                                <el-dropdown-item command="returnWorkingCondition">重新给堆垛机下发任务</el-dropdown-item>
                              <el-dropdown-item command="changeCommand">修改</el-dropdown-item>
                              <el-dropdown-item command="assign">派发</el-dropdown-item>
                              <el-dropdown-item command="complete">完结</el-dropdown-item>
@@ -115,7 +116,8 @@
      <script>
         var $layui = layui.config({
            base: baseUrl + "/static/wms/layui/lay/modules/"
         }).use(['layer', 'form'], function() {})
    }).use(['layer', 'form'], function () {
    })
         var app = new Vue({
            el: '#app',
@@ -205,6 +207,10 @@
               },
               handleCommand(command, row) {
                  switch (command) {
                    case "returnWorkingCondition":
                        //重新给堆垛机下发任务
                        this.returnWorkingConditionWrk(row)
                        break;
                     case "showCommand":
                        //查看指令
                        this.showCommand(row)
@@ -237,7 +243,8 @@
                     area: [top.detailWidth, top.detailHeight],
                     shadeClose: true,
                     content: 'commandManage.html?taskNo=' + row.taskNo + "&wrkNo=" + wrkNo,
                     success: function(layero, index) {}
                    success: function (layero, index) {
                    }
                  });
               },
               changeCommand(row) {
@@ -306,6 +313,36 @@
                     }
                  });
               },
            returnWorkingConditionWrk(row){
                //重新给堆垛机下发任务
                let that = this
                $.ajax({
                    url: baseUrl + "/taskWrk/returnWorkingCondition/auth",
                    headers: {
                        'token': localStorage.getItem('token')
                    },
                    data: {
                        taskNo: row.taskNo
                    },
                    method: 'POST',
                    success: function(res) {
                        if (res.code == 200) {
                            that.$message({
                                message: "取消成功",
                                type: 'success'
                            });
                            that.getTableData()
                        } else if (res.code === 403) {
                            top.location.href = baseUrl + "/";
                        } else {
                            that.$message({
                                message: res.msg,
                                type: 'error'
                            });
                        }
                    }
                });
            },
               cancelWrk(row){
                  //取消任务
                  let that = this