添康获取多车间订单排产;小卫彩盒SN校验标题调整;过站解绑列表添加日期区间过滤;香囊标签打印,添加暂停打印,继续打印功能
| | |
| | | <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"> |
| | | <link rel="stylesheet" href="../../../layuiadmin/layui/css/layui.css" media="all"> |
| | | <link rel="stylesheet" href="../../../layuiadmin/style/admin.css" media="all"> |
| | | <link rel="stylesheet" href="../../../layuiadmin/ext/soulTable.css" media="all"> |
| | | <script src="../../../layuiadmin/layui/layui.js"></script> |
| | | <script src="../../../layuiadmin/Scripts/json2.js"></script> |
| | | <script src="../../../layuiadmin/Scripts/jquery-1.4.1.js"></script> |
| | |
| | | <script src="../../../layuiadmin/PubCustom.js"></script> |
| | | <script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script> |
| | | <script src="../../../layuiadmin/PageTitle.js"></script> |
| | | <!--<script src="../../../../layuiadmin/modules/soulTable.js"></script>--> |
| | | </head> |
| | | <body> |
| | | <div class="layui-fluid"> |
| | |
| | | <button type="button" class="layui-btn layui-btn-sm" lay-event="set_HideColumn"><i class="layui-icon layui-icon-form"></i>å设置</button> |
| | | <button type="button" class="layui-btn layui-btn-sm" lay-event="set_SaveScheme" id="set_SaveScheme"><i class="layui-icon layui-icon-template"></i>ä¿åæ¹æ¡</button> |
| | | <button type="button" class="layui-btn layui-btn-sm" lay-event="set_ReadScheme" id="set_ReadScheme"><i class="layui-icon layui-icon-set"></i>è¯»åæ¹æ¡</button> |
| | | <a class="layui-btn layui-btn-sm" lay-event="clearFilter">æ¸
é¤æææ é¢ç鿡件</a> |
| | | </div> |
| | | </script> |
| | | </form> |
| | |
| | | base: '../../../layuiadmin/' //éæèµæºæå¨è·¯å¾ |
| | | }).extend({ |
| | | index: 'lib/index', //主å
¥å£æ¨¡å |
| | | soulTable: '../ext/soulTable' |
| | | }).use(['index', 'form', 'table', 'element', 'laypage', 'laydate','soulTable'], function () { |
| | | //#region å
¬ç¨åé |
| | | var $ = layui.$ |
| | |
| | | }); |
| | | //#endregion |
| | | |
| | | //#region æ¸
餿æç鿡件并éè½½è¡¨æ ¼ |
| | | table.on('toolbar(mainTable)', function (obj) { |
| | | if (obj.event === 'clearFilter') { |
| | | // æ¸
餿æç鿡件并éè½½è¡¨æ ¼ |
| | | // åæ°: tableId |
| | | soulTable.clearFilter('mainTable') |
| | | } |
| | | }); |
| | | //#endregion |
| | | |
| | | //#region éç½®æé® |
| | | form.on('submit(btnReSearch)', function (data) { |
| | | set_ClearQuery(); |
| | |
| | | //, cellMinWidth: 90 |
| | | , limit: 500 |
| | | , limits: [50, 500, 5000, 20000] |
| | | , done: function () { |
| | | soulTable.render(this) |
| | | } |
| | | }; |
| | | } |
| | | //#endregion |
| | |
| | | else if ($.inArray(data[i].name, totalArray) > -1) { |
| | | col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: true, totalRow: true, width: 120 }); |
| | | } else if (data[i].name == 'åæ®å·') { |
| | | col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: true, width: 200, event: 'åæ®å·', filter: true}); |
| | | col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: true, width: 200, event: 'åæ®å·' }); |
| | | } |
| | | else if (data[i].name == 'é
ä»¶æ¡ç ') { |
| | | col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: true, width: 200, event: 'é
ä»¶æ¡ç ', filter: true }); |
| | | } |
| | | else if (data[i].name == 'æ¥æ') { |
| | | col.push({ field: data[i].id, title: data[i].name, align: 'center', filter: { type: 'date[yyyy-MM-dd HH:mm:ss]' }, sort: true, width: 200 }); |
| | | col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: true, width: 200, event: 'é
ä»¶æ¡ç ' }); |
| | | } |
| | | else { |
| | | switch (data[i].Type) { |
| | |
| | | col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: true, templet: "<div>{{d." + data[i].name + " ==null ?'':layui.util.toDateString(d." + data[i].name + ", 'yyyy-MM-dd')}}</div>", width:120 }); |
| | | break; |
| | | default: |
| | | col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: true, width: 120, filter: true }); |
| | | col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: true, width: 120 }); |
| | | } |
| | | } |
| | | } |
| | |
| | | <input type="text" class="layui-input ForFilteringSchemes" name="HBarcode_ZX" id="HBarcode_ZX" onfocus="this.select();"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">å¼å§æ¥æ</label> |
| | | <div class="layui-input-block"> |
| | | <input type="date" class="layui-input ForFilteringSchemes" id="HBeginDate" style="width:110px;"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">ç»ææ¥æ</label> |
| | | <div class="layui-input-block"> |
| | | <input type="date" class="layui-input ForFilteringSchemes" id="HEndDate" style="width:110px;"> |
| | | </div> |
| | | </div> |
| | | |
| | | <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch"> |
| | | <i class="layui-icon layui-icon-search layuiadmin-button-btn"></i> |
| | |
| | | |
| | | //#region åå§åçé¢ |
| | | function set_ClearBill() { |
| | | $("#HBeginDate").val(Format(new Date(new Date() - (1000 * 60 * 60 * 24 * 7)), "yyyy-MM-dd")); |
| | | $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd")); |
| | | //åå§åè¡¨æ ¼ |
| | | set_InitGrid(); |
| | | //æ¥è¯¢ |
| | |
| | | var HBarcode_SN = $("#HBarcode_SN").val(); //SNå· |
| | | var HBarcode_ZB = $("#HBarcode_ZB").val(); //æ æ¿ç |
| | | var HBarcode_ZX = $("#HBarcode_ZX").val(); //ä¸ç®±ç |
| | | var HDate = $("#HBeginDate").val();//å¼å§æ¥æ |
| | | var HDate1 = $("#HEndDate").val();//ç»ææ¥æ |
| | | |
| | | //ä»»æåæ®µè¿æ»¤ |
| | | var ColName = $("#ColName").val();//å¤éæ¡ |
| | |
| | | } |
| | | if (HBarcode_ZB) { |
| | | sWhere += "and æ æ¿ç like '%" + HBarcode_ZB + "%'"; |
| | | |
| | | } |
| | | if (HBarcode_ZX) { |
| | | sWhere += "and ä¸ç®±ç like '%" + HBarcode_ZX + "%'"; |
| | | |
| | | } |
| | | if (HDate) { |
| | | sWhere += " and CONVERT(varchar(100),çäº§æ¥æ, 23) >= '" + HDate + "'"; |
| | | } |
| | | if (HDate1) { |
| | | sWhere += " and CONVERT(varchar(100),çäº§æ¥æ, 23) <= '" + HDate1 + "'"; |
| | | } |
| | | |
| | | get_Display(sWhere); |
| | |
| | | $("#HBarcode_SN").val(""); |
| | | $("#HBarcode_ZB").val(""); |
| | | $("#HBarcode_ZX").val(""); |
| | | $("#HBeginDate").val(Format(new Date(new Date() - (1000 * 60 * 60 * 24 * 7)), "yyyy-MM-dd")); |
| | | $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd")); |
| | | $("#ColContent").val(""); |
| | | $("#ColName").val("0"); |
| | | $("#Comparator").val("0"); |
| | |
| | | <html> |
| | | <head> |
| | | <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
| | | <title>å·¥åºååè¿ç«å¹³å°(彩çSNæ ¡éª)</title> |
| | | <title>å·¥åºååè¿ç«å¹³å°(SNæ ¡éª)</title> |
| | | <meta name="renderer" content="webkit"> |
| | | <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> |
| | | <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"> |
| | |
| | | <div class="layui-card-body" style="padding: 1px;"> |
| | | <form class="layui-form" action="" lay-filter="formData" style="background-color:white;"> |
| | | <div style="padding: 10px;"> |
| | | <h1 style="text-align: center; padding: 10px 0;"><b>彩çSNæ ¡éªè¿ç«å¹³å°</b></h1> |
| | | <h1 style="text-align: center; padding: 10px 0;"><b>SNæ ¡éªè¿ç«å¹³å°</b></h1> |
| | | </div> |
| | | <div class="layui-tab" style="width: 100%; float: left; background-color:white;"> |
| | | <div class="layui-row"> |
| | |
| | | |
| | | <button class="layui-btn layui-btn-normal" style="float:right" type="button" lay-submit="" lay-filter="btnExit" id="btnExit">éåº</button> |
| | | <div class="layui-input-block" style="display: inline-block; margin-left: 0px; float: right"> |
| | | <label class="layui-form-label" style="padding-left:0px" id="">彩çSNç :</label> |
| | | <label class="layui-form-label" style="padding-left:0px" id="">SNç :</label> |
| | | <input type="text" class="layui-input" name="HBarCode_SN2" lay-verify="HBarCode_SN2" autocomplete="off" placeholder="请é®å
¥åå车" id="HBarCode_SN2" style="width: 500px;"> |
| | | </div> |
| | | |
| | |
| | | <div class="layui-input-block"> |
| | | <!--<button type="button" class="layui-btn" id="ToolPrint" lay-submit="" lay-filter="ToolPrint">é¢è§æå°</button>--> |
| | | <button type="button" class="layui-btn" id="ToolCreate" lay-submit="" lay-filter="ToolCreate">çæ</button> |
| | | <button type="button" class="layui-btn" id="PausePrint" lay-submit="" lay-filter="PausePrint">æåæå°</button> |
| | | <button type="button" class="layui-btn" id="ContinuePrint" lay-submit="" lay-filter="ContinuePrint">ç»§ç»æå°</button> |
| | | <button type="button" class="layui-btn" id="ToolExit" lay-submit="" lay-filter="ToolExit">éåº</button> |
| | | </div> |
| | | </div> |
| | |
| | | <div class="layui-tab-content"> |
| | | <div class="layui-tab-item layui-show"> |
| | | <div class="layui-form-item"> |
| | | |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">ç产订å</label> |
| | | <div class="layui-input-inline"> |
| | |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">æå°é´é(ç§)</label> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" name="HTime" id="HTime" autocomplete="off" value="3"> |
| | | |
| | | <input class="layui-input" name="HTime" id="HTime" autocomplete="off" value="3" onfocus="this.select();"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">æ¡ç ç¼å·</label> |
| | | <div class="layui-input-inline" style="width:600px;"> |
| | | <input class="layui-input" name="HBarCode" id="HBarCode" autocomplete="off" style="float:left;width:410px;" onfocus="this.select();" placeholder="请è¾å
¥åä¸ªè¡¥ææ¡ç ç¼å·ï¼ä¸æ¯ææ¹éè¡¥æ"> |
| | | <button type="button" class="layui-btn" id="PrintBarCode" lay-submit="" lay-filter="PrintBarCode" style="float:left;">è¡¥ææ¡ç </button> |
| | | </div> |
| | | </div> |
| | | </div> |
| | |
| | | var sWhere = ""; |
| | | var HModName = "Cj_SachetBarCodePrint"; |
| | | var titleData = [];//ä¸éè¦æ¾ç¤ºçåæ®µ 坿©å± |
| | | var HWhetherToPrint = true; //æ¯å¦æå° |
| | | |
| | | //#endregion |
| | | |
| | |
| | | $('#ToolCreate').addClass("layui-btn-disabled").attr("disabled", true);//çææé®ç¦ç¨ |
| | | SaveBarCodeCreate(); |
| | | }) |
| | | |
| | | //æåæå° |
| | | form.on('submit(PausePrint)', function (data) { |
| | | layer.confirm("æ¯å¦ç¡®è®¤æåæå°?", { |
| | | btn: ["ç¡®å®", "åæ¶"] |
| | | , btn1: function (index) { |
| | | layer.close(index); |
| | | HWhetherToPrint = false; |
| | | } |
| | | }) |
| | | }) |
| | | |
| | | //ç»§ç»æå° |
| | | form.on('submit(ContinuePrint)', function (data) { |
| | | if (Number($("#HTime").val()) < Number(3)) { |
| | | layer.msg("æå°é´éä¸å
许å°äº3ç§ï¼") |
| | | return; |
| | | } |
| | | |
| | | layer.confirm("æ¯å¦ç»§ç»æå°?", { |
| | | btn: ["ç¡®å®", "åæ¶"] |
| | | , btn1: function (index) { |
| | | layer.close(index); |
| | | HWhetherToPrint = true; |
| | | |
| | | var HICMOInterID = $("#HICMOInterID").val(); |
| | | var HICMOEntryID = $("#HICMOEntryID").val(); |
| | | //è°ç¨æå°æ¹æ³ |
| | | get_BatchPrint(HICMOInterID, HICMOEntryID); |
| | | } |
| | | }) |
| | | }) |
| | | |
| | | //è¡¥ææ¡ç |
| | | form.on('submit(PrintBarCode)', function (data) { |
| | | PrintBarCode(); |
| | | }) |
| | | |
| | | //æ¡ç ç¼å·åè½¦æ¹æ³ |
| | | $('#HBarCode').on('keydown', function (event) { |
| | | if (event.keyCode == 13) { |
| | | PrintBarCode(); |
| | | } |
| | | }); |
| | | |
| | | //éåº |
| | | form.on('submit(ToolExit)', function (data) { |
| | |
| | | //}; |
| | | webapp_ws_ajax_run(args); |
| | | |
| | | if (rest.length <= num + 1) { |
| | | if (rest.length <= num + 1 || HWhetherToPrint == false) { |
| | | num = 0; |
| | | clearInterval(time); |
| | | } else { |
| | |
| | | |
| | | } |
| | | |
| | | //è¡¥ææ¡ç |
| | | function PrintBarCode() { |
| | | var HBarCode = $("#HBarCode").val(); |
| | | |
| | | var sWhere = "select top 1 a.HItemID,HBarCode æ¡ç ç¼å·,isnull(ms.HCusRelationNumber,'') SKU from Gy_BarCodeBill a with(nolock) left join Gy_Material m with(nolock) on a.HMaterID = m.HItemID left join Gy_MateNumRelation_Sec ms with(nolock) on m.HMASTERID = ms.HMaterID where a.HBarCode = '" + HBarCode + "'"; |
| | | |
| | | $.ajax({ |
| | | type: "GET", |
| | | url: GetWEBURL() + "/Gy_SOPBillList/WindowPrintList", //æ¹æ³æå¨é¡µé¢åæ¹æ³å |
| | | async: false, |
| | | data: { "sWhere": sWhere }, |
| | | success: function (data) { |
| | | if (data.count == 1) { // 说æéªè¯æåäºï¼ |
| | | |
| | | if (data.data.length != 0) { |
| | | if (data.data[0].SKU == "") { |
| | | layer.msg("ç©æSKUæªç»´æ¤ï¼è¯·è系管çå确认ï¼"); |
| | | return; |
| | | } |
| | | |
| | | var dataPrint = []; |
| | | for (var i = 0; i < data.data.length; i++) { |
| | | dataPrint.push(data.data[i]) |
| | | } |
| | | |
| | | var Customer = { |
| | | "Table": dataPrint |
| | | } |
| | | |
| | | var args = { |
| | | type: "print",//æå°æ¨¡å¼ |
| | | //type: "preview",//é¢è§æ¨¡å¼ |
| | | showOptionDlg: false, //妿䏿¾ç¤ºæå°å¯¹è¯æ¡èç´æ¥æå°ï¼å°æ¤è¡æ³¨é廿å³å¯ |
| | | report: urlAddRandomNo("../../grf/é¦åæ ç¾JSON3.grf"), |
| | | data: Customer |
| | | }; |
| | | |
| | | console.log("æå°é¦åæ¡ç ï¼" + data.data[0].æ¡ç ç¼å·); |
| | | //var args = { |
| | | // report: urlAddRandomNo("../../grf/cs10.grf"), |
| | | // data: Customer |
| | | //}; |
| | | webapp_ws_ajax_run(args); |
| | | |
| | | var sql = "update a set HPrintQty = HPrintQty + 1 from Gy_BarCodeBill a with(nolock) where HItemID = " + data.data[0].HItemID; |
| | | $.ajax({ |
| | | type: "GET", |
| | | url: GetWEBURL() + "/Gy_SOPBillList/UpDelSQL", //æ¹æ³æå¨é¡µé¢åæ¹æ³å |
| | | async: false, |
| | | data: { "sWhere": sql }, |
| | | success: function (result) { |
| | | //if (result.data.code != 1) { |
| | | // layer.alert("æ´æ°æå°æ¥æå¼å¸¸ï¼" + result.data.Message); |
| | | //} |
| | | } |
| | | }) |
| | | |
| | | } else { |
| | | layer.msg("æ¥æ æ°æ®!"); |
| | | } |
| | | } |
| | | else { |
| | | layer.msg(data.Message, { icon: 5 }); |
| | | } |
| | | layer.closeAll("loading"); |
| | | }, |
| | | error: function (err) { |
| | | layer.msg("é误:" + err, { icon: 5 }); |
| | | } |
| | | }) |
| | | |
| | | } |
| | | |
| | | /** |
| | | * é¦åä¿¡æ¯è¿ç« |
| | | * @param HBarCode |