自动化立体仓库 - WMS系统
#
luxiaotao1123
2020-06-13 944c35175669e8af1c4dc47ce7921e0134978c6d
src/main/webapp/static/js/pakStore/emptyOut.js
@@ -6,6 +6,29 @@
    var layDate = layui.laydate;
    var form = layui.form;
    // 获取出库口
    function getOutBound(){
        $.ajax({
            url: baseUrl+"/available/take/site",
            headers: {'token': localStorage.getItem('token')},
            method: 'POST',
            asymc: false,
            success: function (res) {
                if (res.code === 200){
                    var tpl = $("#takeSiteSelectTemplate").html();
                    var template = Handlebars.compile(tpl);
                    var html = template(res);
                    $('#staNoSelect').append(html);
                    form.render('select');
                } else if (res.code === 403){
                    top.location.href = baseUrl+"/";
                }else {
                    layer.msg(res.msg)
                }
            }
        })
    }
    // 数据渲染
    tableIns = table.render({
        elem: '#locMast',
@@ -56,6 +79,7 @@
                top.location.href = baseUrl+"/";
            }
            pageCurr=curr;
            getOutBound();
            limit();
            form.on('checkbox(tableCheckbox)', function (data) {
                var _index = $(data.elem).attr('table-index')||0;
@@ -73,16 +97,10 @@
        var checkStatus = table.checkStatus(obj.config.id);
        switch (obj.event) {
            case 'outbound':
                layer.open({
                    type: 1,
                    title: '出库',
                    maxmin: true,
                    area: [top.detailWidth, top.detailHeight],
                    shadeClose: true,
                    content: $("#outboundDiv"),
                    success: function (layero, index) {
                    }
                });
                var staNo = $("#staNoSelect").val();
                if (staNo === ""){
                    layer.msg("请选择出库口");
                }
                break;
        }
    });
@@ -92,6 +110,7 @@
        pageCurr = 1;
        $('#detlTable').css("display", 'none');
        tableReload(false);
        getOutBound();
    });
    // 搜索栏重置事件
@@ -100,6 +119,7 @@
        clearFormVal($('#search-box'));
        $('#detlTable').css("display", 'none');
        tableReload(false);
        getOutBound();
    });
})
@@ -132,5 +152,3 @@
        }
    });
}