From aa7a8daa767787cdd5849dc134ce11be86515a97 Mon Sep 17 00:00:00 2001 From: hwh <332078369@qq.com> Date: 星期三, 17 七月 2024 17:00:11 +0800 Subject: [PATCH] 视觉盘点 --- HTML/views/HouseWithinSetting/StockCheck.html | 1396 ++++++++++++++++++++++++++++++---------------------------- 1 files changed, 723 insertions(+), 673 deletions(-) diff --git a/HTML/views/HouseWithinSetting/StockCheck.html b/HTML/views/HouseWithinSetting/StockCheck.html index b1219ad..7adf894 100644 --- a/HTML/views/HouseWithinSetting/StockCheck.html +++ b/HTML/views/HouseWithinSetting/StockCheck.html @@ -1,157 +1,163 @@ <!DOCTYPE html> <html> - <head> - <meta charset="utf-8"> - <title>鐩樼偣鍗曟嵁鍒楄〃</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.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0"> - <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="../../css/public.css" media="all"> - <style> - .layui-table-tool-panel{ - top: auto; - bottom: 29px; - } - .layui-table-tool{ - padding-left: 5px; - } - /* 琛ㄦ牸涓嬫媺灏忕澶撮殣钘� */ - .layui-table-grid-down { - display: none; - } - </style> - <script> - // 杩欓噷鏄渶瑕佸湪椤甸潰娓叉煋涔嬪墠鎵ц鐨勪唬鐮� - document.addEventListener("DOMContentLoaded", function() { - - //鑾峰彇table榛樿鏄剧ず鏁� - pageCntFirst(); - //鍒ゆ柇鏄惁寮�鍚痶able鍒楄〃鍒楀璋冩暣鍔熻兘銆� - GetIsSetColW(); - }); - </script> - </head> - <body id="body"> - <div class="layui-fluid" style="padding-bottom: 0;"> - <div class="layui-card"> - <div class="layui-form layui-card-header layuiadmin-card-header-auto" id="top"> - <div class="layui-form-item"> - <div class="layui-inline"> - <label class="layui-form-label" style="width: 60px;">鐩樼偣鍗曞彿</label> - <div class="layui-input-inline"> - <input type="text" id="CRNo" name="CRNo" placeholder="鐩樼偣鍗曞彿" autocomplete="off" - class="layui-input"> - </div> - </div> - <div class="layui-inline"> - <label class="layui-form-label" style="width: 60px;">鎵ц鐘舵��</label> - <div class="layui-input-inline"> - <select name="Status" id="Status" lay-filter="Status" lay-search> - <option value=""></option> - <option value="0">绛夊緟鎵ц</option> - <option value="1">姝e湪鎵ц</option> - <option value="2">鐩樼偣瀹屾垚</option> - <option value="3">鐢熸垚璋冩暣</option> - </select> - </div> - </div> - <div class="layui-inline"> - <label class="layui-form-label" style="width: 60px;">鎵樼洏鏉$爜</label> - <div class="layui-input-inline"> - <input type="text" id="PalletNo" name="PalletNo" placeholder="鎵樼洏鏉$爜" autocomplete="off" - class="layui-input"> - </div> - </div> - <div class="layui-inline"> - <label class="layui-form-label" style="width: 60px;">鐗╁搧缂栫爜</label> - <div class="layui-input-inline"> - <input type="text" id="SkuNo" name="SkuNo" placeholder="鐗╁搧缂栫爜" - autocomplete="off" class="layui-input"> - </div> - </div> - <div class="layui-inline"> - <label class="layui-form-label" style="width: 60px;">鐗╁搧鍚嶇О</label> - <div class="layui-input-inline"> - <input type="text" id="SkuName" name="SkuName" placeholder="鐗╁搧鍚嶇О" autocomplete="off" - class="layui-input"> - </div> - </div> - <div class="layui-inline"> - <label class="layui-form-label" style="width: 60px;">鎵规</label> - <div class="layui-input-inline"> - <input type="text" id="LotNo" name="LotNo" placeholder="鎵规" autocomplete="off" - class="layui-input"> - </div> - </div> - <div class="layui-inline"> - <label class="layui-form-label" style="width: 60px;">寮�濮嬫棩鏈�</label> - <div class="layui-input-inline"> - <input type="text" autocomplete="off" name="StartTime" id="StartTime" class="layui-input" - placeholder="寮�濮嬫棩鏈�"> - </div> - </div> - <div class="layui-inline"> - <label class="layui-form-label" style="width: 60px;">缁撴潫鏃ユ湡</label> - <div class="layui-input-inline"> - <input type="text" autocomplete="off" name="EndTime" id="EndTime" class="layui-input" - placeholder="缁撴潫鏃ユ湡"> - </div> - </div> - <div class="layui-inline" id="divPickingArea" style="display: none; padding-top: 10px;"> - <label class="layui-form-label">鍑哄簱鍙�</label> - <div class="layui-input-inline"> - <select name="PickingArea" id="PickingArea" lay-search> - <option value=""></option> - <option value="1">1</option> - <option value="2">2</option> - <option value="3">3</option> - <option value="4">4</option> - </select> - </div> - </div> - <div class="layui-inline"> - <button class="layui-btn layui-btn-sm layuiadmin-btn-list" lay-submit - lay-filter="LAY-app-contlist-search"> - <i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>鎼滅储 - </button> - </div> - <!-- 缁存姢澶囨敞寮规 --> - <div class="layui-inline" id="divEditDemo" style="display: none; padding-top: 10px;"> - <label class="layui-form-label">澶囨敞</label> - <div class="layui-input-inline" style="width: 300px;height: 100%;"> - <textarea placeholder="璇疯緭鍏ュ唴瀹�" id="NoticeDemo" name="NoticeDemo" class="layui-textarea"></textarea> - </div> +<head> + <meta charset="utf-8"> + <title>鐩樼偣鍗曟嵁鍒楄〃</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.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0"> + <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="../../css/public.css" media="all"> + <style> + .layui-table-tool-panel { + top: auto; + bottom: 29px; + } + + .layui-table-tool { + padding-left: 5px; + } + + /* 琛ㄦ牸涓嬫媺灏忕澶撮殣钘� */ + .layui-table-grid-down { + display: none; + } + </style> + <script> + // 杩欓噷鏄渶瑕佸湪椤甸潰娓叉煋涔嬪墠鎵ц鐨勪唬鐮� + document.addEventListener("DOMContentLoaded", function () { + + //鑾峰彇table榛樿鏄剧ず鏁� + pageCntFirst(); + //鍒ゆ柇鏄惁寮�鍚痶able鍒楄〃鍒楀璋冩暣鍔熻兘銆� + GetIsSetColW(); + }); + </script> +</head> + +<body id="body"> + <div class="layui-fluid" style="padding-bottom: 0;"> + <div class="layui-card"> + <div class="layui-form layui-card-header layuiadmin-card-header-auto" id="top"> + <div class="layui-form-item"> + <div class="layui-inline"> + <label class="layui-form-label" style="width: 60px;">鐩樼偣鍗曞彿</label> + <div class="layui-input-inline"> + <input type="text" id="CRNo" name="CRNo" placeholder="鐩樼偣鍗曞彿" autocomplete="off" + class="layui-input"> + </div> + </div> + <div class="layui-inline"> + <label class="layui-form-label" style="width: 60px;">鎵ц鐘舵��</label> + <div class="layui-input-inline"> + <select name="Status" id="Status" lay-filter="Status" lay-search> + <option value=""></option> + <option value="0">绛夊緟鎵ц</option> + <option value="1">姝e湪鎵ц</option> + <option value="2">鐩樼偣瀹屾垚</option> + <option value="3">鐢熸垚璋冩暣</option> + </select> + </div> + </div> + <div class="layui-inline"> + <label class="layui-form-label" style="width: 60px;">鎵樼洏鏉$爜</label> + <div class="layui-input-inline"> + <input type="text" id="PalletNo" name="PalletNo" placeholder="鎵樼洏鏉$爜" autocomplete="off" + class="layui-input"> + </div> + </div> + <div class="layui-inline"> + <label class="layui-form-label" style="width: 60px;">鐗╁搧缂栫爜</label> + <div class="layui-input-inline"> + <input type="text" id="SkuNo" name="SkuNo" placeholder="鐗╁搧缂栫爜" autocomplete="off" + class="layui-input"> + </div> + </div> + <div class="layui-inline"> + <label class="layui-form-label" style="width: 60px;">鐗╁搧鍚嶇О</label> + <div class="layui-input-inline"> + <input type="text" id="SkuName" name="SkuName" placeholder="鐗╁搧鍚嶇О" autocomplete="off" + class="layui-input"> + </div> + </div> + <div class="layui-inline"> + <label class="layui-form-label" style="width: 60px;">鎵规</label> + <div class="layui-input-inline"> + <input type="text" id="LotNo" name="LotNo" placeholder="鎵规" autocomplete="off" + class="layui-input"> + </div> + </div> + <div class="layui-inline"> + <label class="layui-form-label" style="width: 60px;">寮�濮嬫棩鏈�</label> + <div class="layui-input-inline"> + <input type="text" autocomplete="off" name="StartTime" id="StartTime" class="layui-input" + placeholder="寮�濮嬫棩鏈�"> + </div> + </div> + <div class="layui-inline"> + <label class="layui-form-label" style="width: 60px;">缁撴潫鏃ユ湡</label> + <div class="layui-input-inline"> + <input type="text" autocomplete="off" name="EndTime" id="EndTime" class="layui-input" + placeholder="缁撴潫鏃ユ湡"> + </div> + </div> + <div class="layui-inline" id="divPickingArea" style="display: none; padding-top: 10px;"> + <label class="layui-form-label">鍑哄簱鍙�</label> + <div class="layui-input-inline"> + <select name="PickingArea" id="PickingArea" lay-search> + <option value=""></option> + <option value="1">1</option> + <option value="2">2</option> + <option value="3">3</option> + <option value="4">4</option> + </select> + </div> + </div> + <div class="layui-inline"> + <button class="layui-btn layui-btn-sm layuiadmin-btn-list" lay-submit + lay-filter="LAY-app-contlist-search"> + <i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>鎼滅储 + </button> + </div> + + <!-- 缁存姢澶囨敞寮规 --> + <div class="layui-inline" id="divEditDemo" style="display: none; padding-top: 10px;"> + <label class="layui-form-label">澶囨敞</label> + <div class="layui-input-inline" style="width: 300px;height: 100%;"> + <textarea placeholder="璇疯緭鍏ュ唴瀹�" id="NoticeDemo" name="NoticeDemo" + class="layui-textarea"></textarea> </div> </div> </div> - <div id="center"></div> - <div class="layui-card-body"> - <div class="position-relative"> - <table id="LAY-app-content-list" lay-filter="LAY-app-content-list" ></table> - <!--#region 鑷畾涔夎〃澶� --> - <div class="headerSetIcon"> - <button class="layui-btn layui-btn-primary layui-btn-sm" data-type="customCols"> - <i class="layui-icon"></i> - </button> - </div> - <!-- #endregion --> + </div> + <div id="center"></div> + <div class="layui-card-body"> + <div class="position-relative"> + <table id="LAY-app-content-list" lay-filter="LAY-app-content-list"></table> + <!--#region 鑷畾涔夎〃澶� --> + <div class="headerSetIcon"> + <button class="layui-btn layui-btn-primary layui-btn-sm" data-type="customCols"> + <i class="layui-icon"></i> + </button> + </div> + <!-- #endregion --> + </div> + <div class="position-relative"> + <table id="LAY-app-content-list2" lay-filter="LAY-app-content-list2"></table> + <!--#region 鑷畾涔夎〃澶� --> + <div class="headerSetIcon"> + <button class="layui-btn layui-btn-primary layui-btn-sm" data-type="customCols2"> + <i class="layui-icon"></i> + </button> </div> - <div class="position-relative"> - <table id="LAY-app-content-list2" lay-filter="LAY-app-content-list2" ></table> - <!--#region 鑷畾涔夎〃澶� --> - <div class="headerSetIcon"> - <button class="layui-btn layui-btn-primary layui-btn-sm" data-type="customCols2"> - <i class="layui-icon"></i> - </button> - </div> - <!-- #endregion --> - </div> - <script type="text/html" id="table-content-list"> + <!-- #endregion --> + </div> + <script type="text/html" id="table-content-list"> {{# var html = ''; @@ -163,6 +169,9 @@ </a>`; } if(d.Status == 0 || d.Status == 1){ + html += `<a class="layui-btn layui-btn-xs checkOut" lay-event="vision"> + <i class="layui-icon layui-icon-ok"></i>瑙嗚鐩樼偣 + </a>`; html += `<a class="layui-btn layui-btn-xs checkOut" lay-event="outbound"> <i class="layui-icon layui-icon-ok"></i>鍑哄簱 </a>`; @@ -179,9 +188,9 @@ }} </script> - - <script type="text/html" id="toolbarDemo"> - + + <script type="text/html" id="toolbarDemo"> + <button class="layui-btn layuiadmin-btn-list layui-btn-sm addClass" lay-event="add"> <i class="layui-icon"></i>娣诲姞 </button> @@ -190,8 +199,8 @@ </button> </script> - <!-- 鎬诲崟鏉ユ簮 --> - <script type="text/html" id="OriginzongButton"> + <!-- 鎬诲崟鏉ユ簮 --> + <script type="text/html" id="OriginzongButton"> {{# if(d.Origin=='0'){ }} <p>鎿嶄綔浜哄垱寤�</p> {{# } else if(d.Origin=='1'){ }} @@ -199,8 +208,8 @@ {{# } }} </script> - <!-- 鎬诲崟鏄惁澶嶇洏 --> - <script type="text/html" id="IsDoubleCheckButton"> + <!-- 鎬诲崟鏄惁澶嶇洏 --> + <script type="text/html" id="IsDoubleCheckButton"> {{# if(d.AuditStatusNo=='0'){ }} <p>鍚�</p> {{# } else if(d.AuditStatusNo=='1'){ }} @@ -208,8 +217,8 @@ {{# } }} </script> - <!-- 鎬诲崟瀹℃牳鐘舵�� --> - <script type="text/html" id="AuditStatusButton"> + <!-- 鎬诲崟瀹℃牳鐘舵�� --> + <script type="text/html" id="AuditStatusButton"> {{# if(d.AuditStatusNo=='0'){ }} <p>寰呭鏍�</p> {{# } else if(d.AuditStatusNo=='9'){ }} @@ -217,8 +226,8 @@ {{# } }} </script> - <!-- 鎬诲崟鎵ц鐘舵�� --> - <script type="text/html" id="StatuszongButton"> + <!-- 鎬诲崟鎵ц鐘舵�� --> + <script type="text/html" id="StatuszongButton"> {{# var html = ``; if(d.Status=='0'){ @@ -237,43 +246,43 @@ }} </script> - <!-- 鎬诲崟寮�濮嬫椂闂� --> - <script type="text/html" id="CheckDateButton"> + <!-- 鎬诲崟寮�濮嬫椂闂� --> + <script type="text/html" id="CheckDateButton"> {{# return formatDate(d.CheckDate); }} </script> - - <!-- 鎬诲崟瀹屾垚鏃堕棿 --> - <script type="text/html" id="CompleteDateButtom"> + + <!-- 鎬诲崟瀹屾垚鏃堕棿 --> + <script type="text/html" id="CompleteDateButtom"> {{# return formatDate(d.CompleteDate); }} </script> - - <!-- 鎬诲崟瀹℃牳鏃堕棿 --> - <script type="text/html" id="AuditTimeButton"> + + <!-- 鎬诲崟瀹℃牳鏃堕棿 --> + <script type="text/html" id="AuditTimeButton"> {{# return formatDate(d.AuditTime); }} </script> - - <!-- 鍒涘缓鏃堕棿 --> - <script type="text/html" id="CreateTimeButton"> + + <!-- 鍒涘缓鏃堕棿 --> + <script type="text/html" id="CreateTimeButton"> {{# return formatDate(d.CreateTime); }} </script> - - <!-- 淇敼鏃堕棿 --> - <script type="text/html" id="UpdateTimeButton"> + + <!-- 淇敼鏃堕棿 --> + <script type="text/html" id="UpdateTimeButton"> {{# return formatDate(d.UpdateTime); }} </script> - <!-- 鏄庣粏鎵ц鐘舵�� --> - <script type="text/html" id="StatusmingButton"> + <!-- 鏄庣粏鎵ц鐘舵�� --> + <script type="text/html" id="StatusmingButton"> {{# var html = ``; if(d.Status=='0'){ @@ -294,8 +303,8 @@ }} </script> - <!-- 鏄庣粏鐩樼偣缁撴灉 --> - <script type="text/html" id="CheckResultButton"> + <!-- 鏄庣粏鐩樼偣缁撴灉 --> + <script type="text/html" id="CheckResultButton"> {{# var html = ``; if(d.CheckResult=='0'){ @@ -314,533 +323,574 @@ }} </script> - - </div> + </div> </div> - - <script src="../../layuiadmin/layui/layui.js"></script> - <script src="../../js/jquery-3.5.1.min.js"></script> - <script src="../../js/jquery.cookie.js"></script> - <script src="../../js/public.js"></script> - <script> - - layui.config({ - base: '../../layuiadmin/' //闈欐�佽祫婧愭墍鍦ㄨ矾寰� - }).extend({ - index: 'lib/index' //涓诲叆鍙fā鍧� - }).use(['index', 'table', 'laypage', 'layer', 'laydate'], function() { - var table = layui.table, - form = layui.form, - laypage = layui.laypage, - layer = layui.layer; - laydate = layui.laydate; - var $ = layui.$; - var h1 = GetTableTopHeight(); - var h2 = GetTableBottomHeight(); - - laydate.render({ - elem: '#StartTime' - , format: 'yyyy-MM-dd' //鍙换鎰忕粍鍚� - }); - laydate.render({ - elem: '#EndTime' - , format: 'yyyy-MM-dd' //鍙换鎰忕粍鍚� - }); - var isChongFu = true; - var xqid = "kong"; + </div> - //鎬诲崟 - var TotalColsArrz = - [[ - {field:'',title: '搴忓彿', type: 'numbers', width: 65, fixed: 'left', "disabled": true, }, - {field: 'CrNo', title: '鐩樼偣鍗曞彿', align: 'center', fixed: 'left', width: 165, }, - {field: 'Origin',title: '鏉ユ簮',align: 'center', templet: '#OriginzongButton', }, - {field: 'Status',title: '鎵ц鐘舵��',align: 'center', templet: '#StatuszongButton', }, - {field: 'CheckDate',title: '寮�濮嬫椂闂�',align: 'center', templet: '#CheckDateButton', }, - {field: 'CompleteDate',title: '瀹屾垚鏃堕棿',align: 'center', templet: '#CompleteDateButtom', }, - {field: 'Demo',title: '澶囨敞',align: 'center',width: 180}, - {field: 'AuditStatusNo',title: '瀹℃牳鐘舵��',align: 'center',width: 130,hide:true, templet: '#AuditStatusButton', }, - {field: 'IsDoubleCheck', title: '鏄惁澶嶇洏', align: 'center', width: 180, hide:true, templet: '#IsDoubleCheckButton', }, - {field: 'AuditUserName',title: '瀹℃牳浜�',align: 'center',width: 180,hide:true}, - {field: 'AuditTime',title: '瀹℃牳鏃堕棿',align: 'center',width: 95,hide:true , templet: '#AuditTimeButton', }, - {field: 'CreateUserName', title:'鍒涘缓浜�', align:'center', }, - {field: 'CreateTime',title: '鍒涘缓鏃堕棿',align: 'center', templet: '#CreateTimeButton', }, - {field: 'UpdateUserName',title: '淇敼浜�',align: 'center',width: 120,hide:true}, - {field: 'UpdateTime',title: '淇敼鏃堕棿',align: 'center',width: 160,hide:true, templet: '#UpdateTimeButton', }, - {field:'caozuo',title: '鎿嶄綔',fixed: 'right',align: 'center',toolbar: '#table-content-list',width: 240 } - ]]; - var TotalColsSysArrz=encodeURIComponent(encodeURIComponent(JSON.stringify(TotalColsArrz)))//灏嗚〃澶存暟鎹繘琛寀rl缂栫爜 + <script src="../../layuiadmin/layui/layui.js"></script> + <script src="../../js/jquery-3.5.1.min.js"></script> + <script src="../../js/jquery.cookie.js"></script> + <script src="../../js/public.js"></script> + <script> - //鏄庣粏 - var TotalColsArrm = - [[ - {field:'',title:'搴忓彿', type:'numbers', width:65, fixed:'left', "disabled": true, }, - {field:'CrNo', title:'鐩樼偣鍗曞彿', align:'center', fixed:'left', width: 165, }, - {field:'PalletNo', title:'鎵樼洏鍙�', align:'center', fixed:'left', width: 165, }, - {field:'Qty', title:'搴撳瓨鏁伴噺', align:'center', fixed:'left', width: 105, }, - {field:'RealQty', title:'瀹為檯鏁伴噺', align:'center', width: 105, }, - {field:'Status', title:'鎵ц鐘舵��', align:'center', width: 105, templet : '#StatusmingButton', }, - {field:'CheckResult', title:'鐩樼偣缁撴灉', align:'center', width:105, templet : '#CheckResultButton', }, - {field:'SkuNo', title:'鐗╂枡缂栫爜', align:'center', width:105, }, - {field:'SkuName', title:'鐗╂枡鍚嶇О', align:'center', width:125, }, - {field:'Standard', title:'瑙勬牸', align:'center', width:225, }, - {field:'LotNo', title:'鎵规鍙�', align:'center', width:105, }, - {field:'LotText', title:'鎵规鎻忚堪', align:'center', width:105, }, - {field:'SupplierLot', title:'渚涜揣鎵规', align:'center', width:105, }, - {field: 'CreateUserName', title:'鍒涘缓浜�', align:'center', width:100, }, - {field: 'CreateTime',title: '鍒涘缓鏃堕棿',align: 'center',width: 160, templet: '#CreateTimeButton',}, - {field: 'UpdateUserName',title: '淇敼浜�',align: 'center',width: 120,hide:true}, - {field: 'UpdateTime',title: '淇敼鏃堕棿',align: 'center',width: 160,hide:true, templet: '#UpdateTimeButton',}, - ]]; - var TotalColsSysArrm=encodeURIComponent(encodeURIComponent(JSON.stringify(TotalColsArrm)))//灏嗚〃澶存暟鎹繘琛寀rl缂栫爜 - refreshTable(); - var colsJsonz; - var colsJsonm; + layui.config({ + base: '../../layuiadmin/' //闈欐�佽祫婧愭墍鍦ㄨ矾寰� + }).extend({ + index: 'lib/index' //涓诲叆鍙fā鍧� + }).use(['index', 'table', 'laypage', 'layer', 'laydate'], function () { + var table = layui.table, + form = layui.form, + laypage = layui.laypage, + layer = layui.layer; + laydate = layui.laydate; + var $ = layui.$; + var h1 = GetTableTopHeight(); + var h2 = GetTableBottomHeight(); + + laydate.render({ + elem: '#StartTime' + , format: 'yyyy-MM-dd' //鍙换鎰忕粍鍚� + }); + laydate.render({ + elem: '#EndTime' + , format: 'yyyy-MM-dd' //鍙换鎰忕粍鍚� + }); + var isChongFu = true; + var xqid = "kong"; + + //鎬诲崟 + var TotalColsArrz = + [[ + { field: '', title: '搴忓彿', type: 'numbers', width: 65, fixed: 'left', "disabled": true, }, + { field: 'CrNo', title: '鐩樼偣鍗曞彿', align: 'center', fixed: 'left', width: 165, }, + { field: 'Origin', title: '鏉ユ簮', align: 'center', templet: '#OriginzongButton', }, + { field: 'Status', title: '鎵ц鐘舵��', align: 'center', templet: '#StatuszongButton', }, + { field: 'CheckDate', title: '寮�濮嬫椂闂�', align: 'center', templet: '#CheckDateButton', }, + { field: 'CompleteDate', title: '瀹屾垚鏃堕棿', align: 'center', templet: '#CompleteDateButtom', }, + { field: 'Demo', title: '澶囨敞', align: 'center', width: 180 }, + { field: 'AuditStatusNo', title: '瀹℃牳鐘舵��', align: 'center', width: 130, hide: true, templet: '#AuditStatusButton', }, + { field: 'IsDoubleCheck', title: '鏄惁澶嶇洏', align: 'center', width: 180, hide: true, templet: '#IsDoubleCheckButton', }, + { field: 'AuditUserName', title: '瀹℃牳浜�', align: 'center', width: 180, hide: true }, + { field: 'AuditTime', title: '瀹℃牳鏃堕棿', align: 'center', width: 95, hide: true, templet: '#AuditTimeButton', }, + { field: 'CreateUserName', title: '鍒涘缓浜�', align: 'center', }, + { field: 'CreateTime', title: '鍒涘缓鏃堕棿', align: 'center', templet: '#CreateTimeButton', }, + { field: 'UpdateUserName', title: '淇敼浜�', align: 'center', width: 120, hide: true }, + { field: 'UpdateTime', title: '淇敼鏃堕棿', align: 'center', width: 160, hide: true, templet: '#UpdateTimeButton', }, + { field: 'caozuo', title: '鎿嶄綔', fixed: 'right', align: 'center', toolbar: '#table-content-list', width: 240 } + ]]; + var TotalColsSysArrz = encodeURIComponent(encodeURIComponent(JSON.stringify(TotalColsArrz)))//灏嗚〃澶存暟鎹繘琛寀rl缂栫爜 + + //鏄庣粏 + var TotalColsArrm = + [[ + { field: '', title: '搴忓彿', type: 'numbers', width: 65, fixed: 'left', "disabled": true, }, + { field: 'CrNo', title: '鐩樼偣鍗曞彿', align: 'center', fixed: 'left', width: 165, }, + { field: 'PalletNo', title: '鎵樼洏鍙�', align: 'center', fixed: 'left', width: 165, }, + { field: 'Qty', title: '搴撳瓨鏁伴噺', align: 'center', fixed: 'left', width: 105, }, + { field: 'RealQty', title: '瀹為檯鏁伴噺', align: 'center', width: 105, }, + { field: 'Status', title: '鎵ц鐘舵��', align: 'center', width: 105, templet: '#StatusmingButton', }, + { field: 'CheckResult', title: '鐩樼偣缁撴灉', align: 'center', width: 105, templet: '#CheckResultButton', }, + { field: 'SkuNo', title: '鐗╂枡缂栫爜', align: 'center', width: 105, }, + { field: 'SkuName', title: '鐗╂枡鍚嶇О', align: 'center', width: 125, }, + { field: 'Standard', title: '瑙勬牸', align: 'center', width: 225, }, + { field: 'LotNo', title: '鎵规鍙�', align: 'center', width: 105, }, + { field: 'LotText', title: '鎵规鎻忚堪', align: 'center', width: 105, }, + { field: 'SupplierLot', title: '渚涜揣鎵规', align: 'center', width: 105, }, + { field: 'CreateUserName', title: '鍒涘缓浜�', align: 'center', width: 100, }, + { field: 'CreateTime', title: '鍒涘缓鏃堕棿', align: 'center', width: 160, templet: '#CreateTimeButton', }, + { field: 'UpdateUserName', title: '淇敼浜�', align: 'center', width: 120, hide: true }, + { field: 'UpdateTime', title: '淇敼鏃堕棿', align: 'center', width: 160, hide: true, templet: '#UpdateTimeButton', }, + ]]; + var TotalColsSysArrm = encodeURIComponent(encodeURIComponent(JSON.stringify(TotalColsArrm)))//灏嗚〃澶存暟鎹繘琛寀rl缂栫爜 + refreshTable(); + var colsJsonz; + var colsJsonm; + // refreshTablemx(xqid); + + //娓叉煋鐩樼偣鎬诲崟 + function refreshTable() { + var param1 = { + // Href:'QualityControl/QualityInformation' + Href: 'BllCheck/GetStockCheckList' + }; + sendData(IP + "/Sys/GetTableColsByUserId", param1, 'post', function (res) { + if (res.code == 0) { + if (res.data == '' || res.data == undefined || res.data == null) { + console.log(1) + colsJsonz = TotalColsArrz + } else { + console.log(2) + colsJsonz = eval(res.data); + } + } else { + colsJsonz = TotalColsArrz + } + // tableclass(LotNo,SkuNo,SkuName,IsQualified); + var param = { + CrNo: $("#CRNo").val(), + Status: $("#Status").val(), + + PalletNo: $("#PalletNo").val(), + SkuNo: $("#SkuNo").val(), + SkuName: $("#SkuName").val(), + LotNo: $("#LotNo").val(), + StartTime: $("#StartTime").val(), + EndTime: $("#EndTime").val(), + }; + table.render({ + elem: '#LAY-app-content-list', + url: IP + "/BllCheck/GetStockCheckList", + method: 'post', + height: h1,//'full-'+hei1 + id: 'LAY-app-content-list', + where: param, + contentType: 'application/json', + // toolbar: '#toolbarDemo', + defaultToolbar: [], //'filter','print', 'exports' + headers: { ToKen: $.cookie('token') }, + page: true, + even: true, + limit: pageCnt, + limits: pageLimits, + cellMinWidth: 60, //鍏ㄥ眬瀹氫箟甯歌鍗曞厓鏍肩殑鏈�灏忓搴︼紝layui 2.2.1 鏂板 + done: function (res) { + initMenu(); + var soCode = "res.data[0].SONo"; + if (res.data.length != 0) { + soCode = res.data[0].SONo; + } + refreshTablemx(soCode) + //鑷畾涔夊垪瀹� + SetTableColW('LAY-app-content-list', 'BllCheck/GetStockCheckList', TotalColsSysArrz); + }, + cols: colsJsonz + }); + + // table.render({ + // elem: '#LAY-app-content-list', + // url: IP+"/BllCheck/GetStockCheckList", + // method: 'POST', + // height: h1 ,//'full-'+hei1 + // id: 'LAY-app-content-list', + // where: param, + // contentType: 'application/json', + // headers:{ToKen:$.cookie('token')}, + // page: true, + // even: true, + // limit: pageCnt, + // limits: pageLimits, + // cellMinWidth: 60, //鍏ㄥ眬瀹氫箟甯歌鍗曞厓鏍肩殑鏈�灏忓搴︼紝layui 2.2.1 鏂板 + // done: function(res){ + // initMenu(); + // var soCode = "res.data[0].SONo"; + // if (res.data.length != 0) { + // soCode = res.data[0].SONo; + // } + // refreshTablemx(soCode) + // }, + // cols: [ + // [ + // {title: '搴忓彿', type: 'numbers', width: 65, fixed: 'left', }, + // {field: 'CrNo', title: '鐩樼偣鍗曞彿', align: 'center', fixed: 'left', width: 165, }, + // {field: 'Origin',title: '鏉ユ簮',align: 'center', templet: '#OriginzongButton', }, + // {field: 'Status',title: '鎵ц鐘舵��',align: 'center', templet: '#StatuszongButton', }, + // {field: 'CheckDate',title: '寮�濮嬫椂闂�',align: 'center', templet: '#CheckDateButton', }, + // {field: 'CompleteDate',title: '瀹屾垚鏃堕棿',align: 'center', templet: '#CompleteDateButtom', }, + // {field: 'AuditStatusNo',title: '瀹℃牳鐘舵��',align: 'center',width: 130,hide:true, templet: '#AuditStatusButton', }, + // {field: 'IsDoubleCheck', title: '鏄惁澶嶇洏', align: 'center', width: 180, hide:true, templet: '#IsDoubleCheckButton', }, + // {field: 'AuditUserName',title: '瀹℃牳浜�',align: 'center',width: 180,hide:true}, + // {field: 'AuditTime',title: '瀹℃牳鏃堕棿',align: 'center',width: 95,hide:true , templet: '#AuditTimeButton', }, + // {field: 'CreateUserName', title:'鍒涘缓浜�', align:'center', }, + // {field: 'CreateTime',title: '鍒涘缓鏃堕棿',align: 'center', templet: '#CreateTimeButton', }, + // {field: 'UpdateUserName',title: '淇敼浜�',align: 'center',width: 120,hide:true}, + // {field: 'UpdateTime',title: '淇敼鏃堕棿',align: 'center',width: 160,hide:true, templet: '#UpdateTimeButton', }, + // {title: '鎿嶄綔',fixed: 'right',align: 'center',toolbar: '#table-content-list',width: 240 } + // ]] + // }); + }); + } + //娓叉煋鍑哄簱鍗曟槑缁� + function refreshTablemx(crNo) { + var param1 = { + // Href:'QualityControl/QualityInformation' + Href: 'BllCheck/GetStockCheckDetailList' + }; + sendData(IP + "/Sys/GetTableColsByUserId", param1, 'post', function (res) { + if (res.code == 0) { + if (res.data == '' || res.data == undefined || res.data == null) { + colsJsonm = TotalColsArrm + } else { + colsJsonm = eval(res.data); + } + } else { + colsJsonm = TotalColsArrm + } + var param = { + CrNo: crNo, + }; + table.render({ + elem: '#LAY-app-content-list2', + url: IP + "/BllCheck/GetStockCheckDetailList", + method: 'post', + height: h2,//'full-'+hei1 + id: 'LAY-app-content-list2', + where: param, + contentType: 'application/json', + toolbar: '#toolbarDemo', + defaultToolbar: [], //'filter','print', 'exports' + headers: { ToKen: $.cookie('token') }, + page: true, + even: true, + limit: pageCnt, + limits: pageLimits, + cellMinWidth: 60, //鍏ㄥ眬瀹氫箟甯歌鍗曞厓鏍肩殑鏈�灏忓搴︼紝layui 2.2.1 鏂板 + done: function (res) { + initMenu(); + //鑷畾涔夊垪瀹� + SetTableColW('LAY-app-content-list2', 'BllCheck/GetStockCheckDetailList', TotalColsSysArrm); + }, + cols: colsJsonm + }); + // var param = { + // CrNo: crNo, + // }; + // table.render({ + // elem: '#LAY-app-content-list2', + // url: IP + "/BllCheck/GetStockCheckDetailList", + // method: 'POST', + // height: h2, + // id: 'LAY-app-content-list2', + // where: param, + // contentType: 'application/json', + // headers:{ToKen:$.cookie('token')}, + // toolbar:'#toolbarDemo', + // defaultToolbar: ['filter'], //'print', 'exports' + // page: true, + // limit: pageCnt, + // limits: pageLimits, + // cellMinWidth: 60, //鍏ㄥ眬瀹氫箟甯歌鍗曞厓鏍肩殑鏈�灏忓搴︼紝layui 2.2.1 鏂板 + // done: function(){ + // initMenu(); + // }, + // cols: [ + // [ + // {title:'搴忓彿', type:'numbers', width:65, fixed:'left', }, + // {field:'CrNo', title:'鐩樼偣鍗曞彿', align:'center', fixed:'left', width: 165, }, + // {field:'PalletNo', title:'鎵樼洏鍙�', align:'center', fixed:'left', width: 165, }, + // {field:'Qty', title:'搴撳瓨鏁伴噺', align:'center', fixed:'left', width: 105, }, + // {field:'RealQty', title:'瀹為檯鏁伴噺', align:'center', width: 105, }, + // {field:'Status', title:'鎵ц鐘舵��', align:'center', width: 105, templet : '#StatusmingButton', }, + // {field:'CheckResult', title:'鐩樼偣缁撴灉', align:'center', width:105, templet : '#CheckResultButton', }, + // {field:'SkuNo', title:'鐗╂枡缂栫爜', align:'center', width:105, }, + // {field:'SkuName', title:'鐗╂枡鍚嶇О', align:'center', width:125, }, + // {field:'Standard', title:'瑙勬牸', align:'center', width:225, }, + // {field:'LotNo', title:'鎵规鍙�', align:'center', width:105, }, + // {field:'LotText', title:'鎵规鎻忚堪', align:'center', width:105, }, + // {field:'SupplierLot', title:'渚涜揣鎵规', align:'center', width:105, }, + // {field: 'CreateUserName', title:'鍒涘缓浜�', align:'center', width:100, }, + // {field: 'CreateTime',title: '鍒涘缓鏃堕棿',align: 'center',width: 160, templet: '#CreateTimeButton',}, + // {field: 'UpdateUserName',title: '淇敼浜�',align: 'center',width: 120,hide:true}, + // {field: 'UpdateTime',title: '淇敼鏃堕棿',align: 'center',width: 160,hide:true, templet: '#UpdateTimeButton',}, + // ]] + // }); + }); + } + //鎼滅储 + form.on('submit(LAY-app-contlist-search)', function (data) { + refreshTable(); // refreshTablemx(xqid); - - //娓叉煋鐩樼偣鎬诲崟 - function refreshTable() { - var param1={ - // Href:'QualityControl/QualityInformation' - Href:'BllCheck/GetStockCheckList' - }; - sendData(IP + "/Sys/GetTableColsByUserId", param1, 'post', function(res) { - if (res.code == 0){ - if(res.data=='' || res.data==undefined || res.data==null){ - console.log(1) - colsJsonz=TotalColsArrz - }else{ - console.log(2) - colsJsonz= eval(res.data); - } - }else{ - colsJsonz=TotalColsArrz - } - // tableclass(LotNo,SkuNo,SkuName,IsQualified); - var param = { - CrNo: $("#CRNo").val(), - Status: $("#Status").val(), - - PalletNo: $("#PalletNo").val(), - SkuNo: $("#SkuNo").val(), - SkuName: $("#SkuName").val(), - LotNo: $("#LotNo").val(), - StartTime: $("#StartTime").val(), - EndTime: $("#EndTime").val(), - }; - table.render({ - elem: '#LAY-app-content-list', - url: IP + "/BllCheck/GetStockCheckList", - method: 'post', - height: h1 ,//'full-'+hei1 - id: 'LAY-app-content-list', - where: param, - contentType: 'application/json', - // toolbar: '#toolbarDemo', - defaultToolbar: [], //'filter','print', 'exports' - headers: { ToKen: $.cookie('token') }, - page: true, - even: true, - limit: pageCnt, - limits: pageLimits, - cellMinWidth: 60, //鍏ㄥ眬瀹氫箟甯歌鍗曞厓鏍肩殑鏈�灏忓搴︼紝layui 2.2.1 鏂板 - done: function (res) { - initMenu(); - var soCode = "res.data[0].SONo"; - if (res.data.length != 0) { - soCode = res.data[0].SONo; - } - refreshTablemx(soCode) - //鑷畾涔夊垪瀹� - SetTableColW('LAY-app-content-list','BllCheck/GetStockCheckList',TotalColsSysArrz); - }, - cols: colsJsonz - }); - - // table.render({ - // elem: '#LAY-app-content-list', - // url: IP+"/BllCheck/GetStockCheckList", - // method: 'POST', - // height: h1 ,//'full-'+hei1 - // id: 'LAY-app-content-list', - // where: param, - // contentType: 'application/json', - // headers:{ToKen:$.cookie('token')}, - // page: true, - // even: true, - // limit: pageCnt, - // limits: pageLimits, - // cellMinWidth: 60, //鍏ㄥ眬瀹氫箟甯歌鍗曞厓鏍肩殑鏈�灏忓搴︼紝layui 2.2.1 鏂板 - // done: function(res){ - // initMenu(); - // var soCode = "res.data[0].SONo"; - // if (res.data.length != 0) { - // soCode = res.data[0].SONo; - // } - // refreshTablemx(soCode) - // }, - // cols: [ - // [ - // {title: '搴忓彿', type: 'numbers', width: 65, fixed: 'left', }, - // {field: 'CrNo', title: '鐩樼偣鍗曞彿', align: 'center', fixed: 'left', width: 165, }, - // {field: 'Origin',title: '鏉ユ簮',align: 'center', templet: '#OriginzongButton', }, - // {field: 'Status',title: '鎵ц鐘舵��',align: 'center', templet: '#StatuszongButton', }, - // {field: 'CheckDate',title: '寮�濮嬫椂闂�',align: 'center', templet: '#CheckDateButton', }, - // {field: 'CompleteDate',title: '瀹屾垚鏃堕棿',align: 'center', templet: '#CompleteDateButtom', }, - // {field: 'AuditStatusNo',title: '瀹℃牳鐘舵��',align: 'center',width: 130,hide:true, templet: '#AuditStatusButton', }, - // {field: 'IsDoubleCheck', title: '鏄惁澶嶇洏', align: 'center', width: 180, hide:true, templet: '#IsDoubleCheckButton', }, - // {field: 'AuditUserName',title: '瀹℃牳浜�',align: 'center',width: 180,hide:true}, - // {field: 'AuditTime',title: '瀹℃牳鏃堕棿',align: 'center',width: 95,hide:true , templet: '#AuditTimeButton', }, - // {field: 'CreateUserName', title:'鍒涘缓浜�', align:'center', }, - // {field: 'CreateTime',title: '鍒涘缓鏃堕棿',align: 'center', templet: '#CreateTimeButton', }, - // {field: 'UpdateUserName',title: '淇敼浜�',align: 'center',width: 120,hide:true}, - // {field: 'UpdateTime',title: '淇敼鏃堕棿',align: 'center',width: 160,hide:true, templet: '#UpdateTimeButton', }, - // {title: '鎿嶄綔',fixed: 'right',align: 'center',toolbar: '#table-content-list',width: 240 } - // ]] - // }); - }); - } - //娓叉煋鍑哄簱鍗曟槑缁� - function refreshTablemx(crNo) { - var param1={ - // Href:'QualityControl/QualityInformation' - Href:'BllCheck/GetStockCheckDetailList' - }; - sendData(IP + "/Sys/GetTableColsByUserId", param1, 'post', function(res) { - if (res.code == 0){ - if(res.data=='' || res.data==undefined || res.data==null){ - colsJsonm=TotalColsArrm - }else{ - colsJsonm= eval(res.data); - } - }else{ - colsJsonm=TotalColsArrm - } - var param = { - CrNo: crNo, - }; - table.render({ - elem: '#LAY-app-content-list2', - url: IP + "/BllCheck/GetStockCheckDetailList", - method: 'post', - height: h2 ,//'full-'+hei1 - id: 'LAY-app-content-list2', - where: param, - contentType: 'application/json', - toolbar: '#toolbarDemo', - defaultToolbar: [], //'filter','print', 'exports' - headers: { ToKen: $.cookie('token') }, - page: true, - even: true, - limit: pageCnt, - limits: pageLimits, - cellMinWidth: 60, //鍏ㄥ眬瀹氫箟甯歌鍗曞厓鏍肩殑鏈�灏忓搴︼紝layui 2.2.1 鏂板 - done: function (res) { - initMenu(); - //鑷畾涔夊垪瀹� - SetTableColW('LAY-app-content-list2','BllCheck/GetStockCheckDetailList',TotalColsSysArrm); - }, - cols: colsJsonm - }); - // var param = { - // CrNo: crNo, - // }; - // table.render({ - // elem: '#LAY-app-content-list2', - // url: IP + "/BllCheck/GetStockCheckDetailList", - // method: 'POST', - // height: h2, - // id: 'LAY-app-content-list2', - // where: param, - // contentType: 'application/json', - // headers:{ToKen:$.cookie('token')}, - // toolbar:'#toolbarDemo', - // defaultToolbar: ['filter'], //'print', 'exports' - // page: true, - // limit: pageCnt, - // limits: pageLimits, - // cellMinWidth: 60, //鍏ㄥ眬瀹氫箟甯歌鍗曞厓鏍肩殑鏈�灏忓搴︼紝layui 2.2.1 鏂板 - // done: function(){ - // initMenu(); - // }, - // cols: [ - // [ - // {title:'搴忓彿', type:'numbers', width:65, fixed:'left', }, - // {field:'CrNo', title:'鐩樼偣鍗曞彿', align:'center', fixed:'left', width: 165, }, - // {field:'PalletNo', title:'鎵樼洏鍙�', align:'center', fixed:'left', width: 165, }, - // {field:'Qty', title:'搴撳瓨鏁伴噺', align:'center', fixed:'left', width: 105, }, - // {field:'RealQty', title:'瀹為檯鏁伴噺', align:'center', width: 105, }, - // {field:'Status', title:'鎵ц鐘舵��', align:'center', width: 105, templet : '#StatusmingButton', }, - // {field:'CheckResult', title:'鐩樼偣缁撴灉', align:'center', width:105, templet : '#CheckResultButton', }, - // {field:'SkuNo', title:'鐗╂枡缂栫爜', align:'center', width:105, }, - // {field:'SkuName', title:'鐗╂枡鍚嶇О', align:'center', width:125, }, - // {field:'Standard', title:'瑙勬牸', align:'center', width:225, }, - // {field:'LotNo', title:'鎵规鍙�', align:'center', width:105, }, - // {field:'LotText', title:'鎵规鎻忚堪', align:'center', width:105, }, - // {field:'SupplierLot', title:'渚涜揣鎵规', align:'center', width:105, }, - // {field: 'CreateUserName', title:'鍒涘缓浜�', align:'center', width:100, }, - // {field: 'CreateTime',title: '鍒涘缓鏃堕棿',align: 'center',width: 160, templet: '#CreateTimeButton',}, - // {field: 'UpdateUserName',title: '淇敼浜�',align: 'center',width: 120,hide:true}, - // {field: 'UpdateTime',title: '淇敼鏃堕棿',align: 'center',width: 160,hide:true, templet: '#UpdateTimeButton',}, - // ]] - // }); - }); - } - //鎼滅储 - form.on('submit(LAY-app-contlist-search)', function(data) { - refreshTable(); - // refreshTablemx(xqid); + }); + //鏉冮檺 + function initMenu() { + $(function () { + $(".addClass").hide(); + $(".editClass").hide(); + $(".delClass").hide(); + $(".checkOut").hide(); + $(".addAdjust").hide(); + $(".editDemoClass").hide();//澶囨敞 }); - //鏉冮檺 - function initMenu() { - $(function() { - $(".addClass").hide(); - $(".editClass").hide(); - $(".delClass").hide(); - $(".checkOut").hide(); - $(".addAdjust").hide(); - $(".editDemoClass").hide();//澶囨敞 - }); - sendData(IP + "/Basis/GetRoleRightList", {}, 'get', function(res) { - if (res.code == 0) { //鎴愬姛 - for (var k = 0; k < res.data.length; k++) { - if (res.data[k].MenuName == "娣诲姞鐩樼偣鍗�") { - $(function() { - $(".addClass").show(); - }); - } - if (res.data[k].MenuName == "缂栬緫鐩樼偣鍗�") { - $(function() { - $(".editClass").show(); - }); - } - if (res.data[k].MenuName == "鍒犻櫎鐩樼偣鍗�") { - $(function() { - $(".delClass").show(); - }); - } - if (res.data[k].MenuName == "鐩樼偣鍑哄簱") { - $(function() { - $(".checkOut").show(); - }); - } - if (res.data[k].MenuName == "璋冩暣搴撳瓨") { - $(function() { - $(".addAdjust").show(); - }); - } - if (res.data[k].MenuName == "缁存姢鐩樼偣鍗曞娉�") { - $(function() { - $(".editDemoClass").show(); - }); - } + sendData(IP + "/Basis/GetRoleRightList", {}, 'get', function (res) { + if (res.code == 0) { //鎴愬姛 + for (var k = 0; k < res.data.length; k++) { + if (res.data[k].MenuName == "娣诲姞鐩樼偣鍗�") { + $(function () { + $(".addClass").show(); + }); } - } else { //涓嶆垚鍔� - layer.msg('鑾峰彇鏉冮檺淇℃伅澶辫触', { - icon: 2, - time: 2000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 - }, function() {}); + if (res.data[k].MenuName == "缂栬緫鐩樼偣鍗�") { + $(function () { + $(".editClass").show(); + }); + } + if (res.data[k].MenuName == "鍒犻櫎鐩樼偣鍗�") { + $(function () { + $(".delClass").show(); + }); + } + if (res.data[k].MenuName == "鐩樼偣鍑哄簱") { + $(function () { + $(".checkOut").show(); + }); + } + if (res.data[k].MenuName == "璋冩暣搴撳瓨") { + $(function () { + $(".addAdjust").show(); + }); + } + if (res.data[k].MenuName == "缁存姢鐩樼偣鍗曞娉�") { + $(function () { + $(".editDemoClass").show(); + }); + } } - }); - } - //瑙﹀彂琛屽崟鍑讳簨浠� - table.on('row(LAY-app-content-list)', function(obj) { - refreshTablemx(obj.data.CrNo); - xqid = "obj.data.CrNo"; - }); - - - - //-------------------------------------------------------------------------------------------- - //澶村伐鍏锋爮浜嬩欢 - table.on('toolbar(LAY-app-content-list2)', function(obj){ - var checkStatus = table.checkStatus(obj.config.id); - if (obj.event == "add") { - layer.open({ - type: 2, - title: '娣诲姞鐩樼偣鍗�', - content: 'StockCheckFrom.html', - maxmin: true, - area: ['1200px', '90%'], - }); + } else { //涓嶆垚鍔� + layer.msg('鑾峰彇鏉冮檺淇℃伅澶辫触', { + icon: 2, + time: 2000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 + }, function () { }); } }); - //鐩戝惉鏁版嵁鎿嶄綔 - table.on('tool(LAY-app-content-list)', function(obj) { - var data = obj.data; - console.log(data); - Id = data.Id; - CrNo = data.CrNo; - if (obj.event === 'del') {//鍒犻櫎 - layer.confirm('纭畾鍒犻櫎姝ゅ崟鎹悧锛�', function(index) { - var param = { - Id: parseInt(Id), - }; - sendData(IP + "/BllCheck/DelStockCheck", param, 'post', function(res) { - console.log(res); - if (res.code == 0) { //鎴愬姛 - layer.msg(res.msg, { - icon: 1, - time: 1000 //1绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 - }, function() { - refreshTable(); - }); - } else { //涓嶆垚鍔� - layer.msg(res.msg, { - icon: 2, - time: 2000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 - }, function() {}); - } - }); - }); - } else if (obj.event === 'finish') {//鐢熸垚璋冩暣鍗� - layer.confirm('纭畾璋冩暣搴撳瓨鍚楋紵', function(index) { - var param = { - Id: parseInt(Id), - Origin:data.Origin - }; - sendData(IP + "/UpApi/FinishCr", param, 'post', function(res) { - console.log(res); - if (res.code == 0) { //鎴愬姛 - layer.msg(res.msg, { - icon: 1, - time: 1000 //1绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 - }, function() { - refreshTable(); - }); - } else { //涓嶆垚鍔� - layer.msg(res.msg, { - icon: 2, - time: 2000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 - }, function() { - refreshTable(); - }); - } - }); - }); - }else if(obj.event === 'edit'){//缂栬緫 - layer.open({ - type: 2, - title: '缂栬緫鐩樼偣鍗�', - content: 'StockCheckFrom.html?crNo='+CrNo, - maxmin: true, - area: ['1200px', '90%'], - }); - }else if(obj.event === 'outbound'){ - layer.open({ - type: 1, - title: '纭鍑哄簱鍙�', - content: $('#divPickingArea'), - maxmin: true, - area: ['300px','265px'], - btn: ['纭畾', '鍙栨秷'], - yes: function(index, layero) { - var pa = $('#PickingArea').val(); - if (isChongFu== true) { - isChongFu= false; - - var param = { - crNo: data.CrNo, - outMode: pa, - }; - sendData(IP + "/DownApi/CheckOutHouse", param, 'get', function(res) { - console.log(res); - if (res.code == 0) { //鎴愬姛 - layer.msg(res.msg, { - icon: 1, - time: 3000 //1绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 - }, function() { - refreshTable(); - isChongFu= true; - }); - } else { //涓嶆垚鍔� - layer.msg(res.msg, { - icon: 2, - time: 3000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 - }, function() { - refreshTable(); - isChongFu= true; - }); - } - layer.close(index); - }); - }else{ - layer.msg("璇峰嬁閲嶅鐐瑰嚮", { - icon: 2, - time: 2000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 - }); - } + } + //瑙﹀彂琛屽崟鍑讳簨浠� + table.on('row(LAY-app-content-list)', function (obj) { + refreshTablemx(obj.data.CrNo); + xqid = "obj.data.CrNo"; + }); + + + + //-------------------------------------------------------------------------------------------- + //澶村伐鍏锋爮浜嬩欢 + table.on('toolbar(LAY-app-content-list2)', function (obj) { + var checkStatus = table.checkStatus(obj.config.id); + if (obj.event == "add") { + layer.open({ + type: 2, + title: '娣诲姞鐩樼偣鍗�', + content: 'StockCheckFrom.html', + maxmin: true, + area: ['1200px', '90%'], + }); + } + }); + //鐩戝惉鏁版嵁鎿嶄綔 + table.on('tool(LAY-app-content-list)', function (obj) { + var data = obj.data; + console.log(data); + Id = data.Id; + CrNo = data.CrNo; + if (obj.event === 'del') {//鍒犻櫎 + layer.confirm('纭畾鍒犻櫎姝ゅ崟鎹悧锛�', function (index) { + var param = { + Id: parseInt(Id), + }; + sendData(IP + "/BllCheck/DelStockCheck", param, 'post', function (res) { + console.log(res); + if (res.code == 0) { //鎴愬姛 + layer.msg(res.msg, { + icon: 1, + time: 1000 //1绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 + }, function () { + refreshTable(); + }); + } else { //涓嶆垚鍔� + layer.msg(res.msg, { + icon: 2, + time: 2000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 + }, function () { }); } - }); - }else if(obj.event === 'editDemo'){//缂栬緫澶囨敞 - $('#NoticeDemo').val(data.Demo); - layer.open({ - type: 1, - title: '缁存姢澶囨敞', - content: $('#divEditDemo'), - maxmin: false, - area: ['420px','260px'], - btn: ['纭畾', '鍙栨秷'], - yes: function(index, layero) { - var demo = $('#NoticeDemo').val(); + }); + }); + } else if (obj.event === 'finish') {//鐢熸垚璋冩暣鍗� + layer.confirm('纭畾璋冩暣搴撳瓨鍚楋紵', function (index) { + var param = { + Id: parseInt(Id), + Origin: data.Origin + }; + sendData(IP + "/UpApi/FinishCr", param, 'post', function (res) { + console.log(res); + if (res.code == 0) { //鎴愬姛 + layer.msg(res.msg, { + icon: 1, + time: 1000 //1绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 + }, function () { + refreshTable(); + }); + } else { //涓嶆垚鍔� + layer.msg(res.msg, { + icon: 2, + time: 2000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 + }, function () { + refreshTable(); + }); + } + }); + }); + } else if (obj.event === 'edit') {//缂栬緫 + layer.open({ + type: 2, + title: '缂栬緫鐩樼偣鍗�', + content: 'StockCheckFrom.html?crNo=' + CrNo, + maxmin: true, + area: ['1200px', '90%'], + }); + } else if (obj.event === 'outbound') { + layer.open({ + type: 1, + title: '纭鍑哄簱鍙�', + content: $('#divPickingArea'), + maxmin: true, + area: ['300px', '265px'], + btn: ['纭畾', '鍙栨秷'], + yes: function (index, layero) { + var pa = $('#PickingArea').val(); + if (isChongFu == true) { + isChongFu = false; + var param = { - id: data.Id, - demo: demo, + crNo: data.CrNo, + outMode: pa, }; - sendData(IP + "/BllCheck/EditNoticeDemo", param, 'get', function(res) { + sendData(IP + "/DownApi/CheckOutHouse", param, 'get', function (res) { + console.log(res); if (res.code == 0) { //鎴愬姛 - refreshTable(); layer.msg(res.msg, { icon: 1, - time: 1500 //1绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 - }, function() { - + time: 3000 //1绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 + }, function () { + refreshTable(); + isChongFu = true; }); } else { //涓嶆垚鍔� layer.msg(res.msg, { icon: 2, time: 3000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 - }, function() { + }, function () { refreshTable(); + isChongFu = true; }); } layer.close(index); }); + } else { + layer.msg("璇峰嬁閲嶅鐐瑰嚮", { + icon: 2, + time: 2000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 + }); } - }); - } - }); - - var $ = layui.$, - active = { - customCols: function(){ - layer.open({ - type: 2, - title: '鑷畾涔夊垪', - content: '../SystemSettings/HeaderSetting.html?Href=BllCheck/GetStockCheckList&ColsSysArr='+TotalColsSysArrz, - maxmin: false, - resize: false, - area: ['970px', '650px'] + } + }); + } else if (obj.event === 'vision') { + + layer.confirm('纭畾瑙嗚鐩樼偣', function () { + if (isChongFu == true) { + isChongFu = false; + var param = { + crNo: data.CrNo + }; + sendData(IP + "/DownApi/CheckVision", param, 'get', function (res) { + console.log(res); + if (res.code == 0) { //鎴愬姛 + layer.msg(res.msg, { + icon: 1, + time: 3000 //1绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 + }, function () { + refreshTable(); + isChongFu = true; + }); + } else { //涓嶆垚鍔� + layer.msg(res.msg, { + icon: 2, + time: 3000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 + }, function () { + refreshTable(); + isChongFu = true; + }); + } + layer.close(index); }); - }, - customCols2: function(){ - layer.open({ - type: 2, - title: '鑷畾涔夊垪', - content: '../SystemSettings/HeaderSetting.html?Href=BllCheck/GetStockCheckDetailList&ColsSysArr='+TotalColsSysArrm, - maxmin: false, - resize: false, - area: ['970px', '650px'] + } else { + layer.msg("璇峰嬁閲嶅鐐瑰嚮", { + icon: 2, + time: 2000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 + }, function () { + isChongFu = true }); } - }; - $('.layui-btn').on('click', function() { - var type = $(this).data('type'); - active[type] ? active[type].call(this) : ''; - }); - + }, function () { + + }); + } else if (obj.event === 'editDemo') {//缂栬緫澶囨敞 + $('#NoticeDemo').val(data.Demo); + layer.open({ + type: 1, + title: '缁存姢澶囨敞', + content: $('#divEditDemo'), + maxmin: false, + area: ['420px', '260px'], + btn: ['纭畾', '鍙栨秷'], + yes: function (index, layero) { + var demo = $('#NoticeDemo').val(); + var param = { + id: data.Id, + demo: demo, + }; + sendData(IP + "/BllCheck/EditNoticeDemo", param, 'get', function (res) { + if (res.code == 0) { //鎴愬姛 + refreshTable(); + layer.msg(res.msg, { + icon: 1, + time: 1500 //1绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 + }, function () { + + }); + } else { //涓嶆垚鍔� + layer.msg(res.msg, { + icon: 2, + time: 3000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 + }, function () { + refreshTable(); + }); + } + layer.close(index); + }); + } + }); + } }); - </script> - </body> -</html> + + var $ = layui.$, + active = { + customCols: function () { + layer.open({ + type: 2, + title: '鑷畾涔夊垪', + content: '../SystemSettings/HeaderSetting.html?Href=BllCheck/GetStockCheckList&ColsSysArr=' + TotalColsSysArrz, + maxmin: false, + resize: false, + area: ['970px', '650px'] + }); + }, + customCols2: function () { + layer.open({ + type: 2, + title: '鑷畾涔夊垪', + content: '../SystemSettings/HeaderSetting.html?Href=BllCheck/GetStockCheckDetailList&ColsSysArr=' + TotalColsSysArrm, + maxmin: false, + resize: false, + area: ['970px', '650px'] + }); + } + }; + $('.layui-btn').on('click', function () { + var type = $(this).data('type'); + active[type] ? active[type].call(this) : ''; + }); + + }); + </script> +</body> + +</html> \ No newline at end of file -- Gitblit v1.8.0