| | |
| | | word-break: break-all; |
| | | word-wrap: break-word; |
| | | } |
| | | .layui-form-switch { |
| | | margin-top: 0; |
| | | } |
| | | </style> |
| | | <link rel="stylesheet" href="/css/adapter.css" /> |
| | | </head> |
| | |
| | | autocomplete="off" class="layui-input"> |
| | | </div> |
| | | </div> |
| | | |
| | | |
| | | <div class="layout-tab-page"> |
| | | <div class="layui-form-item layout-input" style="margin-top: 10px;"> |
| | | <div id="" class="layui-form-item layout-input" > |
| | | <label class="layui-form-label">是否数量盘点:</label> |
| | | <div class="layui-input-block" style="position: absolute;top: 100;"> |
| | | <input type="checkbox" name="IsZhengTuo" id="IsZhengTuo" lay-skin="switch" lay-text="是|否" |
| | | lay-filter="IsZhengTuo" class="layui-input" > |
| | | </div> |
| | | </div> |
| | | <div id="boxno1" class="layui-form-item layout-input" style="margin-top: 10px;"> |
| | | <label class="layui-form-label">箱码:</label> |
| | | <div class="layui-input-block"> |
| | | <input id="boxNo" type="text" lay-verify="boxNo" placeholder="请扫描外箱条码" |
| | |
| | | <div class="layui-input-block"> |
| | | <select id="Result" lay-filter="Result" lay-search> |
| | | <!-- <option value=""></option> --> |
| | | <option value="0" selected>正常</option> |
| | | <option value="0">正常</option> |
| | | <option value="1">盘亏</option> |
| | | <option value="2">盘盈</option> |
| | | </select> |
| | |
| | | </form> |
| | | </div> |
| | | |
| | | <div id="" class="layout-tbl-paging"> |
| | | <div id="tableid" class="layout-tbl-paging"> |
| | | <table id="tableBoxList" class="tbl-box-list" border="" cellspacing="" cellpadding=""> |
| | | <tr> |
| | | <th style="width: 40%;">箱码</th> |
| | | <th style="width: 30%;">支码</th> |
| | | <th style="width: 15%;">箱内数量</th> |
| | | <th style="width: 15%;">结果</th> |
| | | <th style="width: 40%;"><p id="a">箱码</p></th> |
| | | <th style="width: 30%;"><p id="b">支码</p></th> |
| | | <th style="width: 15%;"><p id="c">箱内数量</p></th> |
| | | <th style="width: 15%;"><p id="d">结果</p></th> |
| | | </tr> |
| | | <tr id="boxCell" style="display: none;"> |
| | | <td name="boxNo"></td> |
| | |
| | | var canPickBox = true; |
| | | $("#palletNo").focus(); |
| | | |
| | | //是否数量盘点 |
| | | var isContinue = "0"; |
| | | |
| | | form.on('switch(IsZhengTuo)', function (obj) { |
| | | $("#a").html(''); |
| | | $("#b").html(''); |
| | | $("#c").html(''); |
| | | |
| | | if (obj.elem.checked) { |
| | | $('#boxno1').attr("style", "display:none") |
| | | $('#boxno3').attr("style", "display:none") |
| | | isContinue="1"; |
| | | |
| | | $("#a").html('物料编码'); |
| | | $("#b").html('托盘条码'); |
| | | $("#c").html('托盘数量'); |
| | | |
| | | } else { |
| | | $('#boxno1').attr("style", "display:block") |
| | | $('#boxno3').attr("style", "display:block") |
| | | isContinue="0"; |
| | | |
| | | $("#a").html('箱码'); |
| | | $("#b").html('支码'); |
| | | $("#c").html('箱内数量'); |
| | | |
| | | if ($("#Result").val() != "0") { |
| | | $('#boxno3').addClass("show"); |
| | | $('#boxno3').removeClass("noshow"); |
| | | }else{ |
| | | $('#boxno3').addClass("noshow"); |
| | | $('#boxno3').removeClass("show"); |
| | | } |
| | | if($("#Result").val() == "2"){ |
| | | $('#factNum').removeAttr("disabled"); |
| | | } |
| | | else{ |
| | | $('#factNum').attr("disabled","disabled"); |
| | | } |
| | | } |
| | | $('#boxNo').val(""); |
| | | $('#boxNo3').val(""); |
| | | refreshTable() |
| | | checkPalletState() |
| | | }); |
| | | |
| | | $("#menuImg").click(function (e) { |
| | | //console.log("menuImg") |
| | |
| | | $("#menuList").hide() |
| | | }) |
| | | |
| | | // //当托盘条码输入框失去焦点时,检查一下托盘状态 |
| | | //当托盘条码输入框失去焦点时,检查一下托盘状态 |
| | | // $("#palletNo").blur(function () { |
| | | // //console.log("0000000000000") |
| | | // if ($("#palletNo").val() == "") { |
| | |
| | | "CrDetail": $("#skuLotNo").val(), |
| | | "PalletNo": $("#palletNo").val(), |
| | | "BoxNo": $("#boxNo").val(), |
| | | "isContinue": isContinue, |
| | | } |
| | | console.log(param) |
| | | synData(IP + "/PdaCr/GetStockCheckLogList", param, 'post', function (res) { |
| | | console.log(res) |
| | | if (res.code == 0) { //成功 |
| | |
| | | }, function () { }); |
| | | return |
| | | } |
| | | if ($("#Result").val() == "2") { |
| | | if ($("#Result").val() == "2" && isContinue == "0") { |
| | | if ($("#boxNo").val() == "" ||$("#boxNo3").val() == "") { |
| | | layer.msg("请扫描外箱条码和支码", { |
| | | icon: 2, |
| | |
| | | "BoxNo3": $("#boxNo3").val(), |
| | | "Result": $("#Result").val(), |
| | | "Qty": parseInt($("#factNum").val()), |
| | | "isContinue": isContinue, |
| | | } |
| | | sendData(IP + "/PdaCr/CrSetCheck", param, 'post', function (res) { |
| | | |
| | |
| | | $("#boxNo3").val('') |
| | | $("#Result").val('0') |
| | | refreshTable() |
| | | GetOutInfo() |
| | | canPickBox = true |
| | | }); |
| | | |
| | |
| | | $('#boxno3').addClass("noshow"); |
| | | $('#boxno3').removeClass("show"); |
| | | } |
| | | if(data.value == "2"){ |
| | | if(data.value == "2" || isContinue == "1"){ |
| | | $('#factNum').removeAttr("disabled"); |
| | | } |
| | | else{ |
| | | else if(isContinue != "1"){ |
| | | $('#factNum').attr("disabled","disabled"); |
| | | } |
| | | $('#boxNo3').val(""); |
| | |
| | | } |
| | | |
| | | |
| | | if (data.length > 0) { //成功 |
| | | if (data.length > 0 || isContinue == "1") { //成功 |
| | | $("#boxNum").val(data.length) |
| | | var list = data |
| | | var arrTrs = new Array() |
| | |
| | | tr.appendTo("#tableBoxList"); |
| | | idx++; |
| | | tr.attr('index', idx) |
| | | tr.find("td[name='boxNo']").html(list[i].BoxNo); |
| | | tr.find("td[name='boxNo3']").html(list[i].BoxNo3); |
| | | //判断是否为数量 |
| | | if(isContinue == "1") |
| | | { |
| | | tr.find("td[name='boxNo']").html(list[i].SkuNo); |
| | | tr.find("td[name='boxNo3']").html(list[i].PalletNo); |
| | | } |
| | | else{ |
| | | tr.find("td[name='boxNo']").html(list[i].BoxNo); |
| | | tr.find("td[name='boxNo3']").html(list[i].BoxNo3); |
| | | } |
| | | tr.find("td[name='qty']").html(list[i].Qty); |
| | | |
| | | |
| | | var CheckResultStr=''; |
| | | if(list[i].CheckResult=='0'){ |
| | |
| | | CheckResultStr='盘盈'; |
| | | }else if(list[i].CheckResult=='3'){ |
| | | CheckResultStr='实物不符'; |
| | | }else if(list[i].CheckResult=='4'){ |
| | | CheckResultStr='数量盘点'; |
| | | } |
| | | tr.find("td[name='result']").html(CheckResultStr); |
| | | |