自动化立体仓库 - WMS系统
#
luxiaotao1123
2020-06-06 d23f39f6e3f743f7b46097a9315a6e28398218e5
src/main/webapp/static/js/wrkMast/wrkMast.js
@@ -11,7 +11,7 @@
    tableIns = table.render({
        elem: '#wrkMast',
        headers: {token: localStorage.getItem('token')},
        url: '/wrkMast/list/auth',
        url: baseUrl+'/wrkMast/list/auth',
        page: true,
        limit: 10,
        even: true,
@@ -63,7 +63,7 @@
            //         return html;
            //     }}
            ,{fixed: 'right', title:'操作', align: 'center', toolbar: '#operate', width:130}
            ,{fixed: 'right', title:'操作', align: 'center', toolbar: '#operate', width:150}
        ]],
        request: {
            pageName: 'curr',
@@ -82,7 +82,7 @@
        },
        done: function(res, curr, count) {
            if (res.code === 403) {
                top.location.href = "/";
                top.location.href = baseUrl;
            }
            pageCurr=curr;
            limit();
@@ -112,7 +112,7 @@
            },
            done: function (res, curr, count) {
                if (res.code === 403) {
                    top.location.href = "/";
                    top.location.href = baseUrl;
                }
                pageCurr=curr;
                limit();
@@ -139,7 +139,7 @@
                } else {
                    layer.confirm('确定增加'+(list.length===1?'此':list.length)+'条数据的优先级吗', function(){
                        $.ajax({
                            url: "/wrkMast/add/pri/auth",
                            url: baseUrl+"/wrkMast/add/pri/auth",
                            headers: {'token': localStorage.getItem('token')},
                            contentType:'application/json;charset=UTF-8',
                            data: JSON.stringify(list),
@@ -149,8 +149,9 @@
                                layer.closeAll();
                                if (res.code === 200){
                                    $(".layui-laypage-btn")[0].click();
                                    layer.msg(res.msg);
                                } else if (res.code === 403){
                                    top.location.href = "/";
                                    top.location.href = baseUrl;
                                } else {
                                    layer.msg(res.msg)
                                }
@@ -174,7 +175,7 @@
                } else {
                    layer.confirm('确定降低'+(list.length===1?'此':list.length)+'条数据的优先级吗', function(){
                        $.ajax({
                            url: "/wrkMast/red/pri/auth",
                            url: baseUrl+"/wrkMast/red/pri/auth",
                            headers: {'token': localStorage.getItem('token')},
                            contentType:'application/json;charset=UTF-8',
                            data: JSON.stringify(list),
@@ -184,8 +185,9 @@
                                layer.closeAll();
                                if (res.code === 200){
                                    $(".layui-laypage-btn")[0].click();
                                    layer.msg(res.msg);
                                } else if (res.code === 403){
                                    top.location.href = "/";
                                    top.location.href = baseUrl;
                                } else {
                                    layer.msg(res.msg)
                                }
@@ -216,7 +218,7 @@
                } else {
                    layer.confirm('确定删除'+(data.length===1?'此':data.length)+'条数据吗', function(){
                        $.ajax({
                            url: "/wrkMast/delete/auth",
                            url: baseUrl+"/wrkMast/delete/auth",
                            headers: {'token': localStorage.getItem('token')},
                            data: {param: JSON.stringify(data)},
                            method: 'POST',
@@ -226,7 +228,7 @@
                                    layer.closeAll();
                                    tableReload(false);
                                } else if (res.code === 403){
                                    top.location.href = "/";
                                    top.location.href = baseUrl;
                                } else {
                                    layer.msg(res.msg)
                                }
@@ -254,7 +256,7 @@
                        'fields': fields
                    };
                    $.ajax({
                        url: "/wrkMast/export/auth",
                        url: baseUrl+"/wrkMast/export/auth",
                        headers: {'token': localStorage.getItem('token')},
                        data: JSON.stringify(param),
                        dataType:'json',
@@ -265,7 +267,7 @@
                            if (res.code === 200) {
                                table.exportFile(titles,res.data,'xls');
                            } else if (res.code === 403) {
                                top.location.href = "/";
                                top.location.href = baseUrl;
                            } else {
                                layer.msg(res.msg)
                            }
@@ -353,7 +355,7 @@
                       content: '../locMast/locMast_detail.html',
                       success: function(layero, index){
                           $.ajax({
                               url: "/locMast/"+ param +"/auth",
                               url: baseUrl+"/locMast/"+ param +"/auth",
                               headers: {'token': localStorage.getItem('token')},
                               method: 'GET',
                               success: function (res) {
@@ -389,7 +391,7 @@
                       content: '../basDevp/basDevp_detail.html',
                       success: function(layero, index){
                           $.ajax({
                               url: "/basDevp/"+ param +"/auth",
                               url: baseUrl+"/basDevp/"+ param +"/auth",
                               headers: {'token': localStorage.getItem('token')},
                               method: 'GET',
                               success: function (res) {
@@ -425,7 +427,7 @@
                       content: '../basDevp/basDevp_detail.html',
                       success: function(layero, index){
                           $.ajax({
                               url: "/basDevp/"+ param +"/auth",
                               url: baseUrl+"/basDevp/"+ param +"/auth",
                               headers: {'token': localStorage.getItem('token')},
                               method: 'GET',
                               success: function (res) {
@@ -461,7 +463,7 @@
                       content: '../locMast/locMast_detail.html',
                       success: function(layero, index){
                           $.ajax({
                               url: "/locMast/"+ param +"/auth",
                               url: baseUrl+"/locMast/"+ param +"/auth",
                               headers: {'token': localStorage.getItem('token')},
                               method: 'GET',
                               success: function (res) {
@@ -563,7 +565,7 @@
        };
        $.ajax({
            url: "/wrkMast/"+name+"/auth",
            url: baseUrl+"/wrkMast/"+name+"/auth",
            headers: {'token': localStorage.getItem('token')},
            data: top.reObject(data),
            method: 'POST',
@@ -575,7 +577,7 @@
                        $(this).val("");
                    });
                } else if (res.code === 403){
                    top.location.href = "/";
                    top.location.href = baseUrl;
                }else {
                    layer.msg(res.msg)
                }
@@ -668,7 +670,7 @@
        tableIns1 = table.render({
            elem: '#wrkDetlByMap',
            headers: {token: localStorage.getItem('token')},
            url: '/wrkDetl/list/auth',
            url: baseUrl+'/wrkDetl/list/auth',
            where: {wrk_no: param},
            page: true,
            limit: 16,
@@ -711,7 +713,7 @@
            },
            done: function(res, curr, count) {
                if (res.code === 403) {
                    top.location.href = "/";
                    top.location.href = baseUrl;
                }
                pageCur=curr;
                form.on('checkbox(tableCheckbox)', function (data) {
@@ -745,7 +747,7 @@
        },
        done: function (res, curr, count) {
            if (res.code === 403) {
                top.location.href = "/";
                top.location.href = baseUrl;
            }
            pageCurr=curr;
            if (res.data.length === 0 && count !== 0) {