| | |
| | | <input type="text" class="layui-input" name="HNumber" id="HNumber"> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="layui-inline"> |
| | | <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch"> |
| | | <i class="layui-icon layui-icon-search layuiadmin-button-btn"></i> |
| | | </button> |
| | | </div> |
| | | <div class="layui-colla-content" style="padding-left:82px"> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">物料编码</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HMaterNumber" id="HMaterNumber"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">旧物料编码</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HOldMaterNumber" id="HOldMaterNumber"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">物料名称</label> |
| | | <div class="layui-input-block"> |
| | |
| | | <script src="../../../../Scripts/webConfig.js"></script> |
| | | <script> |
| | | var _cur_page = 1; |
| | | var sql = " and 1=1"; |
| | | var sql = ""; |
| | | var options = document.getElementById('HStatus').children; |
| | | function getUrlVars() { |
| | | var vars = [], hash; |
| | |
| | | } |
| | | function set_InitGrid() { |
| | | var columns = [ |
| | | { checkbox: true/*, fixed: true*/ } |
| | | { checkbox: true, fixed: 'left', totalRowText: '合计'/*, fixed: true*/ } |
| | | , { field: 'sorderid', title: '序号', width: 80/*, fixed: true*/ } |
| | | , { field: 'hmainid', title: 'hmainid', sort: true/*, fixed: true*/, hide: true } |
| | | , { field: 'hsubid', title: 'hsubid', sort: true/*, fixed: true*/, hide: true } |
| | |
| | | , { field: '源单单号', title: '源单单号', width: 135 } |
| | | , { field: '包装标识', title: '包装标识', width: 135 } |
| | | //, { field: '物流单号', title: '物流单号', width: 150, sort: true/*, fixed: true*/ } |
| | | //, { field: '物料编码', title: '物料编码', width: 120, sort: true } |
| | | , { field: '物料编码', title: '物料编码', width: 120, sort: true } |
| | | , { field: '旧物料编码', title: '旧物料编码', width: 120, sort: true } |
| | | , { field: '物料代码', title: '物料代码', width: 120, sort: true } |
| | | , { field: '物料名称', title: '物料名称', width: 120, sort: true } |
| | | , { field: '规格型号', title: '规格型号', width: 120, sort: true } |
| | | , { field: '计量单位', title: '计量单位', width: 80, sort: true } |
| | | , { field: '数量', title: '订货数量', width: 100, sort: true } |
| | | , { field: '未生成条码数量', title: '未生成条码数量', width: 100, sort: true } |
| | | , { field: '合格数量', title: '合格数量', width: 100, sort: true } |
| | | , { field: '不合格数量', title: '不合格数量', width: 100, sort: true } |
| | | , { field: '数量', title: '订货数量', width: 100, sort: true, totalRow: true } |
| | | , { field: '未生成条码数量', title: '未生成条码数量', width: 100, sort: true, totalRow: true } |
| | | , { field: '合格数量', title: '合格数量', width: 100, sort: true, totalRow: true } |
| | | , { field: '不合格数量', title: '不合格数量', width: 100, sort: true, totalRow: true } |
| | | , { field: '含税单价', title: '含税单价', width: 100, sort: true, hide: true } |
| | | , { field: '金额', title: '金额', width: 100, sort: true, hide: true } |
| | | , { field: '日期', title: '日期', width: 150, sort: true } |
| | |
| | | |
| | | dataCol = data1.data[0].HGridString.split(','); |
| | | |
| | | for (var i = 0; i < option.cols[0].length - 2; i++) { |
| | | for (var i = 0; i < dataCol.length; i++) { |
| | | var dataCols = dataCol[i].split('|'); |
| | | //隐藏列 |
| | | if (dataCols[1] == 1) { |
| | |
| | | function get_Display(sqlWhere) { |
| | | var wait = layer.load();//遮罩 |
| | | $.ajax({ |
| | | type: "get", |
| | | type: "POST", |
| | | url: GetWEBURL() + "GetPOInStockBill", |
| | | async: false, |
| | | data: { "HSupNo": sessionStorage["HUserName"], "sqlWhere": sqlWhere }, |
| | |
| | | }); |
| | | //查询条件 |
| | | function get_FastQuery(table, option) { |
| | | var sqlWhere = " and 1=1 "; |
| | | var sqlWhere = ""; |
| | | if ($("#HStatus").val() != "") |
| | | if ($("#HStatus").val() == "未生成条码") { |
| | | sqlWhere += " and 未生成条码数量 > 0"; |
| | |
| | | sqlWhere += " and 源单单号 like ^^%" + $("#HBillNoFrom").val() + "%^^"; |
| | | if ($("#HInnerBillNo").val() != "") |
| | | sqlWhere += " and 送货单号 like ^^%" + $("#HInnerBillNo").val() + "%^^"; |
| | | //if ($("#HShortNumber").val() != "") |
| | | // sqlWhere += " and 物料编码 like ^^%" + $("#HShortNumber").val() + "%^^"; |
| | | if ($("#HOldMaterNumber").val() != "") |
| | | sqlWhere += " and 旧物料编码 like ^^%" + $("#HOldMaterNumber").val() + "%^^"; |
| | | if ($("#HMaterNumber").val() != "") |
| | | sqlWhere += " and 物料编码 like ^^%" + $("#HMaterNumber").val() + "%^^"; |
| | | if ($("#HNumber").val() != "") |
| | | sqlWhere += " and 物料代码 like ^^%" + $("#HNumber").val() + "%^^"; |
| | | if ($("#HName").val() != "") |
| | |
| | | InterID += data[i].hmainid.toString() + ","; |
| | | } |
| | | InterID = InterID.substring(0, InterID.length - 1); |
| | | |
| | | var HBillNo = data[0].单据号; |
| | | //逻辑审核方法 |
| | | $.ajax({ |
| | | type: "GET", |
| | | url: GetWEBURL() + "/AuditPOInStockBill", |
| | | data: { "HInterID": InterID, "CurUserName": sessionStorage["HUserName"], "HBillNo": "" }, |
| | | data: { "HInterID": InterID, "CurUserName": sessionStorage["HUserName"], "HBillNo": HBillNo }, |
| | | success: function (result) { |
| | | if (result.count == 1) { |
| | | layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () { |
| | |
| | | //关闭当前frame |
| | | layer.close(index); |
| | | //修改为功后刷新界面 |
| | | get_Display(sqlWhere); |
| | | get_Display(sql); |
| | | }); |
| | | |
| | | } else { |
| | |
| | | //自定义头工具栏右侧图标 - 提示 |
| | | case 'btn-reload': |
| | | _cur_page = $(".layui-laypage-em").next().html(); |
| | | RoadHBillNo(sql); |
| | | get_Display(sql); |
| | | // }); |
| | | break; |
| | | case 'btn-HideColumn': |
| | |
| | | layer.msg("请选择数据", { icon: 5 }); |
| | | return; |
| | | } |
| | | for (var i = 0; i < data.length; i++) { |
| | | if (data[i].单据状态 != "审核") { |
| | | layer.msg("选中行未审核", { icon: 5 }); |
| | | return; |
| | | } |
| | | } |
| | | //for (var i = 0; i < data.length; i++) { |
| | | // if (data[i].单据状态 != "审核") { |
| | | // layer.msg("选中行未审核", { icon: 5 }); |
| | | // return; |
| | | // } |
| | | //} |
| | | layer.open({ |
| | | type: 2 |
| | | , area: ['50%', '50%'] |