From fc69a1e9655df3e8a01dc36ea2742c99f4a651ed Mon Sep 17 00:00:00 2001
From: duhe <226547893@qq.com>
Date: 星期三, 17 一月 2024 13:22:08 +0800
Subject: [PATCH] 特批申请单:数据校验 销售订单:维护页面增加字段 销售出库关联数量、销售出库未关联数量、生产关联数量、生产未关联数量
---
WebTM/views/采购管理/委外订单/WW_EntrustOrderBillList.html | 313 ++++++++++++++++++++++++++++++++++++++-------------
1 files changed, 230 insertions(+), 83 deletions(-)
diff --git "a/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\345\247\224\345\244\226\350\256\242\345\215\225/WW_EntrustOrderBillList.html" "b/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\345\247\224\345\244\226\350\256\242\345\215\225/WW_EntrustOrderBillList.html"
index 30bd422..3f20a0c 100644
--- "a/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\345\247\224\345\244\226\350\256\242\345\215\225/WW_EntrustOrderBillList.html"
+++ "b/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\345\247\224\345\244\226\350\256\242\345\215\225/WW_EntrustOrderBillList.html"
@@ -15,6 +15,8 @@
<script src="../../../layuiadmin/Scripts/webConfig.js"></script>
<script src="../../../layuiadmin/PubCustom.js"></script>
<script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
+ <script src="../../../layuiadmin/HideButton.js"></script>
+ <script src="../../../layuiadmin/soulTable.slim.js"></script>
</head>
<body>
@@ -141,6 +143,7 @@
<label class="layui-form-label">瀹屾垚鐘舵��</label>
<div class="layui-input-block" style="width:190px;">
<select name="HFinishStatus" lay-filter="HFinishStatus">
+ <option value="" selected>鍏ㄩ儴</option>
<option value="鏈畬鎴�" selected>鏈畬鎴�</option>
<option value="宸插畬鎴�">宸插畬鎴�</option>
</select>
@@ -152,17 +155,19 @@
<table class="" id="mainTable" lay-filter="mainTable"></table>
<script type="text/html" id="toolbarDemo">
<div class="layui-btn-container">
- <!--<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-getCheckData"><i class="layui-icon layui-icon-tips"></i>棰勮</button>-->
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-fp"><i class="layui-icon layui-icon-tips"></i>鍒嗛厤</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-fb"><i class="layui-icon layui-icon-tips"></i>鍙戝竷</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-back"><i class="layui-icon layui-icon-close-fill"></i>鎾ら攢</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-yxj"><i class="layui-icon layui-icon-tips"></i>浼樺厛绾�</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="get_Refresh"><i class="layui-icon layui-icon-refresh"></i>鍒锋柊</button>
- <!--<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-confirm" id="btn_confirm"><i class="layui-icon layui-icon-ok-circle"></i>纭</button>
+ <!--<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-getCheckData" id="getCheckData"><i class="layui-icon layui-icon-tips"></i>棰勮</button>-->
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-fp" id="fp"><i class="layui-icon layui-icon-tips"></i>鍒嗛厤</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-fb" id="fb"><i class="layui-icon layui-icon-tips"></i>鍙戝竷</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-back" id="back"><i class="layui-icon layui-icon-close-fill"></i>鎾ら攢</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-yxj" id="yxj"><i class="layui-icon layui-icon-tips"></i>浼樺厛绾�</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="get_Refresh" id="Refresh"><i class="layui-icon layui-icon-refresh"></i>鍒锋柊</button>
+ <!--<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-confirm" id="btn_confirm" id="HideButton"><i class="layui-icon layui-icon-ok-circle"></i>纭</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-back" id="btn_back"><i class="layui-icon layui-icon-close-fill"></i>椹冲洖</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-details"><i class="layui-icon layui-icon-form"></i>璇︽儏</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-generate"><i class="layui-icon layui-icon-file"></i>鐢熸垚閫佽揣鍗�</button>-->
- <button type="button" class="layui-btn layui-btn-sm" lay-event="get_Exit"><i class="layui-icon layui-icon-return"></i>閫�鍑�</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-details" id="details"><i class="layui-icon layui-icon-form"></i>璇︽儏</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-generate" id="generate"><i class="layui-icon layui-icon-file"></i>鐢熸垚閫佽揣鍗�</button>-->
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_HideColumn" id="HideColumn"><i class="layui-icon layui-icon-form"></i>鍒楄缃�</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_HideButton" id="HideButton"><i class="layui-icon layui-icon-form"></i>鎸夐挳璁剧疆</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="get_Exit" id="Exit"><i class="layui-icon layui-icon-return"></i>閫�鍑�</button>
<!--<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnResCnz" id="btnReSearch" style="padding:0 5px">閲嶆柊鍚屾</button>-->
</div>
@@ -177,7 +182,7 @@
base: '../../../layuiadmin/' //闈欐�佽祫婧愭墍鍦ㄨ矾寰�
}).extend({
index: 'lib/index', //涓诲叆鍙fā鍧�
- }).use(['index', 'form', 'table', 'element', 'laypage', 'laydate'], function () {
+ }).use(['index', 'form', 'table', 'element', 'laypage', 'laydate', 'soulTable'], function () {
//#region 鍏叡鍙橀噺
var $ = layui.$
, admin = layui.admin
@@ -188,10 +193,12 @@
, laypage = layui.laypage
, laydate = layui.laydate
, util = layui.util
+ , soulTable = layui.soulTable
//鏌ヨ鏉′欢
var sWhere = "";
var option = [];
var Name = "MouldProdInHouseCellWidth";
+ var HModName = "WW_EntrustOrderBillList";
//#endregion
//#region 杩涘叆椤甸潰鏃㈠姞杞�
@@ -235,6 +242,15 @@
case 'btn-yxj': set_Yxj();
break;
case 'btn-back': set_Back();
+ break;
+ //鍒楄缃�
+ case 'set_HideColumn': get_HideColumn();
+ break;
+ //鎸夐挳璁剧疆
+ case 'set_HideButton':
+ var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
+ var HBillType = "1601";
+ get_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
break;
};
});
@@ -297,84 +313,86 @@
get_FastQuery(table, option)
//鍔犺浇涓氬姟鍛�
get_HEmpName();
+ //闅愯棌鍕鹃�夊瓧娈�
+ DisPlay_HideColumn();
}
//鍒濆鍖栬〃鏍�
function set_InitGrid() {
$("#HBeginDate").val("2022-03-14");
$("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
var columns = [
- { type: 'checkbox', fixed: 'left', totalRowText: '鍚堣' }
+ { type: 'checkbox', fixed: 'left', totalRowText: '鍚堣'}
, { field: 'hmainid', title: 'hmainid', sort: true, hide: true }
- , { field: '鏃ユ湡', title: '鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: '鍗曟嵁鍙�', title: '鍗曟嵁鍙�', width: 150 }
- , { field: '渚涘簲鍟�', title: '渚涘簲鍟�', width: 150 }
- , { field: '涓氬姟鍛�', title: '涓氬姟鍛�', width: 100 }
- , { field: 'HBillType', title: 'HBillType', hide: true }
- , { field: 'HSupID', title: 'HSupID', hide: true }
- , { field: '涓氬姟鐘舵��', title: '涓氬姟鐘舵��', width: 100 , hide: true }
- , { field: '鍒嗛厤鐘舵��', title: '鍒嗛厤鐘舵��', width: 100 }
- , { field: '鍙戝竷鐘舵��', title: '鍙戝竷鐘舵��', width: 100 }
- , { field: '渚涘簲鍟嗗崗鍚岀姸鎬�', title: '渚涘簲鍟嗗崗鍚岀姸鎬�', width: 135 }/*鐗╂枡浠g爜锛岀墿鏂欏悕绉帮紝瑙勬牸鍨嬪彿锛屾壒鍙凤紝鏁伴噺锛屽崟浣嶏紝婧愬崟鍗曞彿*/
- , { field: '鍙嶉鐘舵��', title: '渚涘簲鍟嗗弽棣堢姸鎬�', width: 135 }
- , { field: '鐗╂枡缂栫爜', title: '鐗╂枡缂栫爜', width: 130 }
- , { field: '鐗╂枡浠g爜', title: '鐗╂枡浠g爜', width: 130 }
- , { field: '鐗╂枡鍚嶇О', title: '鐗╂枡鍚嶇О', width: 120 }
- , { field: '鏁伴噺', title: '璁㈠崟鏁伴噺', width: 100}
- , { field: '鎵撳嵃鏉$爜鏁伴噺', title: '鎵撳嵃鏉$爜鏁伴噺', width: 120}
- , { field: '鍏宠仈鏁伴噺', title: '宸插彂璐ф暟閲�', width: 120 }
- , { field: '鏈叧鑱旀暟閲�', title: '鏈凡鍙戣揣鏁伴噺', width: 120 }
- , { field: '瀹屾垚鐘舵��', title: '瀹屾垚鐘舵��', width: 100 }
- , { field: 'HUnitID', title: 'HUnitID', hide: true }
- , { field: '璁¢噺鍗曚綅浠g爜', title: '璁¢噺鍗曚綅浠g爜', width: 120 }
- , { field: '璁¢噺鍗曚綅', title: '璁¢噺鍗曚綅', width: 100 }
- , { field: '瑙勬牸鍨嬪彿', title: '瑙勬牸鍨嬪彿', width: 100 }
- , { field: '鎵瑰彿', title: '鎵瑰彿', width: 100 }
- , { field: '婧愬崟鍗曞彿', title: '婧愬崟鍗曞彿', width: 100 }
- , { field: '渚涘簲鍟嗕唬鐮�', title: '渚涘簲鍟嗕唬鐮�', width: 120, hide: true}
- , { field: '涓氬姟鍛樹唬鐮�', title: '涓氬姟鍛樹唬鐮�', width: 100, hide: true }
- , { field: 'HPriority', title: 'HPriority', width: 100, hide: true }
- , { field: '浼樺厛绾�', title: '浼樺厛绾�', width: 100 }
- , { field: '浜よ揣鍦扮偣', title: '浜よ揣鍦扮偣', width: 100 }
- , { field: 'HPSStyleID', title: 'HPSStyleID', hide: true }
- , { field: '閲囪喘鏂瑰紡浠g爜', title: '閲囪喘鏂瑰紡浠g爜', width: 120 }
- , { field: '閲囪喘鏂瑰紡', title: '閲囪喘鏂瑰紡', width: 100 }
- , { field: 'HSSID', title: 'HSSID', hide: true }
- , { field: '缁撶畻鏂瑰紡浠g爜', title: '缁撶畻鏂瑰紡浠g爜', width: 120 }
- , { field: '缁撶畻鏂瑰紡', title: '缁撶畻鏂瑰紡', width: 100 }
- , { field: '缁撶畻鏃ユ湡', title: '缁撶畻鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.缁撶畻鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: 'HCurID', title: 'HCurID', hide: true }
- , { field: '甯佸埆浠g爜', title: '甯佸埆浠g爜', width: 100 }
- , { field: '甯佸埆', title: '甯佸埆', width: 100 }
- , { field: '姹囩巼', title: '姹囩巼', width: 100 }
- , { field: 'HDeptID', title: 'HDeptID', hide: true }
- , { field: '閮ㄩ棬浠g爜', title: '閮ㄩ棬浠g爜', width: 100 }
- , { field: '閮ㄩ棬', title: '閮ㄩ棬', width: 100 }
- , { field: 'HManagerID', title: 'HManagerID', hide: true }
- , { field: '涓荤浠g爜', title: '涓荤浠g爜', width: 100 }
- , { field: '涓荤', title: '涓荤', width: 100 }
- , { field: 'HEmpID', title: 'HEmpID', hide: true }
- , { field: '鎽樿', title: '鎽樿', width: 100 }
- , { field: '琛ㄥご澶囨敞', title: '琛ㄥご澶囨敞', width: 100 }
- , { field: 'hsubid', title: 'hsubid', hide: true }
- , { field: 'HMaterID', title: 'HMaterID', hide: true }
- , { field: '鍗曚环', title: '鍗曚环', width: 100 }
- , { field: '閲戦', title: '閲戦', width: 100 }
- , { field: '绋庣巼', title: '绋庣巼', width: 100 }
- , { field: '绋庨', title: '绋庨', width: 100 }
- , { field: '浠风◣鍚堣', title: '浠风◣鍚堣', width: 100 }
- , { field: '浜よ揣鏃ユ湡', title: '浜よ揣鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.浜よ揣鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: '璁″垝璺熻釜鍙�', title: '璁″垝璺熻釜鍙�', width: 100 }
- , { field: '琛ㄤ綋澶囨敞', title: '琛ㄤ綋澶囨敞', width: 100 }
- , { field: '鍒跺崟浜�', title: '鍒跺崟浜�', width: 100 }
- , { field: '鍒跺崟鏃ユ湡', title: '鍒跺崟鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.鍒跺崟鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: '瀹℃牳浜�', title: '瀹℃牳浜�', width: 100 }
- , { field: '瀹℃牳鏃ユ湡', title: '瀹℃牳鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.瀹℃牳鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: '淇敼浜�', title: '淇敼浜�', width: 100 }
- , { field: '淇敼鏃ユ湡', title: '淇敼鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.淇敼鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: '鍏抽棴浜�', title: '鍏抽棴浜�', width: 100 }
- , { field: '鍏抽棴鏃ユ湡', title: '鍏抽棴鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.鍏抽棴鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: '浣滃簾浜�', title: '浣滃簾浜�', width: 100 }
- , { field: '浣滃簾鏃ユ湡', title: '浣滃簾鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.浣滃簾鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: '鏃ユ湡', title: '鏃ユ湡', width: 120, sort: true, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: '鍗曟嵁鍙�', title: '鍗曟嵁鍙�', width: 150, sort: true}
+ , { field: '渚涘簲鍟�', title: '渚涘簲鍟�', width: 150, sort: true}
+ , { field: '涓氬姟鍛�', title: '涓氬姟鍛�', width: 100, sort: true }
+ , { field: 'HBillType', title: 'HBillType', hide: true, sort: true}
+ , { field: 'HSupID', title: 'HSupID', hide: true, sort: true }
+ , { field: '涓氬姟鐘舵��', title: '涓氬姟鐘舵��', width: 100, hide: true, sort: true}
+ , { field: '鍒嗛厤鐘舵��', title: '鍒嗛厤鐘舵��', width: 100, sort: true }
+ , { field: '鍙戝竷鐘舵��', title: '鍙戝竷鐘舵��', width: 100, sort: true }
+ , { field: '渚涘簲鍟嗗崗鍚岀姸鎬�', title: '渚涘簲鍟嗗崗鍚岀姸鎬�', width: 135, sort: true }/*鐗╂枡浠g爜锛岀墿鏂欏悕绉帮紝瑙勬牸鍨嬪彿锛屾壒鍙凤紝鏁伴噺锛屽崟浣嶏紝婧愬崟鍗曞彿*/
+ , { field: '鍙嶉鐘舵��', title: '渚涘簲鍟嗗弽棣堢姸鎬�', width: 135, sort: true}
+ , { field: '鐗╂枡缂栫爜', title: '鐗╂枡缂栫爜', width: 130, sort: true }
+ , { field: '鐗╂枡浠g爜', title: '鐗╂枡浠g爜', width: 130, sort: true}
+ , { field: '鐗╂枡鍚嶇О', title: '鐗╂枡鍚嶇О', width: 120, sort: true}
+ , { field: '鏁伴噺', title: '璁㈠崟鏁伴噺', width: 100, sort: true}
+ , { field: '鎵撳嵃鏉$爜鏁伴噺', title: '鎵撳嵃鏉$爜鏁伴噺', width: 120, sort: true}
+ , { field: '鍏宠仈鏁伴噺', title: '宸插彂璐ф暟閲�', width: 120, sort: true }
+ , { field: '鏈叧鑱旀暟閲�', title: '鏈凡鍙戣揣鏁伴噺', width: 120, sort: true }
+ , { field: '瀹屾垚鐘舵��', title: '瀹屾垚鐘舵��', width: 100, sort: true}
+ , { field: 'HUnitID', title: 'HUnitID', hide: true, sort: true}
+ , { field: '璁¢噺鍗曚綅浠g爜', title: '璁¢噺鍗曚綅浠g爜', width: 120, 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: 120, hide: true}
+ //, { field: '涓氬姟鍛樹唬鐮�', title: '涓氬姟鍛樹唬鐮�', width: 100, hide: true }
+ //, { field: 'HPriority', title: 'HPriority', width: 100, hide: true }
+ , { field: '浼樺厛绾�', title: '浼樺厛绾�', width: 100, sort: true}
+ , { field: '浜よ揣鍦扮偣', title: '浜よ揣鍦扮偣', width: 100, sort: true}
+ //, { field: 'HPSStyleID', title: 'HPSStyleID', hide: true }
+ , { field: '閲囪喘鏂瑰紡浠g爜', title: '閲囪喘鏂瑰紡浠g爜', width: 120, sort: true}
+ , { field: '閲囪喘鏂瑰紡', title: '閲囪喘鏂瑰紡', width: 100, sort: true}
+ //, { field: 'HSSID', title: 'HSSID', hide: true }
+ , { field: '缁撶畻鏂瑰紡浠g爜', title: '缁撶畻鏂瑰紡浠g爜', width: 120, sort: true}
+ , { field: '缁撶畻鏂瑰紡', title: '缁撶畻鏂瑰紡', width: 100, sort: true}
+ , { field: '缁撶畻鏃ユ湡', title: '缁撶畻鏃ユ湡', width: 120, sort: true, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.缁撶畻鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ //, { field: 'HCurID', title: 'HCurID', hide: true }
+ , { field: '甯佸埆浠g爜', title: '甯佸埆浠g爜', width: 100, sort: true}
+ , { field: '甯佸埆', title: '甯佸埆', width: 100, sort: true}
+ , { field: '姹囩巼', title: '姹囩巼', width: 100, sort: true}
+ //, { field: 'HDeptID', title: 'HDeptID', hide: true }
+ , { field: '閮ㄩ棬浠g爜', title: '閮ㄩ棬浠g爜', width: 100, sort: true}
+ , { field: '閮ㄩ棬', title: '閮ㄩ棬', width: 100, sort: true}
+ //, { field: 'HManagerID', title: 'HManagerID', hide: true }
+ , { field: '涓荤浠g爜', title: '涓荤浠g爜', width: 100, sort: true}
+ , { field: '涓荤', title: '涓荤', width: 100, sort: true}
+ //, { field: 'HEmpID', title: 'HEmpID', hide: true }
+ , { field: '鎽樿', title: '鎽樿', width: 100, sort: true}
+ , { field: '琛ㄥご澶囨敞', title: '琛ㄥご澶囨敞', width: 100, sort: true}
+ //, { field: 'hsubid', title: 'hsubid', hide: true }
+ //, { field: 'HMaterID', title: 'HMaterID', hide: 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}
+ , { field: '浜よ揣鏃ユ湡', title: '浜よ揣鏃ユ湡', width: 120, sort: true, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.浜よ揣鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: '璁″垝璺熻釜鍙�', title: '璁″垝璺熻釜鍙�', width: 100, sort: true}
+ , { field: '琛ㄤ綋澶囨敞', title: '琛ㄤ綋澶囨敞', width: 100, sort: true}
+ , { field: '鍒跺崟浜�', title: '鍒跺崟浜�', width: 100, sort: true}
+ , { field: '鍒跺崟鏃ユ湡', title: '鍒跺崟鏃ユ湡', width: 120, sort: true, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.鍒跺崟鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: '瀹℃牳浜�', title: '瀹℃牳浜�', width: 100, sort: true}
+ , { field: '瀹℃牳鏃ユ湡', title: '瀹℃牳鏃ユ湡', width: 120, sort: true, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.瀹℃牳鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: '淇敼浜�', title: '淇敼浜�', width: 100, sort: true}
+ , { field: '淇敼鏃ユ湡', title: '淇敼鏃ユ湡', width: 120, sort: true, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.淇敼鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: '鍏抽棴浜�', title: '鍏抽棴浜�', width: 100, sort: true}
+ , { field: '鍏抽棴鏃ユ湡', title: '鍏抽棴鏃ユ湡', width: 120, sort: true, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.鍏抽棴鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: '浣滃簾浜�', title: '浣滃簾浜�', width: 100, sort: true}
+ , { field: '浣滃簾鏃ユ湡', title: '浣滃簾鏃ユ湡', width: 120, sort: true, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.浣滃簾鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
];
option = {
@@ -388,7 +406,7 @@
, cols: [columns]
, limits: [500, 5000, 20000]
, done: function (res, curr, count) {
-
+ soulTable.render(this);
}
};
////璁剧疆鍒楀
@@ -426,6 +444,12 @@
DataList = data1.data;
option.data = data1.data;
table.render(option);
+
+ //鍒锋柊鎸夐挳鏄剧ず
+ var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
+ var HBillType = "1601";
+ Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+
layer.close(wait);
} else {
layer.close(wait);
@@ -1102,6 +1126,129 @@
}
})
}
+
+ //闅愯棌鍒楄缃�
+ function get_HideColumn() {
+ var colName = "";
+ var contentUrl = "";
+ for (var i = 1; i < option.cols[0].length - 1; i++) {
+ colName += option.cols[0][i]["title"] + ",";
+ }
+ var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
+ var urlLen = urlStr.split('/');
+ for (var i = 0; i < urlLen.length - 4; i++) {
+ contentUrl += "../";
+ }
+ colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
+
+ contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+
+ layer.open({
+ type: 2
+ , skin: "layui-layer-rim" //鍔犱笂杈规
+ , title: "闅愯棌鍒楄缃�" //鏍囬
+ , closeBtn: 1 //绐椾綋鍙充笂瑙掑叧闂� 鐨� 鏍峰紡
+ , shift: 2 //寮瑰嚭鍔ㄧ敾
+ , area: ["50%", "90%"] //绐椾綋澶у皬
+ , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
+ , content: [contentUrl, "yes"]
+ , btn: ["纭畾", "鍙栨秷"]
+ , btn1: function (index, laero) {
+ //鍒锋柊琛ㄦ牸鏁版嵁
+ DisPlay_HideColumn();
+ //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹�
+ layer.close(index);//鍏抽棴寮圭獥
+ }
+ })
+ }
+
+ //鏄剧ず鍒楁暟鎹�
+ function DisPlay_HideColumn() {
+ $.ajax({
+ url: GetWEBURL() + '/Xt_grdAlignment_WMES/grdAlignmentWMESList',
+ type: "GET",
+ data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
+ success: function (data1) {
+ if (data1.data.length != 0) {
+
+
+ var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
+ var titleData = ["hmainid", "HBillType", "HSupID", "涓氬姟鐘舵��", "HUnitID", "渚涘簲鍟嗕唬鐮�", "涓氬姟鍛樹唬鐮�", "HPriority", "HPSStyleID", "HSSID", "HCurID", "HDeptID", "HManagerID", "HEmpID", "hsubid","HMaterID"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
+
+ dataCol = data1.data[0].HGridString.split(',');
+
+ for (var i = 0; i < option.cols[0].length - 2; i++) {
+ var dataCols = dataCol[i].split('|');
+ //闅愯棌鍒�
+ if (dataCols[1] == 1) {
+ option.cols[0][i + 1]["hide"] = true;
+ }
+ //璁剧疆鍒楀
+ if (dataCols[3] > 0) {
+ option.cols[0][i + 1]["width"] = dataCols[3];
+ }
+ //璁剧疆鍐呭瀛椾綋澶у皬
+ if (data1.data[0].HFontSize != 0) {
+ option.cols[0][i + 1]["style"] = "font-size:" + data1.data[0].HFontSize + "px;";
+ } else {
+ option.cols[0][i + 1]["style"] = "font-size:100%";
+ }
+ //璁剧疆鍒楀
+ //if (data1.data[0].HColumnWidth != 0) {
+ // option.cols[0][i + 1]["width"] = data1.data[0].HColumnWidth + "px;";
+ //} else {
+ // option.cols[0][i + 1]["width"] = "";
+ //}
+ //鏄剧ず鍒�
+ if (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ switch (dataCols[2]) {
+ case "L":
+ option.cols[0][i + 1]["align"] = "left";
+ break;
+ case "M":
+ option.cols[0][i + 1]["align"] = "center";
+ break;
+ case "R":
+ option.cols[0][i + 1]["align"] = "right";
+ break;
+ }
+ }
+
+ //鍙栨秷鍐荤粨鍒�
+ for (var i = 1; i < option.cols[0].length - 1; i++) {
+ if (option.cols[0][i]["fixed"] != null) {
+ option.cols[0][i]["fixed"] = null;
+ }
+ else {
+ break;
+ }
+ }
+ //鍐荤粨鍒�
+ if (data1.data[0].HFixCols != 0) {
+ for (var i = 0; i < data1.data[0].HFixCols; i++) {
+ if ($.inArray(option.cols[0][i + 1]["title"], titleData) != -1) {
+ data1.data[0].HFixCols += 1;
+ }
+ option.cols[0][i + 1]["fixed"] = "left";
+ }
+ }
+ table.render(option);
+ } else {
+ table.render(option);
+ }
+
+ var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
+ var HBillType = "1601";
+ Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ })
+ }
//浠ヤ笂鏄痩ayui妯″潡
});
</script>
--
Gitblit v1.9.1