From 1ff5be719330df6ccbd9c00538c4258055d47cc6 Mon Sep 17 00:00:00 2001
From: zrg <z18737863051@163.com>
Date: 星期二, 24 十二月 2024 17:16:14 +0800
Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-LayUI
---
WebTM/views/车间管理/报表分析/Mes_OrderProcFlowAllReport.html | 140
WebTM/views/生产管理/要料计划/JIT_NeedMaterPlanBillList.html | 144 +
WebTM/views/基础资料/生产基础资料/Gy_Process.html | 140 +
WebTM/views/基础资料/通用基础资料/Gy_GeneralLookDown.html | 151 +
WebTM/views/基础资料/生产基础资料/Gy_Source.html | 140 +
WebTM/views/采购管理/应付单/Cg_PayableBillList.html | 33
WebTM/views/生产管理/日计划报表/ReportMOMaterReadysBillList.html | 361 ++++
WebTM/views/基础资料/工资基础资料/Gy_Group.html | 175 +-
WebTM/views/生产管理/生产计划平台/JIT_DayPlanPlatForm_TK.html | 168 +-
WebTM/views/生产管理/报工台工序/不良采集/Sc_QualityReportStepBillList_New.html | 135
WebTM/views/车间管理/关键件绑定/Sc_KeyElementBindingList.html | 141 +
WebTM/views/生产管理/日计划基础资料/Gy_WorkWarehouseBillList.html | 139 +
WebTM/views/销售管理/发货通知单/Xs_SeOutStockBillList.html | 33
WebTM/views/项目管理/工作任务/PM_WorkTaskBillList.html | 197 ++
WebTM/layuiadmin/QueryScheme.js | 319 ++++
WebTM/views/生产管理/日计划基础资料/Cg_PODemandPlanConfigBillList.html | 152 +
WebTM/views/基础资料/通用基础资料/Gy_CommonBaseDataCheck.html | 228 +++
WebTM/views/车间管理/报表分析/Mes_OrderProcFlowAllReport_ICMO.html | 138
WebTM/views/采购管理/采购订单/Cg_POOrderBillList.html | 34
WebTM/views/生产管理/生产计划平台/JIT_DayPlanPlatForm.html | 143 +
WebTM/layuiadmin/SetColumn.js | 27
WebTM/views/工资管理/班组职员清单/Gy_GroupEmpBillList.html | 137
WebTM/views/生产管理/生产日计划工单/JIT_DayPlanBillList.html | 139 +
WebTM/views/销售管理/应收单/Xs_ReceivableBill.html | 97
WebTM/views/生产管理/齐套分析/JIT_CompleteDetailList.html | 137 +
WebTM/views/验收入库/外购入库/Kf_POStockInBillList.html | 34
WebTM/views/生产管理/生产投料单/Sc_PPBomBillList.html | 145
WebTM/views/计划管理/工艺路线/Gy_RoutingBill.html | 2
WebTM/views/生产管理/生产计划平台/Sc_ICMOSortBillList.html | 139 +
WebTM/layuiadmin/Scripts/webConfig.js | 2
WebTM/views/生产管理/生产任务单/Sc_ICMOBillList.html | 358 ----
WebTM/WebTM.csproj | 2
WebTM/views/基础资料/公用基础资料/Gy_WorkCenter.html | 138 +
WebTM/views/领料发货/销售出库/Kf_SellOutBillList.html | 38
34 files changed, 2,918 insertions(+), 1,588 deletions(-)
diff --git a/WebTM/WebTM.csproj b/WebTM/WebTM.csproj
index afd87e0..79fc92a 100644
--- a/WebTM/WebTM.csproj
+++ b/WebTM/WebTM.csproj
@@ -97,6 +97,7 @@
<Content Include="layuiadmin\ckou.js" />
<Content Include="layuiadmin\echarts.min.js" />
<Content Include="layuiadmin\grwebapp.js" />
+ <Content Include="layuiadmin\QueryScheme.js" />
<Content Include="layuiadmin\SetColumn.js" />
<Content Include="layuiadmin\modules\tableFilter2.js" />
<Content Include="layuiadmin\PlateBinding.js" />
@@ -445,6 +446,7 @@
<Content Include="views\鍩虹璧勬枡\鐢熶骇鍩虹璧勬枡\Gy_WorkShiftList.html" />
<Content Include="views\鍩虹璧勬枡\鐢熶骇鍩虹璧勬枡\Gy_WorkShiftEdit.html" />
<Content Include="views\鍩虹璧勬枡\閫氱敤鍩虹璧勬枡\Gy_CommonBaseData.html" />
+ <Content Include="views\鍩虹璧勬枡\閫氱敤鍩虹璧勬枡\Gy_CommonBaseDataCheck.html" />
<Content Include="views\鍩虹璧勬枡\閫氱敤鍩虹璧勬枡\Gy_GeneralLookDown.html" />
<Content Include="views\鍩虹璧勬枡\闅愯棌鍒楄缃甛Gy_GridView_Hide_New.html" />
<Content Include="views\宸ヨ祫绠$悊\瀹氶鐢宠\Pay_ProcPriceRequestBillCheckQuery.html" />
diff --git a/WebTM/layuiadmin/QueryScheme.js b/WebTM/layuiadmin/QueryScheme.js
new file mode 100644
index 0000000..5de7b7c
--- /dev/null
+++ b/WebTM/layuiadmin/QueryScheme.js
@@ -0,0 +1,319 @@
+锘�//楂樼骇杩囨护 HTableName鏄繖涓垪琛ㄧ殑瑙嗗浘鍚�
+function set_QueryCondition(option, HTableName, get_FastQuery) {
+ var colName = "";
+ var contentUrl = "";
+ for (var i = 0; i < option.cols[0].length; i++) {
+ if (option.cols[0][i]["field"] != undefined && option.cols[0][i]["hide"] != true) {
+ 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_QueryCondition.html?HModName=' + HTableName + '&colName=' + colName;
+
+ layer.open({
+ type: 2
+ , skin: "layui-layer-rim" //鍔犱笂杈规
+ , title: "楂樼骇杩囨护" //鏍囬
+ , closeBtn: 1 //绐椾綋鍙充笂瑙掑叧闂� 鐨� 鏍峰紡
+ , shift: 2 //寮瑰嚭鍔ㄧ敾
+ , area: ["50%", "80%"] //绐椾綋澶у皬
+ , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
+ , content: [contentUrl, "yes"]
+ , btn: ["纭畾", "鍙栨秷"]
+ , btn1: function (index, laero) {
+ var iframeWindow = window["layui-layer-iframe" + index];//鑾峰彇寮规椤甸潰
+ var checkStatus = iframeWindow.layui.table.cache["mainTable"];//鑾峰彇閫変腑鐨勬暟鎹�
+ if (checkStatus.length == 0) {
+ return layer.msg("璇疯緭鍏ヨ繃婊ゆ潯浠�!");
+ }
+ var myIframe = window[laero.find('iframe')[0]['name']];
+ GetDataCols += "and (";
+ for (var i = 0; i < checkStatus.length; i++) {
+ GetDataCols += myIframe.get_FastQuery(checkStatus[i]); //get_FastQuery()涓哄瓙椤甸潰鐨勬柟娉�
+ if ((i + 1) < checkStatus.length) {
+ GetDataCols += " " + checkStatus[i]["HRelationCol"] + " ";
+ }
+ }
+ GetDataCols += ")";
+ //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹�
+ layer.close(index);//鍏抽棴寮圭獥
+ }
+ , end: function () {
+ if (GetDataCols != "") {
+ get_FastQuery();
+ }
+ }
+ })
+}
+
+//#region 銆愯繃婊ゆ柟妗堛��
+
+//鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
+function get_DefaultModule(get_FastQuery) {
+ $.ajax({
+ url: GetWEBURL() + '/Xt_FastICScheme/Chooselist',
+ type: "GET",
+ async: false,
+ data: { "user": sessionStorage["Czybm"], "HModuleName": HModuleName, "HInterID": 0, "Type": "Default" },
+ success: function (data1) {
+ if (data1.count == 1) {
+ //褰撳墠鐢ㄦ埛璁剧疆鏈夐粯璁ょ殑杩囨护鏂规
+ var data = data1.data;
+ //褰撳墠閫夋嫨鐨勮繃婊ゆ柟妗�
+ HInterID_Choose = data[0].hmainid;
+ //杩囨护鏂规鍐呯爜
+ HInterID = data[0].hmainid
+ //杩囨护鏂规鍚嶇О
+ HDefaultFilter = data[0].鏂规鍚嶇О
+ //杩囨护鏂规鐨勫娉紙鏂规淇℃伅鎻忚堪锛�
+ var HRemark = data[0].澶囨敞
+ //鏄剧ず鍑哄綋鍓嶇殑榛樿杩囨护鏂规
+ document.getElementById("HFilterScheme_Now").style.display = "block";
+ document.getElementById('HFilterScheme_Now').innerHTML = "褰撳墠杩囨护鏂规锛�" + HDefaultFilter + '<span style="font-size: 15px; font-weight: bold; color:#7b90fb"> ' + "(" + HRemark + ")" + '</span>';
+ //鎶婅繃婊ゆ潯浠跺�煎洖鍐欏埌椤甸潰涓�
+ for (let i = 0; i < data.length; i++) {
+ $("#" + data[i].杩囨护瀛楁ID).val(data[i].杩囨护鍊�);
+ if (data[i].杩囨护鏍囩绫诲瀷 == 'SELECT') {
+ $("#" + data[i].杩囨护瀛楁ID).find("option[value='" + data[i].杩囨护鍊� + "']").attr("selected", true);
+ }
+ }
+
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ if (HInitTimeCycle != -1) {
+ //$('#HDate').prop('disabled', true);
+ //$('#HDate1').prop('disabled', true);
+
+ $("#HDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HDate1").val(Format(new Date(), "yyyy-MM-dd"));
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ //$('#HDate').prop('disabled', false);
+ //$('#HDate1').prop('disabled', false);
+ }
+
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery()
+ //form.render("select");
+ } else {
+ //褰撳墠鐢ㄦ埛娌℃湁璁剧疆榛樿鐨勮繃婊ゆ柟妗�
+ //闅愯棌鏄剧ず杩囨护鏂规鐨勬爣绛句俊鎭�
+ document.getElementById("HFilterScheme_Now").style.display = "none";
+ //鎵ц鏌ヨ鏂规硶
+ //get_FastQuery()
+ //form.render("select");
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+}
+
+//淇濆瓨鏂规
+function set_SaveScheme(get_FastQuery) {
+ var index = layer.open()
+ //鍒ゆ柇鐢ㄦ埛鏄惁鐐瑰嚮浜嗗彸涓婅鐨勨�滃弶鍙封�濆叧闂脊绐楅〉闈�
+ var HIsClose_Manual = false;
+ //鑾峰彇鏈〉鎵�鏈夎繃婊ゆ潯浠跺璞�(class涓寘鍚�"ForFilteringSchemes"鐨勫厓绱�)
+ var Filter = document.getElementsByClassName(HClassTag);
+
+ var HFilterIdList = "";//杩囨护鏉′欢
+ var HFilterIdLists = "";//鎷兼帴澶氫釜杩囨护鏉′欢
+ var HValue = "";//杩囨护鍊�
+ var HElement_type = "";//杩囨护鏍囩绫诲瀷
+
+ for (var i = 0; i < Filter.length; i++) {
+ HFilterIdList = Filter[i].id; //杩囨护鏉′欢ID
+ HFilterIdLists += Filter[i].id + ","; //杩囨护鏉′欢ID(鎷兼帴)
+ HValue += $("#" + HFilterIdList).val() + ","; //杩囨护鏉′欢涓緭鍏ョ殑鍊�
+ HElement_type += document.getElementById(HFilterIdList).tagName + ",";//閫氳繃鏍囩id鑾峰彇鏍囩绫诲瀷
+ }
+
+ //鍘婚櫎鏈熬閫楀彿
+ HFilterIdLists = HFilterIdLists.substring(0, HFilterIdLists.length - 1);
+ HValue = HValue.substring(0, HValue.length - 1);
+ HElement_type = HElement_type.substring(0, HElement_type.length - 1);
+
+ //褰撳墠椤甸潰涓婃病鏈夐�夋嫨杩囨护鏂规锛岃繘鍏ユ柊澧炴柟娉�
+ if (HDefaultFilter == "") {
+ layer.open({
+ type: 2
+ , area: ['40%', '80%']
+ , title: '杩囨护鏂规'
+ , shift: 0//寮瑰嚭鍔ㄧ敾
+ , content: '../../绯荤粺绠$悊/杩囨护鏂规璁剧疆/Xt_FastICScheme.html?OperationType=1&HModuleName=' + HModuleName + '&HFilterIdLists=' + HFilterIdLists + '&HValue=' + HValue + '&HElement_type=' + HElement_type
+ , cancel: function () {
+ // 鍙充笂瑙掑叧闂簨浠剁殑閫昏緫
+ HIsClose_Manual = true;
+ }
+ , end: function () {
+ if (HIsClose_Manual != true) {
+ get_FastQuery();
+ //鏄剧ず褰撳墠鐨勮繃婊ゆ柟妗�
+ document.getElementById("HFilterScheme_Now").style.display = "block";
+ document.getElementById('HFilterScheme_Now').innerHTML = "褰撳墠杩囨护鏂规锛�" + sessionStorage["HFilterSchemeName_" + sessionStorage["Czybm"]] + '<span style="font-size: 15px; font-weight: bold; color:#7b90fb"> ' + "(" + sessionStorage["HFilterSchemeRemark_" + sessionStorage["Czybm"]] + ")" + '</span>';
+ }
+ }
+ })
+ layer.close(index)
+ } else {
+ //褰撳墠椤甸潰宸叉湁杩囨护鏂规锛岀敤鎴烽�夋嫨 鏂板鎴栬�呯紪杈�
+ layer.confirm('褰撳墠宸查�夋嫨杩囨护鏂规锛屾槸鍚︿慨鏀癸紵璇烽�夋嫨瀵瑰簲鎿嶄綔', {
+ title: "鎿嶄綔鎻愮ず",
+ icon: 0,
+ btn: ['鏂板鏂规', '淇濆瓨淇敼褰撳墠鏂规', '鍙栨秷']
+ }, function (index, layero) {
+ //鏂板
+ layer.open({
+ type: 2
+ , area: ['40%', '80%']
+ , title: '杩囨护鏂规'
+ , shift: 0//寮瑰嚭鍔ㄧ敾
+ , content: '../../绯荤粺绠$悊/杩囨护鏂规璁剧疆/Xt_FastICScheme.html?OperationType=1&HModuleName=' + HModuleName + '&HFilterIdLists=' + HFilterIdLists + '&HValue=' + HValue + '&HElement_type=' + HElement_type
+ , end: function () {
+ get_FastQuery()
+ //鏄剧ず褰撳墠鐨勮繃婊ゆ柟妗�
+ document.getElementById("HFilterScheme_Now").style.display = "block";
+ document.getElementById('HFilterScheme_Now').innerHTML = "褰撳墠杩囨护鏂规锛�" + sessionStorage["HFilterSchemeName_" + sessionStorage["Czybm"]] + '<span style="font-size: 15px; font-weight: bold; color:#7b90fb"> ' + "(" + sessionStorage["HFilterSchemeRemark_" + sessionStorage["Czybm"]] + ")" + '</span>';
+ }
+ })
+ layer.close(index)
+ }, function (index) {
+ //缂栬緫
+ var Filter_Edit = document.getElementsByClassName(HClassTag); //鑾峰彇鏈〉鎵�鏈夎繃婊ゆ潯浠跺璞�(class涓寘鍚�"ForFilteringSchemes"鐨勫厓绱�)
+ HFilterIdList = "";
+ HFilterIdLists = "";
+ HValue = "";
+ HElement_type = "";
+ for (var i = 0; i < Filter_Edit.length; i++) {
+ HFilterIdList = Filter_Edit[i].id; //杩囨护鏉′欢ID
+ HFilterIdLists += Filter_Edit[i].id + ","; //杩囨护鏉′欢ID(鎷兼帴)
+ HValue += $("#" + HFilterIdList).val() + ","; //杩囨护鏉′欢涓緭鍏ョ殑鍊�
+ HElement_type += document.getElementById(HFilterIdList).tagName + ",";//閫氳繃鏍囩id鑾峰彇鏍囩绫诲瀷
+ }
+ //鍘婚櫎鏈熬閫楀彿
+ HFilterIdLists = HFilterIdLists.substring(0, HFilterIdLists.length - 1);
+ HValue = HValue.substring(0, HValue.length - 1);
+ HElement_type = HElement_type.substring(0, HElement_type.length - 1);
+
+ var sMainSub = HInterID_Choose + ';' + HFilterIdLists + ';' + HValue + ';' + HElement_type + ';' + sessionStorage["Czybm"] + ';' + 3;
+
+ //淇敼
+ $.ajax({
+ type: "POST",
+ url: GetWEBURL() + "/Xt_FastICScheme/save", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ async: true,
+ data: { "oMain": sMainSub },
+ dataType: "json",
+ success: function (data) {
+ if (data.count == 1) { // 璇存槑楠岃瘉鎴愬姛浜嗭紝
+ layer.msg(data.Message, { time: 1 * 1000, icon: 1 });
+ }
+ else {
+
+ }
+ layer.closeAll("loading");
+ },
+ error: function (err) {
+
+
+ }
+ });
+ layer.close(index)
+ }, function (index) {
+ //鍙栨秷
+ layer.alert('鍙栨秷')
+ layer.close(index)
+ });
+ }
+
+}
+
+//璇诲彇鏂规
+function set_ReadScheme(get_FastQuery) {
+ var HIsClose_Manual = false;
+ var Filter = document.getElementsByClassName(HClassTag); //鑾峰彇鏈〉鎵�鏈夎繃婊ゆ潯浠跺璞�(class涓寘鍚�"ForFilteringSchemes"鐨勫厓绱�)
+
+ var HFilterIdList = "";
+ var HFilterIdLists = "";
+ var HValue = "";
+ var HElement_type = "";
+ for (var i = 0; i < Filter.length; i++) {
+ HFilterIdList = Filter[i].id; //杩囨护鏉′欢ID
+ HFilterIdLists += Filter[i].id + ","; //杩囨护鏉′欢ID(鎷兼帴)
+ HValue += $("#" + HFilterIdList).val() + ","; //杩囨护鏉′欢涓緭鍏ョ殑鍊�
+ HElement_type += document.getElementById(HFilterIdList).tagName + ",";//閫氳繃鏍囩id鑾峰彇鏍囩绫诲瀷
+ }
+ //鍘婚櫎鏈熬閫楀彿
+ HFilterIdLists = HFilterIdLists.substring(0, HFilterIdLists.length - 1);
+ HValue = HValue.substring(0, HValue.length - 1);
+ HElement_type = HElement_type.substring(0, HElement_type.length - 1);
+
+ layer.open({
+ type: 2
+ , area: ['80%', '80%']
+ , title: '杩囨护鏂规鍒楄〃'
+ , shift: 0//寮瑰嚭鍔ㄧ敾
+ , content: '../../绯荤粺绠$悊/杩囨护鏂规璁剧疆/Xt_FastICSchemeList.html?HType=Select&HFilterIdLists=' + HFilterIdLists + '&HValue=' + HValue + '&HElement_type=' + HElement_type + '&HModuleName=' + HModuleName
+ , cancel: function () {
+ // 鍙充笂瑙掑叧闂簨浠剁殑閫昏緫
+ HIsClose_Manual = true;
+ }
+ , end: function () {
+ if (HIsClose_Manual != true) {
+ get_FastQuery()
+ form.render("select");
+ }
+ }
+ })
+}
+//#region 銆愯繃婊ゆ柟妗堣繑鍥炴暟鎹��
+function HFilterScheme(obj) //杩斿洖杩囨护鏂规
+{
+ var HInterID = obj[0].hmainid;
+ HInterID_Choose = obj[0].hmainid;
+ $.ajax({
+ url: GetWEBURL() + '/Xt_FastICScheme/Chooselist',
+ type: "GET",
+ data: { "user": sessionStorage["Czybm"], "HModuleName": HModuleName, "HInterID": HInterID, "Type": "Select" },
+ success: function (data1) {
+ if (data1.count == 1) {
+ var data = data1.data;
+ //璧嬪�艰繃婊ゆ柟妗堝悕绉�
+ HDefaultFilter = data[0].鏂规鍚嶇О
+ var HRemark = data[0].澶囨敞
+ //鏄剧ず褰撳墠鐨勮繃婊ゆ柟妗�
+ document.getElementById("HFilterScheme_Now").style.display = "block";
+ document.getElementById('HFilterScheme_Now').innerHTML = "褰撳墠杩囨护鏂规锛�" + HDefaultFilter + '<span style="font-size: 15px; font-weight: bold; color:#7b90fb"> ' + "(" + HRemark + ")" + '</span>';
+ HInterID = data[0].hmainid
+ //鏍规嵁閫夋嫨鐨勮繃婊ゆ柟妗堝洖濉暟鎹埌鍒楄〃杩囨护鏉′欢
+ for (let i = 0; i < data.length; i++) {
+ $("#" + data[i].杩囨护瀛楁ID).val(data[i].杩囨护鍊�);
+ if (data[i].杩囨护鏍囩绫诲瀷 == 'SELECT') {
+ $("#" + data[i].杩囨护瀛楁ID).find("option[value='" + data[i].杩囨护鍊� + "']").attr("selected", true);
+ }
+ }
+
+ } else {
+ layer.close(ajaxLoad);
+ layer.alert(data1.code + data1.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.close(ajaxLoad);
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+}
+//#endregion
+
+//#endregion
+
diff --git a/WebTM/layuiadmin/Scripts/webConfig.js b/WebTM/layuiadmin/Scripts/webConfig.js
index 2b885ee..77bad55 100644
--- a/WebTM/layuiadmin/Scripts/webConfig.js
+++ b/WebTM/layuiadmin/Scripts/webConfig.js
@@ -9,7 +9,7 @@
var WEBURL = "http://localhost:8082/API/"; //寮犵憺骞挎湰鍦伴厤缃�
//var WEBURL = "http://localhost:81/API/" //缈佹稕娑涙湰鍦伴厤缃�
//var WEBURL = "http://47.96.97.237/API/"; //鏅轰簯鏈嶅姟鍣�
- /*var WEBURL = "http://localhost:8082/LuBaoAPI/"; */ //浣欐�濇澃鏈湴閰嶇疆
+ var WEBURL = "http://localhost:8082/LuBaoAPI/"; //浣欐�濇澃鏈湴閰嶇疆
//var WEBURL = "http://localhost:8088/ARAPI/"; //浣欐�濇澃鏈湴閰嶇疆(瀹夌憺)
//var WEBURL = "http://61.164.86.218:8099/ABAPI/"; //濂ラ偊
//var WEBURL = "http://10.1.4.155/API/"; //姹熶赴瀹㈡埛NEW
diff --git a/WebTM/layuiadmin/SetColumn.js b/WebTM/layuiadmin/SetColumn.js
index 876ec63..2c354f5 100644
--- a/WebTM/layuiadmin/SetColumn.js
+++ b/WebTM/layuiadmin/SetColumn.js
@@ -29,6 +29,33 @@
}
//#endregion
+//#region 闅愯棌鍒楄缃� 娌″垎椤垫彃浠�
+function get_HideColumnNoPage(HModName, user, option, get_Display) {
+ var colName = "";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
+ }
+
+ colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
+ layer.open({
+ type: 2
+ , skin: "layui-layer-rim" //鍔犱笂杈规
+ , title: "闅愯棌鍒楄缃�" //鏍囬
+ , closeBtn: 1 //绐椾綋鍙充笂瑙掑叧闂� 鐨� 鏍峰紡
+ , shift: 2 //寮瑰嚭鍔ㄧ敾
+ , area: ["50%", "90%"] //绐椾綋澶у皬
+ , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
+ , content: ['../../鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName, "yes"]
+ , btn: ["纭畾", "鍙栨秷"]
+ , btn1: function (index, laero) {
+ //鐩存帴鎵ц鍒楄〃绛涢�� 鍔犺浇鏁版嵁鍒扮綉鏍�
+ get_Display();
+ //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹�
+ layer.close(index);//鍏抽棴寮圭獥
+ }
+ })
+}
+//#endregion
//#region 璁剧疆琛ㄦ牸椤靛ぇ灏忓垵濮�
function DisPlay_HideColumn_GetPageSize(HModName, user,optionPage) {
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_WorkCenter.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_WorkCenter.html"
index 335d06f..8012cd9 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_WorkCenter.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_WorkCenter.html"
@@ -916,8 +916,8 @@
function get_HideColumn() {
var colName = "";
var contentUrl = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
}
var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
var urlLen = urlStr.split('/');
@@ -926,7 +926,7 @@
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+ contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName;
layer.open({
type: 2
@@ -955,68 +955,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- //var titleData = ["鍗曟嵁ID", "HMouldID", "hsubid", "HManagerID", "婧愬崟涓诲唴鐮�", "婧愬崟瀛愬唴鐮�"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
- var titleData = ["HItemID", "HUSEORGID"];
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\267\245\350\265\204\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Group.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\267\245\350\265\204\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Group.html"
index 118050d..43196b0 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\267\245\350\265\204\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Group.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\267\245\350\265\204\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Group.html"
@@ -374,24 +374,24 @@
}
//鏂囦欢涓婁紶
- upload.render({
- elem: '#UpLoad',
- url: GetWEBURL() + '/Gy_ProcPrice/Gy_ProcPrice_Excel',
- contentType: 'application/json',
- exts: 'xls|xlsx', //鍏佽涓婁紶鐨勭被鍨�
- done: function (data1) {
- if (data1.count == 1) {
- option.data = data1.data;
- table.render(option);
- } else {
- layer.alert(data1.code + data1.Message, { icon: 5 });
- }
- },
- error: function (err) {
- debugger
- layer.alert('瀵煎叆鍑虹幇寮傚父', { icon: 2 });
- }
- });
+ //upload.render({
+ // elem: '#UpLoad',
+ // url: GetWEBURL() + '/Gy_ProcPrice/Gy_ProcPrice_Excel',
+ // contentType: 'application/json',
+ // exts: 'xls|xlsx', //鍏佽涓婁紶鐨勭被鍨�
+ // done: function (data1) {
+ // if (data1.count == 1) {
+ // option.data = data1.data;
+ // table.render(option);
+ // } else {
+ // layer.alert(data1.code + data1.Message, { icon: 5 });
+ // }
+ // },
+ // error: function (err) {
+ // debugger
+ // layer.alert('瀵煎叆鍑虹幇寮傚父', { icon: 2 });
+ // }
+ //});
//#region 鍒濆鍖栬〃鏍兼柟娉�
function set_InitGrid() {
@@ -790,8 +790,8 @@
function get_HideColumn() {
var colName = "";
var contentUrl = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
}
var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
var urlLen = urlStr.split('/');
@@ -800,7 +800,7 @@
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+ contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName;
layer.open({
type: 2
@@ -904,69 +904,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- //var titleData = ["鍗曟嵁ID", "HMouldID", "hsubid", "HManagerID", "婧愬崟涓诲唴鐮�", "婧愬崟瀛愬唴鐮�"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
- //涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
- var titleData = ["HItemID", "HDeptID", "HUSEORGID"];
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\347\224\237\344\272\247\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Process.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\347\224\237\344\272\247\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Process.html"
index b345950..87c8864 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\347\224\237\344\272\247\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Process.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\347\224\237\344\272\247\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Process.html"
@@ -843,8 +843,8 @@
function get_HideColumn() {
var colName = "";
var contentUrl = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
}
var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
var urlLen = urlStr.split('/');
@@ -853,7 +853,7 @@
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+ contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName;
layer.open({
type: 2
@@ -882,70 +882,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- //var titleData = ["鍗曟嵁ID", "HMouldID", "hsubid", "HManagerID", "婧愬崟涓诲唴鐮�", "婧愬崟瀛愬唴鐮�"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
- var titleData = ["HItemID", "HProcessID_K3", "HUSEORGID"];
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
dataCol = data1.data[0].HGridString.split(',');
-
- for (var i = 0; i < option.cols[0].length - 2; i++) {
- if (dataCol[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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\347\224\237\344\272\247\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Source.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\347\224\237\344\272\247\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Source.html"
index 7ff32aa..1fbf2eb 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\347\224\237\344\272\247\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Source.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\347\224\237\344\272\247\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Source.html"
@@ -853,8 +853,8 @@
function get_HideColumn() {
var colName = "";
var contentUrl = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
}
var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
var urlLen = urlStr.split('/');
@@ -863,7 +863,7 @@
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+ contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName;
layer.open({
type: 2
@@ -967,70 +967,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- //var titleData = ["鍗曟嵁ID", "HMouldID", "hsubid", "HManagerID", "婧愬崟涓诲唴鐮�", "婧愬崟瀛愬唴鐮�"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
- var titleData = ["HItemID", "Hprocid", "HUSEORGID"];
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
dataCol = data1.data[0].HGridString.split(',');
-
- for (var i = 0; i < option.cols[0].length - 2; i++) {
- if (dataCol[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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\200\232\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_CommonBaseDataCheck.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\200\232\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_CommonBaseDataCheck.html"
new file mode 100644
index 0000000..c186823
--- /dev/null
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\200\232\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_CommonBaseDataCheck.html"
@@ -0,0 +1,228 @@
+锘�<!DOCTYPE html>
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <meta http-equiv="Content-Type" content="text/html; 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, maximum-scale=1">
+ <link rel="stylesheet" href="../../../layuiadmin/layui/css/layui.css" media="all">
+ <link rel="stylesheet" href="../../../layuiadmin/style/admin.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/Scripts/webConfig.js"></script>
+ <script src="../../../layuiadmin/PubCustom.js"></script>
+ <script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
+ <script src="../../../layuiadmin/HideButton.js"></script>
+
+ <style>
+ /* 褰撻紶鏍囨偓娴湪琛ㄦ牸鐨勫鏁拌涓婃椂鏀瑰彉鑳屾櫙鑹� */
+ .layui-table tbody tr:nth-child(odd):hover {
+ background-color: #ceedfa; /* 鏇存敼涓轰綘鎯宠鐨勯鑹� */
+ }
+
+ /* 褰撻紶鏍囨偓娴湪琛ㄦ牸鐨勫伓鏁拌涓婃椂鏀瑰彉鑳屾櫙鑹� */
+ .layui-table tbody tr:nth-child(even):hover {
+ background-color: #ceedfa; /* 鏇存敼涓轰綘鎯宠鐨勯鑹� */
+ }
+ </style>
+
+</head>
+<body>
+ <div class="layui-fluid">
+ <div class="layui-col-md12">
+ <div class="layui-card" style="padding: 1px">
+ <div class="layui-card-body" style="padding: 1px;">
+ <form class="layui-form" action="" lay-filter="component-form-group">
+ <!--<div class="layui-collapse">
+ <div class="layui-colla-item">-->
+ <!--<div class="layui-colla-title layui-inline">
+ </div>-->
+ <!--</div>
+ </div>-->
+ <table class="" id="mainTable" lay-filter="mainTable"></table>
+ </form>
+ </div>
+ </div>
+ </div>
+ </div>
+ <script>
+
+
+ layui.config({
+ base: '../../../layuiadmin/' //闈欐�佽祫婧愭墍鍦ㄨ矾寰�
+ }).extend({
+ index: 'lib/index', //涓诲叆鍙fā鍧�
+ }).use(['index', 'form', 'table', 'element', 'laypage', 'laydate'], function () {
+ //#region 鍏敤鍙橀噺
+ var $ = layui.$
+ , admin = layui.admin
+ , layer = layui.layer
+ , table = layui.table
+ , form = layui.form
+ , element = layui.element
+ , laypage = layui.laypage
+ , laydate = layui.laydate
+
+ var option = [];
+ var sWhere = "";
+ //#endregion
+
+ //#region 瑙﹀彂浜嬩欢
+ //#region 鐐瑰嚮杩斿洖琛岀殑鏁版嵁
+ table.on('RowDouble(mainTable)', function (obj) {
+ parent.childData = obj.data;
+ var index = parent.layer.getFrameIndex(window.name);
+ parent.layer.close(index);
+ })
+ //#endregion
+ //#endregion
+
+ //#region 鏈〉闈㈡墍鏈夎璋冪敤鐨勬柟娉�
+ //#region 鍒濆鍖栫晫闈�
+ function set_ClearBill(sql,tableView) {
+ //鍒濆鍖栬〃鏍�
+ set_InitGrid();
+ //鏌ヨ
+ get_Display(sql, tableView);
+ }
+ //#endregion
+
+ //#region 鍒濆鍖栬〃鏍兼柟娉�
+ function set_InitGrid() {
+ option = {
+ elem: '#mainTable'
+ //, toolbar: '#toolbarDemo'
+ , height: 'full-50'
+ , cellMinWidth: 90
+ //, page: true
+ , limit: 10
+ , limits: [5, 10, 15, 20]
+ //, totalRow: true
+ , cols: [[
+ { field: '浠g爜', title: '浠g爜', width: 150, sort: true }
+ , { field: '鍚嶇О', title: '鍚嶇О', width: 150, sort: true }
+ ]]
+ , data: []
+ , done: function (res, curr, count) {
+ // 璁剧疆琛屾牱寮�
+ var style = 'background-color: #ceedfa;'; // 鎸囧畾鐨勮儗鏅壊
+ // 鍋囪鎴戜滑瑕佽缃涓夎鐨勮儗鏅壊
+ var targetIndex = rowIndex; // 琛屽彿绱㈠紩锛屼粠0寮�濮嬭鏁�
+ $('tr[data-index=' + targetIndex + ']').attr('style', style);
+
+
+ //璁剧疆婊氬姩鏉′綅缃�
+ if (option.data.length > 0) {
+ // 琛ㄦ牸娓叉煋瀹屾瘯鍚庣殑鍥炶皟
+ var parentObject = document.getElementById('mainTable').nextElementSibling.childNodes[0].childNodes[1].childNodes[0].childNodes[0];
+ if (parentObject.childNodes.length > 0) {
+ var rowObject = parentObject.childNodes[0];
+ var rowHeight = rowObject.offsetHeight; // 鑾峰彇琛岄珮
+ var rowPosition = rowHeight * rowIndex;
+ $('.layui-table-body').scrollTop(rowPosition);
+ }
+ }
+ }
+ };
+ }
+ //#endregion
+
+ //#region 鏌ヨ
+ function get_Display(sql, tableView) {
+ $.ajax({
+ url: GetWEBURL() + '/Gy_GetBaseData/Gy_GetBaseData',
+ type: "GET",
+ data: { "sql": sql, "tableView": tableView, "user": sessionStorage["HUserName"] },
+ success: function (data1) {
+ if (data1.count == 1) {
+ var data = [];
+ var col = [];
+ //缁欑┖鐨勬暟缁勮祴鍊�
+ for (var key in data1.list) {
+ data.push({ "id": data1.list[key].ColmCols, "name": data1.list[key].ColmCols, "Type": data1.list[key].ColmType });
+ }
+ //鍒ゆ柇鏄惁鏄函鑻辨枃
+ var patrn = new RegExp("[\u4E00-\u9FA5]+");
+ //鍦ㄥ垪琛ㄥ乏杈规坊鍔犲嬀閫夋
+ col.push({ type: 'checkbox', fixed: 'left' });
+ for (var i = 0; i < data.length; i++) {
+ if (!patrn.test(data[i].name)) {
+ col.push({ field: data[i].name, title: data[i].name, hide: true }); //闅愯棌鍒�
+ }
+ else {
+ switch (data[i].Type) {
+ case 'DateTime':
+ 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 });
+ }
+ }
+ }
+
+
+ option.cols = [col];
+ option.data = data1.data;
+ table.render(option);
+ } else {
+ layer.alert(data1.code + data1.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ //#endregion
+ //#endregion
+
+
+ //#region 涓簑indow瀵硅薄澹版槑骞跺畾涔塯etData鏂规硶锛岀敤浜庨�氳繃window瀵硅薄璋冪敤layui.use鍐呴儴瀹氫箟鐨勬柟娉�
+ //#region 鏍规嵁鐖堕〉闈紶閫掔殑鍙傛暟锛屾煡璇㈡暟鎹苟娓叉煋琛ㄦ牸
+ window.getData = function (sql,tableView) {
+ set_ClearBill(sql, tableView);
+ }
+ //#endregion
+
+ //#region 鏍规嵁鐖堕〉闈紶閫掔殑绱㈠紩锛屾覆鏌撹鑳屾櫙锛屽疄鐜伴�変腑鍔熻兘
+ window.setSelectedRow = function (currRowIndex) {
+ rowIndex += currRowIndex;
+ if (rowIndex >= option.data.length) {
+ rowIndex = option.data.length - 1;
+ parent.currRowIndex = rowIndex + 1;
+ } else if (rowIndex < -1) {
+ rowIndex = -1;
+ parent.currRowIndex = rowIndex + 1;
+ }
+ table.render(option);
+ rowIndex = -1;
+ }
+ //#endregion
+
+ //#region 鏍规嵁鐖堕〉闈紶閫掔殑绱㈠紩锛岃繑鍥為�変腑琛屾暟鎹埌鐖堕〉闈�
+ window.getSelectedData = function (currRowIndex) {
+ parent.childData = option.data[currRowIndex - 1];
+
+ var index = parent.layer.getFrameIndex(window.name);
+ parent.layer.close(index);
+ }
+ //#endregion
+
+ //#endregion
+ });
+
+ //#endregion
+ //浠ヤ笂鏄痩ayui妯″潡
+
+
+
+
+ //#region 鏂囨湰妗嗚緭鍏ユ悳绱㈢浉鍏虫暟鎹�-鍙橀噺
+ parent.childPage = window; //瀛愮獥鍙e璞� 璧嬬粰 鐖剁獥鍙�
+ var rowIndex = -1; //鐢ㄤ簬瀹氫綅 褰撳墠閫変腑鐨勬暟鎹殑浣嶇疆
+ //#endregion
+ </script>
+
+</body>
+</html>
\ No newline at end of file
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\200\232\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_GeneralLookDown.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\200\232\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_GeneralLookDown.html"
index 43e74b6..91517aa 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\200\232\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_GeneralLookDown.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\200\232\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_GeneralLookDown.html"
@@ -11,6 +11,8 @@
<script src="../../../layuiadmin/Scripts/jquery-1.4.1.js"></script>
<script src="../../../layuiadmin/Scripts/webConfig.js"></script>
<script src="../../../layuiadmin/PubCustom.js"></script>
+ <script src="../../../layuiadmin/SetColumn.js"></script>
+ <script src="../../../layuiadmin/PageTitle.js"></script>
</head>
<body>
<div class="layui-fluid" style="padding: 0;">
@@ -53,9 +55,18 @@
//鑾峰彇鍙傛暟
var params = getUrlVars();
- var linterid = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 婧愬崟鍗曟嵁鍐呯爜
+ var HInterID = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 婧愬崟鍗曟嵁鍐呯爜
var HModName = params[params[1]]; //浠庡弬鏁颁腑鑾峰彇鍒楄缃甿odname
- var url = "";
+ var HEntryID = params[params[2]]; //浠庡弬鏁颁腑鑾峰彇 婧愬崟瀛愬唴鐮佹殏鏃舵棤鐢�
+ var url = ""; //ajax鍦板潃
+ var content = ""; //缂栬緫椤甸潰鍦板潃
+ var ajaxData = {}; //ajax鎺ュ彛浼犺緭鏁版嵁
+ //#region 銆愬姩鎬佽幏鍙栨ā鍧楀悕绉般��
+ var HModuleType = "";
+ //閫氳繃鍗曟嵁绫诲瀷锛屼粠鏁版嵁搴撳姩鎬佽幏鍙栧崟鎹ā鍧楀懡鍚�,寮曠敤js鏂囦欢 PageTitle.js
+ var HPageTitle = "";
+ //#endregion
+
//#endregion
//#region 杩涘叆椤甸潰鍗冲姞杞�
@@ -80,11 +91,42 @@
switch (obj.event) {
//鍒楄缃�
case 'set_HideColumn':
- get_HideColumn();
+ get_HideColumnNoPage(HModName, sessionStorage["HUserName"], option, get_Display);
break;
}
});
//#endregion
+
+ //#region 鐩戝惉缃戞牸琛ㄤ綋浜嬩欢
+ table.on('tool(mainTable)', function (obj) {
+ var data = obj.data;
+
+ //鍗曟嵁鍙疯秴閾炬帴
+ if (obj.event == '鍗曟嵁鍙�') { //妫�鏌� obj.event 鏄惁绛変簬瀛楃涓� '鍗曟嵁鍙�'銆傚鏋滅瓑浜庯紝鍒欐墽琛宨f寰幆
+ var linterid = data.hmainid.toString(); //澹版槑鍙橀噺linterid 涓� data.hmainid
+ //if (AllowLoadData(sSubStr) != false) {//闈炵┖楠岃瘉
+ layer.open({ //浣跨敤 layer鐨刼pen鎵撳紑寮瑰嚭 灞�
+ type: 2 //琛ㄧず寮瑰嚭灞傜殑鍐呭鏄竴涓� iframe
+ , area: ['100%', '100%']
+ , title: '缂栬緫' + HPageTitle //璁剧疆寮瑰嚭灞傜殑鍚嶅瓧鍜屽彉閲�
+ , closeBtn: 1//鏄剧ず鍏抽棴鎸夐挳
+ , shade: 0.6 //閬僵閫忔槑搴�
+ , maxmin: true //鍏佽鍏ㄥ睆鏈�灏忓寲
+ , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
+ , content: content+'?OperationType=3&linterid=' + linterid + '&HSouceBillType=0&closeType=1' //璁剧疆 iframe 鐨� URL锛孶RL 涓寘鍚簡鏌ヨ鍙傛暟锛屾潵璋冪敤鎵�闇�瑕佺殑鍊�
+
+ , resize: false, //鏄惁鍏佽鐢ㄦ埛璋冩暣寮瑰嚭澶у皬
+ end: function () { //褰撳叧闂椂璋冪敤
+ get_FastQuery();
+ }
+ , cancel: function () { //鐐瑰嚮鍙栨秷鏃朵娇鐢ㄥ洖璋�
+ //$(".layui-btn").removeClass("layui-btn-disabled");
+ }
+ })
+ }
+ });
+ //#endregion
+
//#endregion
@@ -92,7 +134,10 @@
//#region 鍒濆鍖栫晫闈�
function set_ClearBill()
{
+ set_url();
+ //鍒濆鍖栬〃鏍�
set_InitGrid();
+ //鏌ヨ
get_Display();
}
//#endregion
@@ -103,8 +148,8 @@
option ={
elem: '#mainTable'
, toolbar: '#toolbarDemo'
- , height: 550
- //, page: true
+ , height: 'full-120'
+ , page: false
, cellMinWidth: 90
, limit: Number.MAX_VALUE
//, limits: [50, 500, 5000, 20000]
@@ -112,10 +157,38 @@
}
//#endregion
- //#region 鏍规嵁modname璁剧疆url
- function set_url(modname) {
- if (modname == "") {
-
+ //#region 鏍规嵁modname璁剧疆url鍜宎jaxdata
+ function set_url() {
+ if (HModName == "Kf_SellOutBillList") {//閿�鍞嚭搴�
+ url = '/Kf_SellOutBill/GetSellOutBillList_byPage';
+ ajaxData = { "sWhere": "and HSourceInterID=" + HInterID, "user": sessionStorage["HUserName"], "Organization": sessionStorage["Organization"], "page": 1, "size": 1000 };
+ HModuleType = "1205";
+ content = "../../棰嗘枡鍙戣揣/閿�鍞嚭搴�/Kf_SellOutBill.html";//缂栬緫鍦板潃
+ HPageTitle = get_PageTitle(HModuleType) == "" ? document.title : get_PageTitle(HModuleType);
+ } else if (HModName == "Xs_ReceivableBillList") {//搴旀敹鍗�
+ url = '/Xs_ReceivableBill/list_byPage';
+ ajaxData = { "sWhere": "and HSourceInterID=" + HInterID, "user": sessionStorage["HUserName"], "Organization": sessionStorage["Organization"], "page": 1, "size": 1000 };
+ HModuleType = "1426";
+ content = "../../閿�鍞鐞�/搴旀敹鍗�/Xs_ReceivableBill.html";//缂栬緫鍦板潃
+ HPageTitle = get_PageTitle(HModuleType) == "" ? document.title : get_PageTitle(HModuleType);
+ } else if (HModName == "Kf_POStockInBillList") {//閲囪喘鍏ュ簱鍗�
+ url = '/Kf_POStockInBill/page';
+ ajaxData = { "sWhere": "and 婧愬崟涓诲唴鐮�=" + HInterID, "user": sessionStorage["HUserName"],"page": 1, "size": 1000 };
+ HModuleType = "1201";
+ content = "../../楠屾敹鍏ュ簱/澶栬喘鍏ュ簱/Add_Edit_Kf_POStockInBillList.html";//缂栬緫鍦板潃
+ HPageTitle = get_PageTitle(HModuleType) == "" ? document.title : get_PageTitle(HModuleType);
+ } else if (HModName == "Cg_PayableBillList") {//搴斾粯鍗�
+ url = '/Cg_PayableBill/page';
+ ajaxData = { "sWhere": "and HSourceInterID=" + HInterID, "user": sessionStorage["HUserName"], "page": 1, "size": 1000 };
+ HModuleType = "1114";
+ content = "../../閲囪喘绠$悊/搴斾粯鍗�/Cg_PayableBill.html";//缂栬緫鍦板潃
+ HPageTitle = get_PageTitle(HModuleType) == "" ? document.title : get_PageTitle(HModuleType);
+ } else if (HModName == "YF_PayMentBillList") {//搴斾粯鍗�
+ url = '/YF_PayMentBill/page';
+ ajaxData = { "sWhere": "and 婧愬崟涓诲唴鐮�=" + HInterID, "user": sessionStorage["HUserName"], "page": 1, "size": 1000 };
+ HModuleType = "2103";
+ content = "../../閲囪喘绠$悊/浠樻鍗�/YF_PayMentBill.html";//缂栬緫鍦板潃
+ HPageTitle = get_PageTitle(HModuleType) == "" ? document.title : get_PageTitle(HModuleType);
}
}
//#endregion
@@ -123,12 +196,66 @@
//#region 鏌ヨ
function get_Display() {
var ajaxLoad = layer.load();
+ if (url == "") {
+ layer.alert("鏃犲搴旀帴鍙e湴鍧�", { icon: 5 });
+ layer.close(ajaxLoad);
+ return false;
+ }
$.ajax({
- url: GetWEBURL() + '/Kf_SellOutBill/SellOutBill_LookDown',
+ url: GetWEBURL() + url,
type: "GET",
- data: { "HInterID": linterid},
+ data: ajaxData,
success: function (data1) {
- if (data1.count == 1) {
+ if (data1.code == 1) {
+ var titleData = [];
+ var data = [];
+ var col = [];
+ //缁欑┖鐨勬暟缁勮祴鍊�
+ for (var key in data1.list) {
+ //鍔ㄦ�佽幏鍙栧垪琛ㄦ墍鏈夊垪鍚�
+ data.push({ "id": data1.list[key].ColmCols, "name": data1.list[key].ColmCols, "Type": data1.list[key].ColmType });
+ //鑾峰彇涓嶉渶瑕佹樉绀虹殑鍒楋紙H寮�澶寸殑鍒椾笉鏄剧ず锛�
+ var patrn = new RegExp(/^h/i);
+ if (patrn.test(data1.list[key].ColmCols)) {
+ titleData[key] = data1.list[key].ColmCols;
+ }
+ }
+ //鍦ㄥ垪琛ㄥ乏杈规坊鍔犲嬀閫夋
+ col.push({ type: 'checkbox', fixed: 'left', totalRowText: '鍚堣' });
+ for (var i = 0; i < data.length; i++) {
+ // if (data[i].name == 'HInterID' || data[i].name == 'HBillType' || data[i].name == 'hmainid') {
+ if ($.inArray(data[i].name, titleData) > -1) {
+ col.push({ field: data[i].id, title: data[i].name, align: 'center', hide: true }); //闅愯棌id鍒�
+ } else if (data[i].name == '鍗曟嵁鍙�') {
+ col.push({
+ field: data[i].id, title: data[i].name, align: 'center', sort: true, width: 200, event: '鍗曟嵁鍙�'
+ , event: '鍗曟嵁鍙�', templet: function (d) {
+ return '<span style="color: blue;">' + d.鍗曟嵁鍙� + '</span>'
+ }, style: 'cursor: pointer;'
+ });
+ }
+ else {
+ switch (data[i].Type) {
+ //int
+ case 'DateTime':
+ col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: false, templet: "<div>{{d." + data[i].name + " ==null ?'':layui.util.toDateString(d." + data[i].name + ", 'yyyy-MM-dd HH:mm:ss')}}</div>", width: 160 });
+ break;
+ case 'Decimal':
+ col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: false, width: 140, totalRow: true });
+ break;
+ case 'Int32':
+ col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: false, width: 140, totalRow: true });
+ break;
+ default:
+ col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: false, width: 140 });
+ }
+ }
+ }
+ option.cols = [col];
+ option.data = data1.data;
+ //鍒楄缃�
+ DisPlay_HideColumn(HModName, sessionStorage["HUserName"], option);
+ table.render(option);
layer.close(ajaxLoad);
} else {
layer.close(ajaxLoad);
diff --git "a/WebTM/views/\345\267\245\350\265\204\347\256\241\347\220\206/\347\217\255\347\273\204\350\201\214\345\221\230\346\270\205\345\215\225/Gy_GroupEmpBillList.html" "b/WebTM/views/\345\267\245\350\265\204\347\256\241\347\220\206/\347\217\255\347\273\204\350\201\214\345\221\230\346\270\205\345\215\225/Gy_GroupEmpBillList.html"
index f405af5..fea9a80 100644
--- "a/WebTM/views/\345\267\245\350\265\204\347\256\241\347\220\206/\347\217\255\347\273\204\350\201\214\345\221\230\346\270\205\345\215\225/Gy_GroupEmpBillList.html"
+++ "b/WebTM/views/\345\267\245\350\265\204\347\256\241\347\220\206/\347\217\255\347\273\204\350\201\214\345\221\230\346\270\205\345\215\225/Gy_GroupEmpBillList.html"
@@ -633,7 +633,7 @@
function get_HideColumn() {
var colName = "";
for (var i = 1; i < option.cols[0].length; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ colName += option.cols[0][i]["field"] + ",";
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
@@ -645,7 +645,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["50%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ['../../鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName, "yes"]
+ , content: ['../../鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName, "yes"]
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鍒锋柊琛ㄦ牸鏁版嵁
@@ -664,69 +664,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- /*var titleData = ["鍗曟嵁ID", "HGroupID","HEmpID"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�*/
-
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
dataCol = data1.data[0].HGridString.split(',');
-
- for (var i = 0; i < option.cols[0].length - 1; 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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/\344\270\215\350\211\257\351\207\207\351\233\206/Sc_QualityReportStepBillList_New.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/\344\270\215\350\211\257\351\207\207\351\233\206/Sc_QualityReportStepBillList_New.html"
index 3f682a3..a846dda 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/\344\270\215\350\211\257\351\207\207\351\233\206/Sc_QualityReportStepBillList_New.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/\344\270\215\350\211\257\351\207\207\351\233\206/Sc_QualityReportStepBillList_New.html"
@@ -829,7 +829,7 @@
var colName = "";
var contentUrl = "";
for (var i = 1; i < option.cols[0].length; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ colName += option.cols[0][i]["field"] + ",";
}
var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
var urlLen = urlStr.split('/');
@@ -867,69 +867,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
- var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- //var titleData = ["鍗曟嵁ID", "HMouldID", "hsubid", "HManagerID", "婧愬崟涓诲唴鐮�", "婧愬崟瀛愬唴鐮�"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
- //涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
var titleData = ["hmainid", "HMainEmpID", "HDeptID", "HGroupID", "HOrgID", "hsubid", "HMaterID", "HUnitID", "HEmpID", "HSourceID", "HBadReasonID", "HICMOInterID", "HICMOEntryID", "HICMOBillNo", "HProcExchInterID", "HProcExchEntryID", "HProcExchBillNo", "HSourceInterID", "HSourceEntryID", "HSourceBillNo", "HSourceBillType", "HBarCode", "HReportType", "HAddr", "HMaker", "HMakeDate", "HMainSourceInterID", "HMainSourceEntryID", "HMainSourceBillNo", "HMainSourceBillType"];
+ var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
dataCol = data1.data[0].HGridString.split(',');
-
- for (var i = 0; i < option.cols[0].length - 1; 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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\345\237\272\347\241\200\350\265\204\346\226\231/Cg_PODemandPlanConfigBillList.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\345\237\272\347\241\200\350\265\204\346\226\231/Cg_PODemandPlanConfigBillList.html"
index 10b4e07..5cccfcb 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\345\237\272\347\241\200\350\265\204\346\226\231/Cg_PODemandPlanConfigBillList.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\345\237\272\347\241\200\350\265\204\346\226\231/Cg_PODemandPlanConfigBillList.html"
@@ -480,7 +480,8 @@
table.render(option);
layer.close(ajaxLoad);
-
+ //鍒楄缃�
+ DisPlay_HideColumn();
//layer.alert("鏌ヨ鎴愬姛", { icon: 1 });
} else {
@@ -491,9 +492,7 @@
layer.close(ajaxLoad);
layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
}
- });
- //鍒楄缃�
- DisPlay_HideColumn();
+ });
}
@@ -501,8 +500,8 @@
//闅愯棌鍒楄缃�
function get_HideColumn() {
var colName = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
@@ -514,7 +513,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["50%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ['../../鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName, "yes"]
+ , content: ['../../鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName, "yes"]
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鍒锋柊琛ㄦ牸鏁版嵁
@@ -531,71 +530,84 @@
url: GetWEBURL() + '/Xt_grdAlignment_WMES/grdAlignmentWMESList',
type: "GET",
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
- success: function (result) {
- if (result.data.length != 0) {
-
-
+ success: function (data1) {
+ if (data1.data.length != 0) {
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- var titleData = ["HMaterID", "HUnitID", "HICMOEmpID"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
-
- dataCol = result.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 (result.data[0].HFontSize != 0) {
- option.cols[0][i + 1]["style"] = "font-size:" + result.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 (result.data[0].HFixCols != 0) {
- for (var i = 0; i < result.data[0].HFixCols; i++) {
- if ($.inArray(option.cols[0][i + 1]["title"], titleData) != -1) {
- result.data[0].HFixCols += 1;
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
+ dataCol = data1.data[0].HGridString.split(',');
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\345\237\272\347\241\200\350\265\204\346\226\231/Gy_WorkWarehouseBillList.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\345\237\272\347\241\200\350\265\204\346\226\231/Gy_WorkWarehouseBillList.html"
index 92f7e47..eec7bd3 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\345\237\272\347\241\200\350\265\204\346\226\231/Gy_WorkWarehouseBillList.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\345\237\272\347\241\200\350\265\204\346\226\231/Gy_WorkWarehouseBillList.html"
@@ -738,8 +738,8 @@
function get_HideColumn() {
var colName = "";
var contentUrl = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
}
var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
var urlLen = urlStr.split('/');
@@ -748,7 +748,7 @@
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+ contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName;
layer.open({
type: 2
@@ -777,69 +777,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- var titleData = ["hmainid"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
-
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\346\212\245\350\241\250/ReportMOMaterReadysBillList.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\346\212\245\350\241\250/ReportMOMaterReadysBillList.html"
index d36e1c1..c1024c9 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\346\212\245\350\241\250/ReportMOMaterReadysBillList.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\346\212\245\350\241\250/ReportMOMaterReadysBillList.html"
@@ -27,14 +27,6 @@
</div>
</div>
<div class="layui-inline">
- <label class="layui-form-label" style="width: 85px;">缁勭粐</label>
- <div class="layui-input-block" style="margin-left: 120px; width: 185px;">
- <select name="HORGID" id="HORGID" lay-verify="HORGID">
- <!--鍔ㄦ�佹覆鏌撶粍缁�-->
- </select>
- </div>
- </div>
- <div class="layui-inline">
<label class="layui-form-label" style="width: 85px;padding: 9px 18px;">鐗╂枡缂栫爜</label>
<div class="layui-input-block" style="margin-left: 77px;">
<input type="hidden" class="layui-input" lay-verify="HMATERIALID" name="HMATERIALID" id="HMATERIALID" value="0" style="background-color:#efefef4d;width: 60%;display: inline-block;" readonly>
@@ -48,17 +40,38 @@
<label class="layui-form-label" style="width: 85px;padding: 9px 18px;">鐢熶骇杞﹂棿</label>
<div class="layui-input-block" style="margin-left: 77px;">
<input type="hidden" class="layui-input" lay-verify="HDeptID" name="HDeptID" id="HDeptID" value="0" style="background-color:#efefef4d;width: 60%;display: inline-block;" readonly>
- <input type="text" class="layui-input" lay-verify="DeptNAME" name="DeptNAME" id="DeptNAME" value="" style="background-color:#efefef4d;width: 60%;display: inline-block;" readonly>
+ <input type="text" class="layui-input" lay-verify="DeptNAME" name="DeptNAME" id="DeptNAME" value="" style="width: 60%;display: inline-block;">
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnHDeptID" id="btnHDeptID" style="padding: 0 10px;float: right;margin-right: 3px;">
<i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
</button>
</div>
</div>
+ <div class="layui-inline">
+ <label class="layui-form-label" style="width: 85px;">璁″垝鏃ユ湡</label>
+ <div class="layui-input-block" style="margin-left: 120px;">
+ <input type="date" class="layui-input" lay-verify="HBeginDate" name="HBeginDate" id="HBeginDate" style="padding-left: 58px;width:160px;">
+ </div>
+ </div>
+ <div class="layui-inline">
+ <label class="layui-form-label" style="width: 85px;">鑷�:</label>
+ <div class="layui-input-block" style="margin-left: 120px;">
+ <input type="date" class="layui-input" lay-verify="HEndDate" name="HEndDate" id="HEndDate" style="padding-left: 58px;width:160px;">
+ </div>
+ </div>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">鏌ヨ</button>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnReSearch" id="btnReSearch">閲嶇疆</button>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnExport" id="btnExport">瀵煎嚭</button>
+ <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="bthHideColumn" id="bthHideColumn">鍒楄缃�</button>
<div class="layui-colla-content" style="padding: 0px; margin-left: 6%;">
<div class="layui-row" style="margin: 10px 0 10px;">
+ <div class="layui-inline">
+ <label class="layui-form-label" style="width: 85px;">缁勭粐</label>
+ <div class="layui-input-block" style="margin-left: 120px; width: 185px;">
+ <select name="HORGID" id="HORGID" lay-verify="HORGID">
+ <!--鍔ㄦ�佹覆鏌撶粍缁�-->
+ </select>
+ </div>
+ </div>
<div class="layui-inline">
<label class="layui-form-label" style="width: 85px;padding: 9px 18px;">鐢熶骇璧勬簮</label>
<div class="layui-input-block" style="margin-left: 77px;">
@@ -79,6 +92,12 @@
<label class="layui-form-label" style="width: 85px;">鐢熶骇璁㈠崟鍙�</label>
<div class="layui-input-block" style="margin-left: 120px;">
<input type="text" class="layui-input" name="HMOBILLNO" id="HMOBILLNO">
+ </div>
+ </div>
+ <div class="layui-inline">
+ <label class="layui-form-label" style="width: 85px;">鐗╂枡灞炴��</label>
+ <div class="layui-input-block" style="margin-left: 120px;">
+ <input type="text" class="layui-input" name="HMaterAtt" id="HMaterAtt">
</div>
</div>
<div class="layui-row" style=" margin-top: 10px; margin-left: 70px;">
@@ -181,10 +200,17 @@
var treeCkData = { id: 0 };
var TagId = "";
var TagParentId = "";
+
+ //#region 鏂囨湰妗嗚緭鍏ユ悳绱㈢浉鍏虫暟鎹�-鍙橀噺
+ var childPage = null; //鑾峰彇瀛愮獥鍙e璞★紝鐢ㄤ簬鎿嶄綔瀛愮獥鍙g殑鍙橀噺鍜屾柟娉�
+ var currRowIndex = 0; //鐢ㄤ簬瀹氫綅瀛愮獥鍙e綋鍓嶉�変腑鐨勮
+ var childData = null; //鐢ㄤ簬鑾峰彇瀛愮獥鍙h繑鍥炵殑鏁版嵁
+ //#endregion
+
layui.config({
base: '../../../layuiadmin/' //闈欐�佽祫婧愭墍鍦ㄨ矾寰�
}).extend({
- index: 'lib/index', //涓诲叆鍙fā鍧�
+ index: 'lib/index', //涓诲叆鍙fā鍧�
}).use(['tree', 'index', 'form', 'table', 'element', 'laypage', 'laydate', 'util','soulTable'], function () {
//#region 鍏敤鍙橀噺
var $ = layui.$
@@ -202,6 +228,8 @@
var sWhere = "";
var option = [];
var ins; //鐢ㄤ簬瀵煎嚭excel
+ var HModName = "ReportMOMaterReadysBillList";
+ var titleData = [];
//#endregion
//#region 杩涘叆椤甸潰鍗冲姞杞�
@@ -249,12 +277,146 @@
});
//#endregion
+ //#region 鍒楄缃寜閽�
+ form.on('submit(bthHideColumn)', function (data) {
+ get_HideColumn();
+ });
+ //#endregion
+
+
+ //#region 鏂囨湰妗嗙洃鍚�
+ $(document).ready(function () {
+ //#region 鏍规嵁鐗╂枡浠g爜鑾峰彇鐗╂枡鍩虹璧勬枡绛涢�夊脊绐�
+ //鏍规嵁鍏冪礌ID瀵瑰厓绱犺繘琛岀洃鍚�=============================================================================
+ $("#DeptNAME").on('keydown', function (data) {
+ //================================================================================================
+ var errKeys = ["ArrowUp", "ArrowDown", "ArrowLeft", "ArrowRight", "Enter"];
+ if ($.inArray(event.key, errKeys) == -1) { //濡傛灉鎸変笅鐨勯敭浣嶄笉鏄� 鏂瑰悜閿紝鍒欏埛鏂板脊绐椾腑鐨勬暟鎹�
+ if (childPage == null) { //鍒ゆ柇褰撳墠瀛愮獥鍙f槸鍚﹀凡缁忔墦寮�锛岃嫢鏈墦鍗★紝鍒欐墦寮�椤甸潰锛屽苟鑾峰彇瀛愮獥鍙g殑瀵硅薄
+ var offset = $(this).offset(); //鑾峰彇瑙﹀彂浜嬩欢鐨勫厓绱犵殑浣嶇疆锛岀敤浜庡畾浣嶅瓙绐楀彛鎵撳紑鐨勪綅缃�
+ var innerHeight = window.innerHeight;
+ var top = offset.top + 0.05 * innerHeight;
+ var left = offset.left;
+ if (top + 0.05 * innerHeight + 0.3 * innerHeight > innerHeight) {
+ top = top - 0.3 * innerHeight - 0.05 * innerHeight;
+ }
+ layer.open({
+ type: 2 //寮圭獥绫诲瀷
+ , skin: 'layui-layer-rim' //鍔犱笂杈规
+ , area: ['25%', '30%'] //澶у皬
+ , shadeClose: true //鐐瑰嚮閬僵鏃跺叧闂脊绐�
+ , offset: [top, left]
+ , title: false //涓嶆樉绀烘爣棰樻爮
+ //, title: '椤圭洰璐圭敤鍒楄〃' //鏍囬
+ , shift: 2 //寮瑰嚭鍔ㄧ敾
+ , closeBtn: 0 //绂佺敤鍏抽棴鎸夐挳
+ , content: ["../../鍩虹璧勬枡/閫氱敤鍩虹璧勬枡/Gy_CommonBaseDataCheck.html?OperationType=2", "yes"]
+ , btn: ['纭畾', '鍙栨秷']
+ , btn1: function (index, layero) {//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
+ var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮规椤甸潰
+ var checkStatus = iframeWindow.layui.table.checkStatus('mainTable');//鑾峰彇table鐨別lem:"#test"
+ if (checkStatus.data.length === 0) {
+ return layer.msg('璇烽�夋嫨鏁版嵁');
+ }
+
+ var HIDValue = "";
+ var HNameValue = "";
+ for (var i = 0; i < checkStatus.data.length; i++) {
+ HIDValue += checkStatus.data[i].HItemID + ",";
+ HNameValue += checkStatus.data[i].閮ㄩ棬鍚嶇О + ",";
+ }
+
+ //鍘婚櫎鏈熬閫楀彿
+ HIDValue = HIDValue.substring(0, HIDValue.length - 1);
+ HNameValue = HNameValue.substring(0, HNameValue.length - 1);
+ $("#HDeptID").val(HIDValue);
+ $("#DeptNAME").val(HNameValue);
+ //鑾峰彇鏁版嵁
+
+ layer.close(index); //瀹冭幏鍙栫殑濮嬬粓鏄渶鏂板脊鍑虹殑鏌愪釜灞傦紝鍊兼槸鐢眑ayer鍐呴儴鍔ㄦ�侀�掑璁$畻鐨�
+ }
+ , btn2: function (index, layero) { }
+ , success: function (layero, index) {
+ setTimeout(function () {
+ //淇敼锛屾牴鎹枃鏈鏁版嵁锛岀紪鍐欐煡璇㈣鍙�================================================================================================
+ var value = $("#DeptNAME").val().replace(/'/g, ""); //鑾峰彇鏂囨湰妗嗘渶鏂板��
+ currRowIndex = 0;
+ var tableView = "h_v_Gy_DepartmentList";
+ var childSWhere = "select top(10) HItemID,閮ㄩ棬浠g爜,閮ㄩ棬鍚嶇О from " + tableView + " where 1=1 and 缁勭粐鍚嶇О = '" + sessionStorage["Organization"] + "' and (閮ㄩ棬浠g爜 like '%" + value + "%' or 閮ㄩ棬鍚嶇О like '%" + value + "%') order by 閮ㄩ棬浠g爜 desc";
+ childPage.getData(childSWhere, tableView);
+ //===================================================================================================================================
+ }, 200);
+ }
+ , end: function () {
+ childPage = null;
+ currRowIndex = 0;
+ if (childData != null) {
+ //鏍规嵁寮圭獥杩斿洖鏁版嵁璁剧疆鏂囨湰妗嗘暟鎹�=================================================================================================
+ //鑾峰彇鏁版嵁
+ $("#HDeptID").val(childData.HItemID);//杞﹂棿id
+ $("#DeptNAME").val(childData.閮ㄩ棬鍚嶇О);//杞﹂棿鍚嶇О
+ //===============================================================================================================================
+
+ childData = null;
+ }
+ }
+ });
+ } else {
+ setTimeout(function () {
+ //淇敼锛屾牴鎹枃鏈鏁版嵁锛岀紪鍐欐煡璇㈣鍙�================================================================================================
+ var value = $("#DeptNAME").val().replace(/'/g, ""); //鑾峰彇鏂囨湰妗嗘渶鏂板��
+ currRowIndex = 0;
+ var tableView = "h_v_Gy_DepartmentList";
+ var childSWhere = "select top(10) HItemID,閮ㄩ棬浠g爜,閮ㄩ棬鍚嶇О from " + tableView + " where 1=1 and 缁勭粐鍚嶇О = '" + sessionStorage["Organization"] + "' and (閮ㄩ棬浠g爜 like '%" + value + "%' or 閮ㄩ棬鍚嶇О like '%" + value + "%') order by 閮ㄩ棬浠g爜 desc";
+ childPage.getData(childSWhere, tableView);
+ //=================================================================================================================================
+ }, 200);
+ }
+ } else { //濡傛灉鎸変笅鐨勯敭浣嶆槸 鏂瑰悜閿紝鍒欒皟鏁寸獥鍙d腑 閫変腑琛� 鐨勪綅缃�
+ if (event.key == "ArrowUp") {
+ currRowIndex--;
+ childPage.setSelectedRow(currRowIndex);
+ } else if (event.key == "ArrowDown") {
+ currRowIndex++;
+ childPage.setSelectedRow(currRowIndex);
+ } else if (event.key == "Enter") {
+ //鎵嬪姩澶辩劍
+ var element = document.getElementById("HMaterNumber");
+ element.blur();
+
+ childPage.getSelectedData(currRowIndex);
+
+ if (childData != null) {
+ //鏍规嵁寮圭獥杩斿洖鏁版嵁璁剧疆鏂囨湰妗嗘暟鎹�=================================================================================================
+ //鑾峰彇鏁版嵁
+ $("#HDeptID").val(childData.HItemID);//杞﹂棿id
+ $("#DeptNAME").val(childData.閮ㄩ棬鍚嶇О);//杞﹂棿鍚嶇О
+ //===============================================================================================================================
+
+ childData = null;
+ }
+
+
+ childPage = null;
+ currRowIndex = 0;
+ childData = null;
+ }
+ }
+ });
+ //#endregion
+ });
+ //#endregion
+
+
//#endregion
//#region 鏈〉闈㈣璋冪敤鐨勬墍鏈夋柟娉�
//#region 鍒濆鍖栫晫闈�
function set_ClearBill() {
+ //鍒濆鍖栨棩鏈�
+ $("#HBeginDate").val(Format(new Date(new Date()), "yyyy-MM-dd"));//鎻愭枡鏃ユ湡
+ $("#HEndDate").val(Format(new Date($("#HBeginDate").val()).setDate(new Date($("#HBeginDate").val()).getDate() + 7), "yyyy-MM-dd"));//鑷�
//鐢熶骇缁勭粐鍔犺浇
Organ();
//鍒濆鍖栬〃鏍�
@@ -297,6 +459,7 @@
, { field: '鐗╂枡缂栫爜', title: '鐗╂枡缂栫爜', sort: true }
, { field: '鐗╂枡鍚嶇О', title: '鐗╂枡鍚嶇О', sort: true }
, { field: '鐗╂枡瑙勬牸鍨嬪彿', title: '鐗╂枡瑙勬牸鍨嬪彿', sort: true }
+ , { field: '鐗╂枡灞炴��', title: '鐗╂枡灞炴��', sort: true }
, { field: '璁″垝鍙戞枡鏁伴噺', title: '璁″垝鍙戞枡鏁伴噺', sort: true, totalRow: true }
, { field: '榻愬鏁伴噺', title: '榻愬鏁伴噺', sort: true, totalRow: true}
, { field: '缂烘枡鏁伴噺', title: '缂烘枡鏁伴噺', sort: true, totalRow: true }
@@ -343,6 +506,9 @@
if (result.count == 1) {
option.data = result.data;
table.render(option);
+ //鍒锋柊琛ㄦ牸鏁版嵁
+ DisPlay_HideColumn();
+
layer.close(ajaxLoad);
} else {
layer.close(ajaxLoad);
@@ -367,7 +533,10 @@
var HSCZYID = $("#HSCZYID").val();//鐢熶骇璧勬簮
var HXQD = $("#HXQD").val();//闇�姹傚崟鍙�
var HMOBILLNO = $("#HMOBILLNO").val();//鐢熶骇璁㈠崟鍙�
-
+ var HBeginDate = $("#HBeginDate").val();//鎻愭枡鏃ユ湡
+ var HEndDate = $("#HEndDate").val();//鑷�
+ var HMaterAtt = $("#HMaterAtt").val();//鐗╂枡灞炴��
+
var ColName = $("#ColName").val();//澶嶉�夋
var Comparator = $("#Comparator").val()
var ColContent = $("#ColContent").val();
@@ -442,6 +611,16 @@
}
sWhere += " and " + ColName2 + " " + com2;
}
+
+ if (HBeginDate > HEndDate) {
+ layer.close(ajaxLoad);
+ return layer.msg("寮�濮嬫棩鏈熶笉鑳藉皬浜庣粨鏉熸棩鏈�!");
+ }
+
+ if (HBeginDate != null && HEndDate != null) {
+ sWhere += " and HDate between ''" + HBeginDate + "'' and ''" + HEndDate + "'' ";
+ }
+
sWhere = {
HORGID: HORGID
, HMATERIALID: HMATERIALID
@@ -449,8 +628,11 @@
, HSCZYID: HSCZYID
, HXQD: HXQD
, HMOBILLNO: HMOBILLNO
+ , HBeginDate: HBeginDate
+ , HEndDate: HEndDate
+ , HMaterAtt: HMaterAtt
}
-
+
$.ajax({
url: GetWEBURL() + '/JIT_Complete/ReportMOMaterReadysBillList',
type: "GET",
@@ -460,6 +642,10 @@
data = result.data;
option.data = data;
+
+ //鍒锋柊琛ㄦ牸鏁版嵁
+ DisPlay_HideColumn();
+
ins = table.render(option);
data.forEach((item) => {
@@ -504,6 +690,9 @@
var HSCZYID = $("#HSCZYID").val();//鐢熶骇璧勬簮
var HXQD = $("#HXQD").val();//闇�姹傚崟鍙�
var HMOBILLNO = $("#HMOBILLNO").val();//鐢熶骇璁㈠崟鍙�
+ var HBeginDate = $("#HBeginDate").val();//鎻愭枡鏃ユ湡
+ var HEndDate = $("#HEndDate").val();//鑷�
+ var HMaterAtt = $("#HMaterAtt").val();//鐗╂枡灞炴��
var ColName = $("#ColName").val();//澶嶉�夋
var Comparator = $("#Comparator").val()
@@ -579,6 +768,15 @@
}
sWhere += " and " + ColName2 + " " + com2;
}
+
+ if (HBeginDate > HEndDate) {
+ return layer.msg("寮�濮嬫棩鏈熶笉鑳藉皬浜庣粨鏉熸棩鏈�!");
+ }
+
+ if (HBeginDate != null && HEndDate != null) {
+ sWhere += " and HDate between ''" + HBeginDate + "'' and ''" + HEndDate + "'' ";
+ }
+
sWhere = {
HORGID: HORGID
, HMATERIALID: HMATERIALID
@@ -586,6 +784,9 @@
, HSCZYID: HSCZYID
, HXQD: HXQD
, HMOBILLNO: HMOBILLNO
+ , HBeginDate: HBeginDate
+ , HEndDate: HEndDate
+ , HMaterAtt: HMaterAtt
}
get_Display(JSON.stringify(sWhere));
sWhere = "";//璋冪敤鎺ュ彛鍚庢竻绌簊Where缂撳瓨
@@ -612,6 +813,9 @@
$("#ColContent2").val("");
$("#ColName2").val("0");
$("#Comparator2").val("0");
+ $("#HBeginDate").val(Format(new Date(new Date()), "yyyy-MM-dd"));//鎻愭枡鏃ユ湡
+ $("#HEndDate").val(Format(new Date($("#HBeginDate").val()).setDate(new Date($("#HBeginDate").val()).getDate() + 7), "yyyy-MM-dd"));//鑷�
+ $("#HMaterAtt").val("");
form.render('select');
sWhere = "";
}
@@ -709,6 +913,139 @@
form.render('select');
}
+ //#region 闅愯棌鍒楄缃�
+ function get_HideColumn() {
+ var colName = "";
+ var contentUrl = "";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
+ }
+ 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_New.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);//鍏抽棴寮圭獥
+ }
+ })
+ }
+ //#endregion
+
+ //#region 鏄剧ず鍒楁暟鎹�
+ 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) {
+ titleData = [];
+ var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
+ dataCol = data1.data[0].HGridString.split(',');
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
+ }
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ })
+ }
+ //#endregion
+
//#endregion
//浠ヤ笂鏄痩ayui妯″潡
});
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\344\273\273\345\212\241\345\215\225/Sc_ICMOBillList.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\344\273\273\345\212\241\345\215\225/Sc_ICMOBillList.html"
index 28ee17d..8b4d6bd 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\344\273\273\345\212\241\345\215\225/Sc_ICMOBillList.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\344\273\273\345\212\241\345\215\225/Sc_ICMOBillList.html"
@@ -16,6 +16,7 @@
<script src="../../../layuiadmin/HideButton.js"></script>
<script src="../../../layuiadmin/soulTable.slim.js"></script>
<script src="../../../layuiadmin/PageTitle.js"></script>
+ <script src="../../../layuiadmin/QueryScheme.js"></script>
</head>
<body>
<div class="layui-fluid">
@@ -376,7 +377,7 @@
//#region 銆愯繃婊ゆ柟妗堛��
//杩囨护鏉′欢鐨刢lass绫�
- var HClassTag = "ForFilteringSchemes";
+ window.HClassTag = "ForFilteringSchemes";
//妯″潡鍚嶇О锛堜腑鏂囩増锛� 姣忎釜妯″潡椤甸潰閮介渶瑕佷慨鏀�
window.HModuleName = "鐢熶骇璁㈠崟";
//鏄惁宸茬粡閫夋嫨浜嗚繃婊ゆ柟妗堬紙鍏ㄥ眬鍙橀噺锛�
@@ -617,14 +618,14 @@
case 'set_Remark': set_Remark();
break;
//淇濆瓨鏂规
- case 'set_SaveScheme': set_SaveScheme();
+ case 'set_SaveScheme': set_SaveScheme(get_FastQuery);
break;
//璇诲彇鏂规
- case 'set_ReadScheme': set_ReadScheme();
+ case 'set_ReadScheme': set_ReadScheme(get_FastQuery);
break;
//楂樼骇杩囨护
case 'set_QueryCondition':
- set_QueryCondition();
+ set_QueryCondition(option, "h_v_IF_ICMOBillList", get_FastQuery);
break;
};
});
@@ -759,7 +760,7 @@
//鏌ヨ
get_FastQuery();
//鏌ヨ褰撳墠鐧诲綍鐢ㄦ埛鏈夋病鏈夊湪褰撳墠妯″潡璁剧疆榛樿杩囨护鏂规
- get_DefaultModule();
+ get_DefaultModule(get_FastQuery);
}
//#endregion
@@ -1468,17 +1469,27 @@
var checkStatus = table.checkStatus('mainTable')
, data = checkStatus.data;
if (data.length != 0) {
-
+ var HErr = "";
for (var i = 0; i < data.length; i++) {
+
+ if (data[i].鐘舵�� != "涓嬭揪" && data[i].鐘舵�� != "寮�宸�") {
+ HErr += "閫変腑琛岀" + (i + 1) + "琛岋紝鐢熶骇璁㈠崟:" + data[i].鍗曟嵁鍙� + "鐘舵�佷笉涓轰笅杈炬垨鑰呭紑宸ワ紝涓嶅厑璁哥敓鎴愭祦杞崱锛�<br/><br/>";
+ continue;
+ }
+
var linterid = data[i].hmainid.toString();
var HEntryID = data[i].HEntryID.toString();
+
layer.open({
type: 2
, area: ['100%', '100%']
, title: '宸ュ簭娴佽浆鍗�-缂栬緫'
, shift: 0//寮瑰嚭鍔ㄧ敾
, content: '../../杞﹂棿绠$悊/宸ュ簭娴佽浆鍗�/Sc_ProcessExchangeBill.html?OperationType=2&linterid=' + linterid + '&HEntryID=' + HEntryID + '&HSouceBillType=3772'
- })
+ })
+ }
+ if (HErr != "") {
+ layer.alert(HErr);
}
} else {
layer.msg('璇烽�夋嫨鏁版嵁涓嬫帹锛�');
@@ -1511,12 +1522,23 @@
if (data.length > 0) {
var linterid = [];
var msg = "";
+ var HErr = "";
for (var i = 0; i < data.length; i++) {
if (Number(data[i].鐢熶骇浠诲姟鍗曟暟閲�) - Number(data[i].娴佽浆鍗℃暟閲�) <= 0) {
msg += "閫変腑琛岀<span style='color: red;'>" + (i + 1) + "</span>琛岋紝鐢熶骇璁㈠崟锛�<span style='color: red;'>" + data[i].鍗曟嵁鍙� + "</span>,<br/>璁㈠崟鏁伴噺锛�<span style='color: blue;'>" + data[i].鐢熶骇浠诲姟鍗曟暟閲� + "</span>锛屽凡鐢熸垚娴佽浆鍗℃暟<span style='color: blue;'>" + data[i].娴佽浆鍗℃暟閲� + "</span>,<br/>鍓╀綑鍙笅鎺ㄦ祦杞崱鏁�:<span style='color: orange;'>" + "0</span>锛岃鍕胯秴閲忕敓鎴愶紒" + "<br/>" + "<br/>";
}
+
+ if (data[i].鐘舵�� != "涓嬭揪" && data[i].鐘舵�� != "寮�宸�") {
+ HErr += "閫変腑琛岀" + (i + 1) + "琛岋紝鐢熶骇璁㈠崟:" + data[i].鍗曟嵁鍙� + "鐘舵�佷笉涓轰笅杈炬垨鑰呭紑宸ワ紝涓嶅厑璁哥敓鎴愭祦杞崱锛�<br/><br/>";
+ continue;
+ }
linterid.push(data[i].hmainid + '@' + data[i].hsubid);
+ }
+
+ if (HErr != "") {
+ layer.alert(HErr);
+ return;
}
if (msg != "") {
@@ -2689,289 +2711,6 @@
return res;
}
- //#region 銆愯繃婊ゆ柟妗堛��
-
- //鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
- function get_DefaultModule() {
- $.ajax({
- url: GetWEBURL() + '/Xt_FastICScheme/Chooselist',
- type: "GET",
- async: false,
- data: { "user": sessionStorage["Czybm"], "HModuleName": HModuleName, "HInterID": 0, "Type": "Default" },
- success: function (data1) {
- if (data1.count == 1) {
- //褰撳墠鐢ㄦ埛璁剧疆鏈夐粯璁ょ殑杩囨护鏂规
- var data = data1.data;
- //褰撳墠閫夋嫨鐨勮繃婊ゆ柟妗�
- HInterID_Choose = data[0].hmainid;
- //杩囨护鏂规鍐呯爜
- HInterID = data[0].hmainid
- //杩囨护鏂规鍚嶇О
- HDefaultFilter = data[0].鏂规鍚嶇О
- //杩囨护鏂规鐨勫娉紙鏂规淇℃伅鎻忚堪锛�
- var HRemark = data[0].澶囨敞
- //鏄剧ず鍑哄綋鍓嶇殑榛樿杩囨护鏂规
- document.getElementById("HFilterScheme_Now").style.display = "block";
- document.getElementById('HFilterScheme_Now').innerHTML = "褰撳墠杩囨护鏂规锛�" + HDefaultFilter + '<span style="font-size: 15px; font-weight: bold; color:#7b90fb"> ' + "(" + HRemark + ")" + '</span>';
- //鎶婅繃婊ゆ潯浠跺�煎洖鍐欏埌椤甸潰涓�
- for (let i = 0; i < data.length; i++) {
- $("#" + data[i].杩囨护瀛楁ID).val(data[i].杩囨护鍊�);
- if (data[i].杩囨护鏍囩绫诲瀷 == 'SELECT') {
- $("#" + data[i].杩囨护瀛楁ID).find("option[value='" + data[i].杩囨护鍊� + "']").attr("selected", true);
- }
- }
-
- var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
- //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
- if (HInitTimeCycle != -1) {
- //$('#HDate').prop('disabled', true);
- //$('#HDate1').prop('disabled', true);
-
- $("#HDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
- $("#HDate1").val(Format(new Date(), "yyyy-MM-dd"));
-
- //鎵ц鏌ヨ鏂规硶
- get_FastQuery();
- } else {
- //$('#HDate').prop('disabled', false);
- //$('#HDate1').prop('disabled', false);
- }
-
-
- //鎵ц鏌ヨ鏂规硶
- get_FastQuery()
- form.render("select");
- } else {
- //褰撳墠鐢ㄦ埛娌℃湁璁剧疆榛樿鐨勮繃婊ゆ柟妗�
- //闅愯棌鏄剧ず杩囨护鏂规鐨勬爣绛句俊鎭�
- document.getElementById("HFilterScheme_Now").style.display = "none";
- //鎵ц鏌ヨ鏂规硶
- get_FastQuery()
- form.render("select");
- }
- }, error: function () {
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- });
- }
-
- //淇濆瓨鏂规
- function set_SaveScheme() {
- var index = layer.open()
- //鍒ゆ柇鐢ㄦ埛鏄惁鐐瑰嚮浜嗗彸涓婅鐨勨�滃弶鍙封�濆叧闂脊绐楅〉闈�
- var HIsClose_Manual = false;
- //鑾峰彇鏈〉鎵�鏈夎繃婊ゆ潯浠跺璞�(class涓寘鍚�"ForFilteringSchemes"鐨勫厓绱�)
- var Filter = document.getElementsByClassName(HClassTag);
-
- var HFilterIdList = "";//杩囨护鏉′欢
- var HFilterIdLists = "";//鎷兼帴澶氫釜杩囨护鏉′欢
- var HValue = "";//杩囨护鍊�
- var HElement_type = "";//杩囨护鏍囩绫诲瀷
-
- for (var i = 0; i < Filter.length; i++) {
- HFilterIdList = Filter[i].id; //杩囨护鏉′欢ID
- HFilterIdLists += Filter[i].id + ","; //杩囨护鏉′欢ID(鎷兼帴)
- HValue += $("#" + HFilterIdList).val() + ","; //杩囨护鏉′欢涓緭鍏ョ殑鍊�
- HElement_type += document.getElementById(HFilterIdList).tagName + ",";//閫氳繃鏍囩id鑾峰彇鏍囩绫诲瀷
- }
-
- //鍘婚櫎鏈熬閫楀彿
- HFilterIdLists = HFilterIdLists.substring(0, HFilterIdLists.length - 1);
- HValue = HValue.substring(0, HValue.length - 1);
- HElement_type = HElement_type.substring(0, HElement_type.length - 1);
-
- //褰撳墠椤甸潰涓婃病鏈夐�夋嫨杩囨护鏂规锛岃繘鍏ユ柊澧炴柟娉�
- if (HDefaultFilter == "") {
- layer.open({
- type: 2
- , area: ['40%', '80%']
- , title: '杩囨护鏂规'
- , shift: 0//寮瑰嚭鍔ㄧ敾
- , content: '../../绯荤粺绠$悊/杩囨护鏂规璁剧疆/Xt_FastICScheme.html?OperationType=1&HModuleName=' + HModuleName + '&HFilterIdLists=' + HFilterIdLists + '&HValue=' + HValue + '&HElement_type=' + HElement_type
- , cancel: function () {
- // 鍙充笂瑙掑叧闂簨浠剁殑閫昏緫
- HIsClose_Manual = true;
- }
- , end: function () {
- if (HIsClose_Manual != true) {
- get_FastQuery();
- //鏄剧ず褰撳墠鐨勮繃婊ゆ柟妗�
- document.getElementById("HFilterScheme_Now").style.display = "block";
- document.getElementById('HFilterScheme_Now').innerHTML = "褰撳墠杩囨护鏂规锛�" + sessionStorage["HFilterSchemeName_" + sessionStorage["Czybm"]] + '<span style="font-size: 15px; font-weight: bold; color:#7b90fb"> ' + "(" + sessionStorage["HFilterSchemeRemark_" + sessionStorage["Czybm"]] + ")" + '</span>';
- }
- }
- })
- layer.close(index)
- } else {
- //褰撳墠椤甸潰宸叉湁杩囨护鏂规锛岀敤鎴烽�夋嫨 鏂板鎴栬�呯紪杈�
- layer.confirm('褰撳墠宸查�夋嫨杩囨护鏂规锛屾槸鍚︿慨鏀癸紵璇烽�夋嫨瀵瑰簲鎿嶄綔', {
- title: "鎿嶄綔鎻愮ず",
- icon: 0,
- btn: ['鏂板鏂规', '淇濆瓨淇敼褰撳墠鏂规', '鍙栨秷']
- }, function (index, layero) {
- //鏂板
- layer.open({
- type: 2
- , area: ['40%', '80%']
- , title: '杩囨护鏂规'
- , shift: 0//寮瑰嚭鍔ㄧ敾
- , content: '../../绯荤粺绠$悊/杩囨护鏂规璁剧疆/Xt_FastICScheme.html?OperationType=1&HModuleName=' + HModuleName + '&HFilterIdLists=' + HFilterIdLists + '&HValue=' + HValue + '&HElement_type=' + HElement_type
- , end: function () {
- get_FastQuery()
- //鏄剧ず褰撳墠鐨勮繃婊ゆ柟妗�
- document.getElementById("HFilterScheme_Now").style.display = "block";
- document.getElementById('HFilterScheme_Now').innerHTML = "褰撳墠杩囨护鏂规锛�" + sessionStorage["HFilterSchemeName_" + sessionStorage["Czybm"]] + '<span style="font-size: 15px; font-weight: bold; color:#7b90fb"> ' + "(" + sessionStorage["HFilterSchemeRemark_" + sessionStorage["Czybm"]] + ")" + '</span>';
- }
- })
- layer.close(index)
- }, function (index) {
- //缂栬緫
- var Filter_Edit = document.getElementsByClassName(HClassTag); //鑾峰彇鏈〉鎵�鏈夎繃婊ゆ潯浠跺璞�(class涓寘鍚�"ForFilteringSchemes"鐨勫厓绱�)
- HFilterIdList = "";
- HFilterIdLists = "";
- HValue = "";
- HElement_type = "";
- for (var i = 0; i < Filter_Edit.length; i++) {
- HFilterIdList = Filter_Edit[i].id; //杩囨护鏉′欢ID
- HFilterIdLists += Filter_Edit[i].id + ","; //杩囨护鏉′欢ID(鎷兼帴)
- HValue += $("#" + HFilterIdList).val() + ","; //杩囨护鏉′欢涓緭鍏ョ殑鍊�
- HElement_type += document.getElementById(HFilterIdList).tagName + ",";//閫氳繃鏍囩id鑾峰彇鏍囩绫诲瀷
- }
- //鍘婚櫎鏈熬閫楀彿
- HFilterIdLists = HFilterIdLists.substring(0, HFilterIdLists.length - 1);
- HValue = HValue.substring(0, HValue.length - 1);
- HElement_type = HElement_type.substring(0, HElement_type.length - 1);
-
- var sMainSub = HInterID_Choose + ';' + HFilterIdLists + ';' + HValue + ';' + HElement_type + ';' + sessionStorage["Czybm"] + ';' + 3;
-
- //淇敼
- $.ajax({
- type: "POST",
- url: GetWEBURL() + "/Xt_FastICScheme/save", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
- async: true,
- data: { "oMain": sMainSub },
- dataType: "json",
- success: function (data) {
- if (data.count == 1) { // 璇存槑楠岃瘉鎴愬姛浜嗭紝
- layer.msg(data.Message, { time: 1 * 1000, icon: 1 });
- }
- else {
-
- }
- layer.closeAll("loading");
- },
- error: function (err) {
-
-
- }
- });
- layer.close(index)
- }, function (index) {
- //鍙栨秷
- layer.alert('鍙栨秷')
- layer.close(index)
- });
- }
-
- }
-
- //璇诲彇鏂规
- function set_ReadScheme() {
- var HIsClose_Manual = false;
- var Filter = document.getElementsByClassName(HClassTag); //鑾峰彇鏈〉鎵�鏈夎繃婊ゆ潯浠跺璞�(class涓寘鍚�"ForFilteringSchemes"鐨勫厓绱�)
-
- var HFilterIdList = "";
- var HFilterIdLists = "";
- var HValue = "";
- var HElement_type = "";
- for (var i = 0; i < Filter.length; i++) {
- HFilterIdList = Filter[i].id; //杩囨护鏉′欢ID
- HFilterIdLists += Filter[i].id + ","; //杩囨护鏉′欢ID(鎷兼帴)
- HValue += $("#" + HFilterIdList).val() + ","; //杩囨护鏉′欢涓緭鍏ョ殑鍊�
- HElement_type += document.getElementById(HFilterIdList).tagName + ",";//閫氳繃鏍囩id鑾峰彇鏍囩绫诲瀷
- }
- //鍘婚櫎鏈熬閫楀彿
- HFilterIdLists = HFilterIdLists.substring(0, HFilterIdLists.length - 1);
- HValue = HValue.substring(0, HValue.length - 1);
- HElement_type = HElement_type.substring(0, HElement_type.length - 1);
-
- layer.open({
- type: 2
- , area: ['80%', '80%']
- , title: '杩囨护鏂规鍒楄〃'
- , shift: 0//寮瑰嚭鍔ㄧ敾
- , content: '../../绯荤粺绠$悊/杩囨护鏂规璁剧疆/Xt_FastICSchemeList.html?HType=Select&HFilterIdLists=' + HFilterIdLists + '&HValue=' + HValue + '&HElement_type=' + HElement_type + '&HModuleName=' + HModuleName
- , cancel: function () {
- // 鍙充笂瑙掑叧闂簨浠剁殑閫昏緫
- HIsClose_Manual = true;
- }
- , end: function () {
- if (HIsClose_Manual != true) {
- get_FastQuery()
- form.render("select");
- }
- }
- })
- }
-
- //楂樼骇杩囨护
- function set_QueryCondition() {
- var colName = "";
- var contentUrl = "";
- for (var i = 0; i < option.cols[0].length; i++) {
- if (option.cols[0][i]["field"] != undefined && option.cols[0][i]["hide"] != true) {
- 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 杩涜缂栫爜
-
- var HModBillName = "h_v_IF_ICMOBillList";//绛変簬璇ュ垪琛ㄧ殑瑙嗗浘
-
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_QueryCondition.html?HModName=' + HModBillName + '&colName=' + colName;
-
- layer.open({
- type: 2
- , skin: "layui-layer-rim" //鍔犱笂杈规
- , title: "楂樼骇杩囨护" //鏍囬
- , closeBtn: 1 //绐椾綋鍙充笂瑙掑叧闂� 鐨� 鏍峰紡
- , shift: 2 //寮瑰嚭鍔ㄧ敾
- , area: ["50%", "80%"] //绐椾綋澶у皬
- , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: [contentUrl, "yes"]
- , btn: ["纭畾", "鍙栨秷"]
- , btn1: function (index, laero) {
- var iframeWindow = window["layui-layer-iframe" + index];//鑾峰彇寮规椤甸潰
- var checkStatus = iframeWindow.layui.table.cache["mainTable"];//鑾峰彇閫変腑鐨勬暟鎹�
- if (checkStatus.length == 0) {
- return layer.msg("璇疯緭鍏ヨ繃婊ゆ潯浠�!");
- }
- var myIframe = window[laero.find('iframe')[0]['name']];
- GetDataCols += "and (";
- for (var i = 0; i < checkStatus.length; i++) {
- GetDataCols += myIframe.get_FastQuery(checkStatus[i]); //get_FastQuery()涓哄瓙椤甸潰鐨勬柟娉�
- if ((i + 1) < checkStatus.length) {
- GetDataCols += " " + checkStatus[i]["HRelationCol"] + " ";
- }
- }
- GetDataCols += ")";
- //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹�
- layer.close(index);//鍏抽棴寮圭獥
- }
- , end: function () {
- if (GetDataCols != "") {
- get_FastQuery();
- }
- }
- })
- }
-
- //#endregion
-
//#endregion
@@ -3048,45 +2787,6 @@
});
- //#region 銆愯繃婊ゆ柟妗堣繑鍥炴暟鎹��
- function HFilterScheme(obj) //杩斿洖杩囨护鏂规
- {
- var HInterID = obj[0].hmainid;
- HInterID_Choose = obj[0].hmainid;
- $.ajax({
- url: GetWEBURL() + '/Xt_FastICScheme/Chooselist',
- type: "GET",
- data: { "user": sessionStorage["Czybm"], "HModuleName": HModuleName, "HInterID": HInterID, "Type": "Select" },
- success: function (data1) {
- if (data1.count == 1) {
- var data = data1.data;
- //璧嬪�艰繃婊ゆ柟妗堝悕绉�
- HDefaultFilter = data[0].鏂规鍚嶇О
- var HRemark = data[0].澶囨敞
- //鏄剧ず褰撳墠鐨勮繃婊ゆ柟妗�
- document.getElementById("HFilterScheme_Now").style.display = "block";
- document.getElementById('HFilterScheme_Now').innerHTML = "褰撳墠杩囨护鏂规锛�" + HDefaultFilter + '<span style="font-size: 15px; font-weight: bold; color:#7b90fb"> ' + "(" + HRemark + ")" + '</span>';
- HInterID = data[0].hmainid
- //鏍规嵁閫夋嫨鐨勮繃婊ゆ柟妗堝洖濉暟鎹埌鍒楄〃杩囨护鏉′欢
- for (let i = 0; i < data.length; i++) {
- $("#" + data[i].杩囨护瀛楁ID).val(data[i].杩囨护鍊�);
- if (data[i].杩囨护鏍囩绫诲瀷 == 'SELECT') {
- $("#" + data[i].杩囨护瀛楁ID).find("option[value='" + data[i].杩囨护鍊� + "']").attr("selected", true);
- }
- }
-
- } else {
- layer.close(ajaxLoad);
- layer.alert(data1.code + data1.Message, { icon: 5 });
- }
- }, error: function () {
- layer.close(ajaxLoad);
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- });
- }
- //#endregion
-
function GetDataCol(data) {
GetDataCols = data;
}
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\346\212\225\346\226\231\345\215\225/Sc_PPBomBillList.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\346\212\225\346\226\231\345\215\225/Sc_PPBomBillList.html"
index 12b1479..8e66f5f 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\346\212\225\346\226\231\345\215\225/Sc_PPBomBillList.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\346\212\225\346\226\231\345\215\225/Sc_PPBomBillList.html"
@@ -1001,7 +1001,7 @@
function get_HideColumn() {
var colName = "";
var contentUrl = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
+ for (var i = 1; i < option.cols[0].length; i++) {
colName += option.cols[0][i]["field"] + ",";
}
var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
@@ -1011,7 +1011,7 @@
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+ contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName;
layer.open({
type: 2
@@ -1041,77 +1041,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- var titleData = ["hmainid", "HDeptID", "HMaterID", "HUnitID", "hsubid", "hmaterid2", "hunitid2", "HWHID", "HSPID"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
-
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
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;
- }
- //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
- if (dataCols[4] != null && dataCols[4] != "") {
- option.cols[0][i + 1]["title"] = dataCols[4];
- }
- //缁熻鍒�
- if (dataCols[6] == 1) {
- option.cols[0][i + 1]["totalRow"] = true;
- }
- }
-
- //鍙栨秷鍐荤粨鍒�
- 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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\346\227\245\350\256\241\345\210\222\345\267\245\345\215\225/JIT_DayPlanBillList.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\346\227\245\350\256\241\345\210\222\345\267\245\345\215\225/JIT_DayPlanBillList.html"
index c7c1d86..e5653f3 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\346\227\245\350\256\241\345\210\222\345\267\245\345\215\225/JIT_DayPlanBillList.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\346\227\245\350\256\241\345\210\222\345\267\245\345\215\225/JIT_DayPlanBillList.html"
@@ -620,8 +620,8 @@
function get_HideColumn() {
var colName = "";
var contentUrl = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
}
var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
var urlLen = urlStr.split('/');
@@ -630,7 +630,7 @@
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+ contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName;
layer.open({
type: 2
@@ -659,69 +659,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- var titleData = ["hmainid"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
-
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\350\256\241\345\210\222\345\271\263\345\217\260/JIT_DayPlanPlatForm.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\350\256\241\345\210\222\345\271\263\345\217\260/JIT_DayPlanPlatForm.html"
index 41221f7..c72e002 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\350\256\241\345\210\222\345\271\263\345\217\260/JIT_DayPlanPlatForm.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\350\256\241\345\210\222\345\271\263\345\217\260/JIT_DayPlanPlatForm.html"
@@ -838,7 +838,7 @@
var oneday = 1000 * 60 * 60 * 24;
columns.push({ type: 'checkbox', fixed: 'left', sort: true });
- columns.push({ type: 'numbers', title: '搴忓彿', sort: true });
+ columns.push({ type: 'numbers', field: '搴忓彿', title: '搴忓彿', sort: true });
columns.push({ field: '鍗曟嵁鍙�', title: '鍗曟嵁鍙�', hide: true, sort: true });
columns.push({ field: '閿�鍞鍗曞彿', title: '閿�鍞鍗曞彿', width: 150, sort: true });
columns.push({ field: '鐢熶骇璁㈠崟鍙�', title: '鐢熶骇璁㈠崟鍙�', width: 150, style: 'background-color: #f9f9f9;', sort: true });
@@ -3311,8 +3311,8 @@
function get_HideColumn() {
var colName = "";
var contentUrl = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
}
var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
var urlLen = urlStr.split('/');
@@ -3321,7 +3321,7 @@
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+ contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName;
layer.open({
type: 2
@@ -3350,71 +3350,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- var titleData = ["鍗曟嵁鍙�", "HProdORGID", "HMaterID", "HUnitID", "HWorkShopID", "HSourceID"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
-
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
dataCol = data1.data[0].HGridString.split(',');
-
- for (var i = 0; i < option.cols[0].length - 2; i++) {
- if (dataCol[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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\350\256\241\345\210\222\345\271\263\345\217\260/JIT_DayPlanPlatForm_TK.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\350\256\241\345\210\222\345\271\263\345\217\260/JIT_DayPlanPlatForm_TK.html"
index 5657fda..fa2afbb 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\350\256\241\345\210\222\345\271\263\345\217\260/JIT_DayPlanPlatForm_TK.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\350\256\241\345\210\222\345\271\263\345\217\260/JIT_DayPlanPlatForm_TK.html"
@@ -12,6 +12,7 @@
<script src="../../../layuiadmin/PubCustom.js"></script>
<script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
<script src="../../../layuiadmin/soulTable.slim.js"></script>
+ <script src="../../../layuiadmin/modules//tableFilter2.js"></script>
</head>
<body>
<div class="layui-fluid">
@@ -347,7 +348,8 @@
, laydate = layui.laydate
, excel = layui.excel
, soulTable = layui.soulTable
- , element = layui.element;
+ , element = layui.element
+ , tableFilter = layui.tableFilter;
var ins;
var sWhere = "";
var sWhere_ICMO = "";
@@ -870,7 +872,7 @@
var oneday = 1000 * 60 * 60 * 24;
columns.push({ type: 'checkbox', fixed: 'left', sort: true });
- columns.push({ type: 'numbers', title: '搴忓彿', sort: true });
+ columns.push({ type: 'numbers', field: '搴忓彿',title: '搴忓彿', sort: true });
columns.push({ field: '鍗曟嵁鍙�', title: '鍗曟嵁鍙�', hide: true, sort: true });
columns.push({ field: '閿�鍞鍗曞彿', title: '閿�鍞鍗曞彿', width: 150, sort: true });
columns.push({ field: '鐢熶骇璁㈠崟鍙�', title: '鐢熶骇璁㈠崟鍙�', width: 150, style: 'background-color: #f9f9f9;', sort: true });
@@ -1087,10 +1089,11 @@
elem: '#mainTable'
, toolbar: '#toolbarDemo'
, height: 'full-120'
- , page: false
+ , page: true
, cellMinWidth: 90
, cols: [columns]
- , limit: Number.MAX_VALUE//榛樿鏄剧ず鍏ㄩ儴
+ , limit: 500//榛樿鏄剧ず鍏ㄩ儴
+ , limits: [500,1000,1500,3000,5000,10000,20000]
, done: function (res, page, count) {
soulTable.render(this);
$('.layui-table thead').on('click', 'th', function () {
@@ -1132,7 +1135,7 @@
//for (var i = 0; i < HBackgroundColorIndex.length;i++) {
// $("tr[data-index='" + i + "']").attr({ "style": "background:#F74848;color:black;" });
- //}
+ //}
}
}
}
@@ -1175,8 +1178,10 @@
data: { "sWhere": sWhere, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.count == 1) {
+
option.data = data1.data;
ins = table.render(option);
+
var HinterID_S = [];
for (var i = 0; i < data1.data.length; i++) {
HinterID_S.push(data1.data[i]["hmainid"]);
@@ -3278,16 +3283,16 @@
//鍒犻櫎瀛愯〃鏁版嵁 浼氬崰鐢ㄦ暟缁勭殑浣嶇疆,闇�瑕侀噸鏂版帓涓�涓嬮『搴�
var num = [];
- for (var i = 0; i < table.cache["mainTable"].length; i++) {
- if (table.cache["mainTable"][i] != "") {
- if (parseFloat(table.cache["mainTable"][i]["鎷嗗崟鏁伴噺"]) == 0) {
+ for (var i = 0; i < option.data.length; i++) {
+ if (option.data[i] != "") {
+ if (parseFloat(option.data[i]["鎷嗗崟鏁伴噺"]) == 0) {
return layer.msg("绗�" + (i + 1) + "琛�,鎷嗕骇鏁伴噺鏈夎,璇烽噸鏂拌緭鍏�!");
}
- if (parseFloat(table.cache["mainTable"][i]["鎷嗗崟鏁伴噺"]) - parseFloat(table.cache["mainTable"][i]["鎷嗗崟姹囨姤鏁伴噺"]) < parseFloat(table.cache["mainTable"][i]["鏃ヨ鍒掓暟閲忔�婚噺"])) { // - 宸叉眹鎶ユ暟閲�
+ if (parseFloat(option.data[i]["鎷嗗崟鏁伴噺"]) - parseFloat(option.data[i]["鎷嗗崟姹囨姤鏁伴噺"]) < parseFloat(option.data[i]["鏃ヨ鍒掓暟閲忔�婚噺"])) { // - 宸叉眹鎶ユ暟閲�
return layer.msg("绗�" + (i + 1) + "琛�,鎺掍骇鏁伴噺瓒呭嚭璁㈠崟鏁伴噺!");
}
- table.cache["mainTable"][i].LAY_TABLE_INDEX = i;
- num.push(table.cache["mainTable"][i])
+ option.data[i].LAY_TABLE_INDEX = i;
+ num.push(option.data[i])
}
}
@@ -3803,8 +3808,8 @@
function get_HideColumn() {
var colName = "";
var contentUrl = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
}
var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
var urlLen = urlStr.split('/');
@@ -3813,7 +3818,7 @@
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+ contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName;
layer.open({
type: 2
@@ -3842,71 +3847,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- var titleData = ["鍗曟嵁鍙�", "HProdORGID", "HMaterID", "HUnitID", "HWorkShopID", "HSourceID"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
-
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
dataCol = data1.data[0].HGridString.split(',');
-
- for (var i = 0; i < option.cols[0].length - 2; i++) {
- if (dataCol[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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\350\256\241\345\210\222\345\271\263\345\217\260/Sc_ICMOSortBillList.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\350\256\241\345\210\222\345\271\263\345\217\260/Sc_ICMOSortBillList.html"
index 640c6c0..ab766fa 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\350\256\241\345\210\222\345\271\263\345\217\260/Sc_ICMOSortBillList.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\350\256\241\345\210\222\345\271\263\345\217\260/Sc_ICMOSortBillList.html"
@@ -440,8 +440,8 @@
function get_HideColumn() {
var colName = "";
var contentUrl = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
}
var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
var urlLen = urlStr.split('/');
@@ -450,7 +450,7 @@
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+ contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName;
layer.open({
type: 2
@@ -479,69 +479,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- var titleData = ["hmainid"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
-
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\350\246\201\346\226\231\350\256\241\345\210\222/JIT_NeedMaterPlanBillList.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\350\246\201\346\226\231\350\256\241\345\210\222/JIT_NeedMaterPlanBillList.html"
index cf78efb..b7f516c 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\350\246\201\346\226\231\350\256\241\345\210\222/JIT_NeedMaterPlanBillList.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\350\246\201\346\226\231\350\256\241\345\210\222/JIT_NeedMaterPlanBillList.html"
@@ -470,6 +470,8 @@
table.render(option);
layer.close(ajaxLoad);
//layer.alert("鏌ヨ鎴愬姛", { icon: 1 });
+
+ DisPlay_HideColumn();
} else {
layer.close(ajaxLoad);
layer.alert(result.code + result.Message, { icon: 5 });
@@ -478,16 +480,15 @@
layer.close(ajaxLoad);
layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
}
- });
- DisPlay_HideColumn();
+ });
}
//闅愯棌鍒楄缃�
function get_HideColumn() {
var colName = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
@@ -499,7 +500,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["50%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ['../../鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName, "yes"]
+ , content: ['../../鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName, "yes"]
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鍒锋柊琛ㄦ牸鏁版嵁
@@ -518,69 +519,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- var titleData = ["HMaterID", "HUnitID", "HICMOEmpID"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
-
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\351\275\220\345\245\227\345\210\206\346\236\220/JIT_CompleteDetailList.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\351\275\220\345\245\227\345\210\206\346\236\220/JIT_CompleteDetailList.html"
index af1cf4f..c354f7c 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\351\275\220\345\245\227\345\210\206\346\236\220/JIT_CompleteDetailList.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\351\275\220\345\245\227\345\210\206\346\236\220/JIT_CompleteDetailList.html"
@@ -574,8 +574,8 @@
function get_HideColumn(value) {
var colName = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ for (var i = 1; i < option.cols[0].length; i++) {
+ colName += option.cols[0][i]["field"] + ",";
}
var contentUrl = "";
@@ -586,7 +586,7 @@
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+ contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName;
layer.open({
type: 2
@@ -616,67 +616,82 @@
async: false,
success: function (data1) {
if (data1.data.length != 0) {
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
-
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\350\256\241\345\210\222\347\256\241\347\220\206/\345\267\245\350\211\272\350\267\257\347\272\277/Gy_RoutingBill.html" "b/WebTM/views/\350\256\241\345\210\222\347\256\241\347\220\206/\345\267\245\350\211\272\350\267\257\347\272\277/Gy_RoutingBill.html"
index 63f6422..15695ad 100644
--- "a/WebTM/views/\350\256\241\345\210\222\347\256\241\347\220\206/\345\267\245\350\211\272\350\267\257\347\272\277/Gy_RoutingBill.html"
+++ "b/WebTM/views/\350\256\241\345\210\222\347\256\241\347\220\206/\345\267\245\350\211\272\350\267\257\347\272\277/Gy_RoutingBill.html"
@@ -648,7 +648,7 @@
, { field: 'HQCSchemeID_Patrol', title: '宸℃妫�楠屾柟妗圛D', hide: true }//f7
, { field: 'HQCSchemeNumber_Patrol', title: '宸℃妫�楠屾柟妗堜唬鐮�', edit: 'text', event: "HQCSchemeNumber_Patrol", width: 125 }
, { field: 'HQCSchemeName_Patrol', title: '宸℃妫�楠屾柟妗堝悕绉�', width: 125 }//f7
-
+ , { field: 'HWorkQty', title: '鍔犲伐鏁伴噺', edit: 'text', width: 125}
//, { field: 'HPassRate', title: '鑹巼', edit: 'text' }//榛樿
//, { field: 'HProcID_S', title: '宸ユ', edit: 'text' }
////, { field: 'HCenterID_S', title: '浜х嚎涓績id', hide: true }//hide: true
diff --git "a/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\345\205\263\351\224\256\344\273\266\347\273\221\345\256\232/Sc_KeyElementBindingList.html" "b/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\345\205\263\351\224\256\344\273\266\347\273\221\345\256\232/Sc_KeyElementBindingList.html"
index 3f9bd27..caf40b5 100644
--- "a/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\345\205\263\351\224\256\344\273\266\347\273\221\345\256\232/Sc_KeyElementBindingList.html"
+++ "b/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\345\205\263\351\224\256\344\273\266\347\273\221\345\256\232/Sc_KeyElementBindingList.html"
@@ -805,7 +805,7 @@
var colName = "";
var contentUrl = "";
for (var i = 1; i < option.cols[0].length; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ colName += option.cols[0][i]["field"] + ",";
}
var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
var urlLen = urlStr.split('/');
@@ -814,7 +814,7 @@
}
colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+ contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName;
layer.open({
type: 2
@@ -841,73 +841,84 @@
url: GetWEBURL() + '/Xt_grdAlignment_WMES/grdAlignmentWMESList',
type: "GET",
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
- success: function (data1) {
+ success: function (data1) {
if (data1.data.length != 0) {
-
+ titleData = ["hmainid", "HMainEmpID", "HDeptID", "HGroupID", "HOrgID", "hsubid", "HMaterID", "HUnitID", "HEmpID", "HSourceID", "HBadReasonID", "HICMOInterID", "HICMOEntryID", "HICMOBillNo", "HProcExchInterID", "HProcExchEntryID", "HSourceInterID", "HSourceEntryID", "HSourceBillNo", "HSourceBillType", "HBarCode", "HReportType", "HAddr", "HMaker", "HMakeDate", "HMainSourceInterID", "HMainSourceEntryID", "HMainSourceBillNo", "HMainSourceBillType"];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- //var titleData = ["鍗曟嵁ID", "HMouldID", "hsubid", "HManagerID", "婧愬崟涓诲唴鐮�", "婧愬崟瀛愬唴鐮�"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
- //涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
- var titleData = ["hmainid", "HMainEmpID", "HDeptID", "HGroupID", "HOrgID", "hsubid", "HMaterID", "HUnitID", "HEmpID", "HSourceID", "HBadReasonID", "HICMOInterID", "HICMOEntryID", "HICMOBillNo", "HProcExchInterID", "HProcExchEntryID", "HSourceInterID", "HSourceEntryID", "HSourceBillNo", "HSourceBillType", "HBarCode", "HReportType", "HAddr", "HMaker", "HMakeDate", "HMainSourceInterID", "HMainSourceEntryID", "HMainSourceBillNo", "HMainSourceBillType"];
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
dataCol = data1.data[0].HGridString.split(',');
-
- for (var i = 0; i < option.cols[0].length - 1; i++) {
- if (dataCol[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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\346\212\245\350\241\250\345\210\206\346\236\220/Mes_OrderProcFlowAllReport.html" "b/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\346\212\245\350\241\250\345\210\206\346\236\220/Mes_OrderProcFlowAllReport.html"
index ba7d52e..3751d26 100644
--- "a/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\346\212\245\350\241\250\345\210\206\346\236\220/Mes_OrderProcFlowAllReport.html"
+++ "b/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\346\212\245\350\241\250\345\210\206\346\236\220/Mes_OrderProcFlowAllReport.html"
@@ -389,7 +389,7 @@
//闅愯棌鍒楄缃�
function get_HideColumn() {
var colName = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
+ for (var i = 1; i < option.cols[0].length; i++) {
colName += option.cols[0][i]["field"] + ",";
}
@@ -402,7 +402,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["50%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ['../../鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName, "yes"]
+ , content: ['../../鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName, "yes"]
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鍒锋柊琛ㄦ牸鏁版嵁
@@ -442,72 +442,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- var titleData = [];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
-
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
dataCol = data1.data[0].HGridString.split(',');
-
- for (var i = 0; i < option.cols[0].length - 2; i++) {
- if (dataCol[i]) {
- var dataCols = dataCol[i].split('|');
- }
- //闅愯棌鍒�
- if (dataCols[1] == 1) {
- option.cols[0][i + 1]["hide"] = true;
- }
- //璁剧疆鍐呭瀛椾綋澶у皬
- 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 (dataCols[3] > 0) {
- option.cols[0][i + 1]["width"] = dataCols[3];
- }
- //鏄剧ず鍒�
- if (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
- option.cols[0][i + 1]["hide"] = false;
- }
- //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
- if (dataCols[4] != null && dataCols[4] != "") {
- option.cols[0][i + 1]["title"] = dataCols[4];
- }
- //缁熻鍒�
- if (dataCols[6] == 1) {
- option.cols[0][i + 1]["totalRow"] = true;
- }
- //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
- 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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\346\212\245\350\241\250\345\210\206\346\236\220/Mes_OrderProcFlowAllReport_ICMO.html" "b/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\346\212\245\350\241\250\345\210\206\346\236\220/Mes_OrderProcFlowAllReport_ICMO.html"
index c207d66..723f5f5 100644
--- "a/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\346\212\245\350\241\250\345\210\206\346\236\220/Mes_OrderProcFlowAllReport_ICMO.html"
+++ "b/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\346\212\245\350\241\250\345\210\206\346\236\220/Mes_OrderProcFlowAllReport_ICMO.html"
@@ -416,7 +416,7 @@
//闅愯棌鍒楄缃�
function get_HideColumn() {
var colName = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
+ for (var i = 1; i < option.cols[0].length; i++) {
colName += option.cols[0][i]["field"] + ",";
}
@@ -429,7 +429,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["50%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ['../../鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName, "yes"]
+ , content: ['../../鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName, "yes"]
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鍒锋柊琛ㄦ牸鏁版嵁
@@ -469,70 +469,82 @@
data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
success: function (data1) {
if (data1.data.length != 0) {
-
+ titleData = [];
var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- var titleData = [];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
-
+ var newCols = [[]];//瀵瑰簲鏁版嵁搴撳垪椤哄簭col
+ newCols[0].push(option.cols[0][0]);//鏀惧叆绗竴涓猚heckbox
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 (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 (dataCols[3] > 0) {
- option.cols[0][i + 1]["width"] = dataCols[3];
- }
- //鏄剧ず鍒�
- if (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
- option.cols[0][i + 1]["hide"] = false;
- }
- //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
- if (dataCols[4] != null && dataCols[4] != "") {
- option.cols[0][i + 1]["title"] = dataCols[4];
- }
- //缁熻鍒�
- if (dataCols[6] == 1) {
- option.cols[0][i + 1]["totalRow"] = true;
- }
- //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
- 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;
+ //鍒楄缃垪鏁颁笌椤甸潰鍒楁暟鏄惁涓�鑷�
+ if (dataCol.length == option.cols[0].length - 1) {
+ //閬嶅巻瀵绘壘鍒楄缃搴斿垪鎸夐『搴忔彃鍏�
+ for (var j = 0; j < option.cols[0].length - 1; j++) {
+ for (var i = 0; i < option.cols[0].length - 1; i++) {
+ var dataCols = dataCol[j].split('|');
+ //閫夋嫨涓巇atacols鐩稿簲鍒楄繘琛屼慨鏀�
+ if (option.cols[0][i + 1]["field"] == dataCols[5]) {
+ //闅愯棌鍒�
+ 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 (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
+ option.cols[0][i + 1]["hide"] = false;
+ }
+ //缁熻鍒�
+ if (dataCols[6] == 1) {
+ option.cols[0][i + 1]["totalRow"] = true;
+ }
+ //瀛椾綋鎵�鍦ㄤ綅缃�(宸� 灞呬腑 鍙�)
+ 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;
+ }
+ //璁剧疆琛ㄦ牸title灞炴�ф樉绀哄埆鍚�
+ if (dataCols[4] != null && dataCols[4] != "") {
+ option.cols[0][i + 1]["title"] = dataCols[4];
+ }
+ newCols[0].push(option.cols[0][i + 1]);
+ }
}
- option.cols[0][i + 1]["fixed"] = "left";
+ }
+ //閬嶅巻寰幆鍚庡垽鏂搴斿垪鏁版槸鍚︿竴鑷�
+ if (dataCol.length == newCols[0].length - 1) {
+ option.cols = newCols;
+ //鍙栨秷鍐荤粨鍒�
+ 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);
diff --git "a/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\345\272\224\344\273\230\345\215\225/Cg_PayableBillList.html" "b/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\345\272\224\344\273\230\345\215\225/Cg_PayableBillList.html"
index d2a88f8..40e6c9a 100644
--- "a/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\345\272\224\344\273\230\345\215\225/Cg_PayableBillList.html"
+++ "b/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\345\272\224\344\273\230\345\215\225/Cg_PayableBillList.html"
@@ -169,6 +169,7 @@
<!--<button type="button" class="layui-btn layui-btn-sm" lay-event="get_view"><i class="layui-icon layui-icon-form"></i>娴忚</button>-->
<button type="button" class="layui-btn layui-btn-sm " lay-event="set_DeleteBill" id="DeleteBill"><i class="layui-icon layui-icon-delete"></i>鍒犻櫎</button>
<button type="button" class="layui-btn layui-btn-sm " lay-event="get_Refresh" id="Refresh"><i class="layui-icon layui-icon-refresh-3"></i>鍒锋柊</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="get_LookDown_PayMentBill" id="get_LookDown_PayMentBill"><i class="layui-icon layui-icon-refresh-3"></i>涓嬫煡(浠樻鍗�)</button>
<button type="button" class="layui-btn layui-btn-sm " lay-event="btn-Audit" id="Audit"><i class="layui-icon layui-icon-radio"></i>瀹℃牳</button>
<button type="button" class="layui-btn layui-btn-sm " lay-event="btn-DeAudit" id="DeAudit"><i class="layui-icon layui-icon-circle"></i>鍙嶅鏍�</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="set_startCheckBill" id="set_startCheckBill"><i class="layui-icon layui-icon-form"></i>鍙戣捣瀹℃壒</button>
@@ -259,6 +260,10 @@
break;
//鍒锋柊
case 'get_Refresh': get_Refresh();
+ break;
+ //涓嬫煡浠樻鍗�
+ case 'get_LookDown_PayMentBill':
+ set_LookDownPayMentBill();
break;
//瀹℃牳鎸夐挳 锛�1:瀹℃牳銆�2:鍙嶅鏍革級
case 'btn-Audit':
@@ -886,6 +891,34 @@
}
//#endregion
+ //#region 涓嬫煡浠樻鍗�
+ function set_LookDownPayMentBill() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var hID = data[0].hmainid.toString();
+ layer.open({
+ type: 2
+ , area: ['100%', '100%']
+ , title: '涓嬫煡浠樻鍗�'
+ , closeBtn: 1
+ , shade: 0.6 //閬僵閫忔槑搴�
+ , maxmin: true //鍏佽鍏ㄥ睆鏈�灏忓寲
+ , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
+ , content: '../../鍩虹璧勬枡/閫氱敤鍩虹璧勬枡/Gy_GeneralLookDown.html?linterid=' + hID + '&HModName=YF_PayMentBillList'
+ , resize: false,
+ end: function () {
+
+ }
+ , cancel: function () {
+
+ }
+ })
+ } else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹紪杈戯紒');
+ }
+ }
+ //#endregion
//#region 鍙嶅鏍�/瀹℃牳鏁版嵁
function set_CheckBill(num) {
diff --git "a/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\351\207\207\350\264\255\350\256\242\345\215\225/Cg_POOrderBillList.html" "b/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\351\207\207\350\264\255\350\256\242\345\215\225/Cg_POOrderBillList.html"
index 712a5d8..f431a12 100644
--- "a/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\351\207\207\350\264\255\350\256\242\345\215\225/Cg_POOrderBillList.html"
+++ "b/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\351\207\207\350\264\255\350\256\242\345\215\225/Cg_POOrderBillList.html"
@@ -298,6 +298,7 @@
<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_LookDown_POStockInBill" id="get_LookDown_POStockInBill"><i class="layui-icon layui-icon-refresh-3"></i>涓嬫煡(閲囪喘鍗�)</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-view" id="view"><i class="layui-icon layui-icon-tips"></i>棰勮</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-print" id="print"><i class="layui-icon layui-icon-print"></i>鎵撳嵃</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="get_Refresh" id="Refresh"><i class="layui-icon layui-icon-refresh-3"></i>鍒锋柊</button>
@@ -483,6 +484,10 @@
break;
//浼樺厛绾�
case 'btn-yxj': set_Yxj();
+ break;
+ //涓嬫煡閲囪喘鍏ュ簱鍗�
+ case 'get_LookDown_POStockInBill':
+ set_LookDownPOStockInBill();
break;
case 'btn-back': set_Back();
break;
@@ -2301,6 +2306,35 @@
}
+ //#region 涓嬫煡閲囪喘鍏ュ簱鍗�
+ function set_LookDownPOStockInBill() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var hID = data[0].hmainid.toString();
+ layer.open({
+ type: 2
+ , area: ['100%', '100%']
+ , title: '涓嬫煡閲囪喘鍏ュ簱'
+ , closeBtn: 1
+ , shade: 0.6 //閬僵閫忔槑搴�
+ , maxmin: true //鍏佽鍏ㄥ睆鏈�灏忓寲
+ , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
+ , content: '../../鍩虹璧勬枡/閫氱敤鍩虹璧勬枡/Gy_GeneralLookDown.html?linterid=' + hID + '&HModName=Kf_POStockInBillList'
+ , resize: false,
+ end: function () {
+
+ }
+ , cancel: function () {
+
+ }
+ })
+ } else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹紪杈戯紒');
+ }
+ }
+ //#endregion
+
//蹇�熻繃婊�
function get_FastQuery(table, option,number) {
var HStatus = $("select[name='HStatus']").val();//
diff --git "a/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\345\217\221\350\264\247\351\200\232\347\237\245\345\215\225/Xs_SeOutStockBillList.html" "b/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\345\217\221\350\264\247\351\200\232\347\237\245\345\215\225/Xs_SeOutStockBillList.html"
index 60d8dbd..d8fdc6f 100644
--- "a/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\345\217\221\350\264\247\351\200\232\347\237\245\345\215\225/Xs_SeOutStockBillList.html"
+++ "b/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\345\217\221\350\264\247\351\200\232\347\237\245\345\215\225/Xs_SeOutStockBillList.html"
@@ -214,6 +214,7 @@
<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Edit" id="btn-Edit"><i class="layui-icon layui-icon-form"></i>缂栬緫</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Delete" id="btn-Delete"><i class="layui-icon layui-icon-delete"></i>鍒犻櫎</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="get_Refresh" id="get_Refresh"><i class="layui-icon layui-icon-refresh-3"></i>鍒锋柊</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="get_LookDown" id="get_LookDown"><i class="layui-icon layui-icon-refresh-3"></i>涓嬫煡</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-print" id="btn-print"><i class="layui-icon layui-icon-print"></i>鎵撳嵃</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="get_Exit" id="get_Exit"><i class="layui-icon layui-icon-logout"></i>閫�鍑�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="HideColumn" id="HideColumn"><i class="layui-icon layui-icon-form"></i>闅愯棌鍒楄缃�</button>
@@ -779,6 +780,10 @@
//鍒锋柊
case 'get_Refresh': get_Refresh();
break;
+ //涓嬫煡
+ case 'get_LookDown':
+ set_LookDown();
+ break;
//閫�鍑烘寜閽�
case 'get_Exit': Pub_Close(2);
break;
@@ -1027,6 +1032,34 @@
}
//#endregion
+ //#region 涓嬫煡閿�鍞嚭搴撳崟
+ function set_LookDown() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var hID = data[0].hmainid.toString();
+ layer.open({
+ type: 2
+ , area: ['100%', '100%']
+ , title: '涓嬫煡閿�鍞嚭搴撳崟'
+ , closeBtn: 1
+ , shade: 0.6 //閬僵閫忔槑搴�
+ , maxmin: true //鍏佽鍏ㄥ睆鏈�灏忓寲
+ , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
+ , content: '../../鍩虹璧勬枡/閫氱敤鍩虹璧勬枡/Gy_GeneralLookDown.html?linterid=' + hID + '&HModName=Kf_SellOutBillList'
+ , resize: false,
+ end: function () {
+ }
+ , cancel: function () {
+
+ }
+ })
+ } else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹紪杈戯紒');
+ }
+ }
+ //#endregion
+
//閲嶆柊鍚屾鎸夐挳
function set_ResCnz() {
var HBillno2 = $('#HBillno2').val();
diff --git "a/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\345\272\224\346\224\266\345\215\225/Xs_ReceivableBill.html" "b/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\345\272\224\346\224\266\345\215\225/Xs_ReceivableBill.html"
index a06f20a..ffbb5fc 100644
--- "a/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\345\272\224\346\224\266\345\215\225/Xs_ReceivableBill.html"
+++ "b/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\345\272\224\346\224\266\345\215\225/Xs_ReceivableBill.html"
@@ -764,11 +764,11 @@
var HQty = dataArray[i].鏁伴噺 - dataArray[i].鍏宠仈鏁伴噺; //鏁伴噺
rowdataEntry.push(
{
- "HMaterID": dataArray[i].hmaterid
+ "HMaterID": dataArray[i].HMaterID
, "鐗╂枡浠g爜": dataArray[i].鐗╂枡浠g爜
, "鐗╂枡鍚嶇О": dataArray[i].鐗╂枡鍚嶇О
, "瑙勬牸鍨嬪彿": dataArray[i].瑙勬牸鍨嬪彿
- , "HUnitID": dataArray[i].hunitid
+ , "HUnitID": dataArray[i].HUnitID
, "璁¢噺鍗曚綅": dataArray[i].璁¢噺鍗曚綅
, "HQty": dealDoubleToFixed(HQty, 1)
, "HPrice": dealDoubleToFixed(dataArray[i].鍗曚环, 3)
@@ -1281,7 +1281,7 @@
function changeHPrice() {
//#region 瀛愯〃 鏁版嵁妫�楠�
for (var i = 0; i < option.data.length; i++) {
- if (option.data[i]["HMaterID"] == "0") {
+ if (option.data[i]["HMaterID"] == "0" || option.data[i]["HMaterID"] == "" || option.data[i]["HMaterID"] == undefined) {
layer.msg("绗�" + (i + 1) + "琛岋細鐗╂枡鏈�夋嫨锛�");
return false;
} else {
@@ -1907,7 +1907,7 @@
, "鐗╂枡浠g爜": dataArray[i].鐗╂枡浠g爜
, "鐗╂枡鍚嶇О": dataArray[i].鐗╂枡鍚嶇О
, "瑙勬牸鍨嬪彿": dataArray[i].瑙勬牸鍨嬪彿
- , "HUnitID": dataArray[i].hunitid
+ , "HUnitID": dataArray[i].HUnitID
, "璁¢噺鍗曚綅": dataArray[i].璁¢噺鍗曚綅
, "HQty": dealDoubleToFixed(HQty, 1)
, "HPrice": dealDoubleToFixed(dataArray[i].鍗曚环, 3)
@@ -2376,7 +2376,7 @@
, "HDeptID": dataArray[0].HDeptID
, "HDeptName": dataArray[0].閮ㄩ棬
- , "HMangerID": dataArray[0].hmanagerid
+ , "HMangerID": dataArray[0].HManagerID
, "HMangerName": dataArray[0].涓荤
, "HEmpID": dataArray[0].HEmpID
, "HEmpName": dataArray[0].涓氬姟鍛�
@@ -2396,11 +2396,11 @@
for (var i = 0; i < dataArray.length; i++) {
rowdata.push(
{
- "HMaterID": dataArray[i].hmaterid
+ "HMaterID": dataArray[i].HMaterID
, "鐗╂枡浠g爜": dataArray[i].鐗╂枡浠g爜
, "鐗╂枡鍚嶇О": dataArray[i].鐗╂枡鍚嶇О
, "瑙勬牸鍨嬪彿": dataArray[i].瑙勬牸鍨嬪彿
- , "HUnitID": dataArray[i].hunitid
+ , "HUnitID": dataArray[i].HUnitID
, "璁¢噺鍗曚綅": dataArray[i].璁¢噺鍗曚綅
, "HQty": dealDoubleToFixed(dataArray[i].鏁伴噺, 1)
, "HPrice": dealDoubleToFixed(dataArray[i].鍗曚环, 3)
@@ -3390,7 +3390,7 @@
, "HDeptID": dataArray[0].HDeptID
, "HDeptName": dataArray[0].閮ㄩ棬
- , "HMangerID": dataArray[0].hmanagerid
+ , "HMangerID": dataArray[0].HManagerID
, "HMangerName": dataArray[0].涓荤
, "HEmpID": dataArray[0].HEmpID
, "HEmpName": dataArray[0].涓氬姟鍛�
@@ -3410,46 +3410,51 @@
//瀛愯〃 璧嬪��
var rowdataEntry = [];
- for (var i = 0; i < dataArray.length; i++) {
- var HQty = dataArray[i].鏁伴噺 * 1 - dataArray[i].鍏宠仈鏁伴噺;
- rowdataEntry.push(
- {
- "HMaterID": dataArray[i].hmaterid
- , "鐗╂枡浠g爜": dataArray[i].鐗╂枡浠g爜
- , "鐗╂枡鍚嶇О": dataArray[i].鐗╂枡鍚嶇О
- , "瑙勬牸鍨嬪彿": dataArray[i].瑙勬牸鍨嬪彿
- , "HUnitID": dataArray[i].hunitid
- , "璁¢噺鍗曚綅": dataArray[i].璁¢噺鍗曚綅
- , "HQty": dealDoubleToFixed(HQty, 1)
- , "HPrice": dealDoubleToFixed(dataArray[i].鍗曚环, 3)
- , "HTaxPrice": dealDoubleToFixed(dataArray[i].鍚◣鍗曚环, 3)
- , 'HDiscountRate': "1" //
- , 'HRelTaxPrice': dealDoubleToFixed(dataArray[i].鍚◣鍗曚环, 3)
- , "HTaxRate": dataArray[i].绋庣巼
- , 'HTaxMoney': "0" //
- , "HMoney": dealDoubleToFixed(HQty * dataArray[i].鍗曚环, 2)
- , 'HMoneyBB': dealDoubleToFixed(HQty * dataArray[i].鍗曚环 * dataArray[0].姹囩巼, 2)
- , 'HlineTotal': dealDoubleToFixed(HQty * dataArray[i].鍚◣鍗曚环, 2)
- , 'HlineTotalBB': dealDoubleToFixed(HQty * dataArray[i].鍚◣鍗曚环 * dataArray[0].姹囩巼, 2)
- , "HRemark": ""
+ try {
+ for (var i = 0; i < dataArray.length; i++) {
+ var HQty = dataArray[i].鏁伴噺 * 1 - dataArray[i].鍏宠仈鏁伴噺;
+ rowdataEntry.push(
+ {
+ "HMaterID": dataArray[i].HMaterID
+ , "鐗╂枡浠g爜": dataArray[i].鐗╂枡浠g爜
+ , "鐗╂枡鍚嶇О": dataArray[i].鐗╂枡鍚嶇О
+ , "瑙勬牸鍨嬪彿": dataArray[i].瑙勬牸鍨嬪彿
+ , "HUnitID": dataArray[i].HUnitID
+ , "璁¢噺鍗曚綅": dataArray[i].璁¢噺鍗曚綅
+ , "HQty": dealDoubleToFixed(HQty, 1)
+ , "HPrice": dealDoubleToFixed(dataArray[i].鍗曚环, 3)
+ , "HTaxPrice": dealDoubleToFixed(dataArray[i].鍚◣鍗曚环, 3)
+ , 'HDiscountRate': "1" //
+ , 'HRelTaxPrice': dealDoubleToFixed(dataArray[i].鍚◣鍗曚环, 3)
+ , "HTaxRate": dataArray[i].绋庣巼
+ , 'HTaxMoney': "0" //
+ , "HMoney": dealDoubleToFixed(HQty * dataArray[i].鍗曚环, 2)
+ , 'HMoneyBB': dealDoubleToFixed(HQty * dataArray[i].鍗曚环 * dataArray[0].姹囩巼, 2)
+ , 'HlineTotal': dealDoubleToFixed(HQty * dataArray[i].鍚◣鍗曚环, 2)
+ , 'HlineTotalBB': dealDoubleToFixed(HQty * dataArray[i].鍚◣鍗曚环 * dataArray[0].姹囩巼, 2)
+ , "HRemark": ""
- , "HSourceInterID": dataArray[i].hmainid
- , "HSourceEntryID": dataArray[i].hsubid
- , "HSourceBillNo": dataArray[i].鍗曟嵁鍙�
- , "HSourceBillType": dataArray[i].HBillType
- , "HRelationQty": "0"
- , "HRelationMoney": "0"
+ , "HSourceInterID": dataArray[i].hmainid
+ , "HSourceEntryID": dataArray[i].hsubid
+ , "HSourceBillNo": dataArray[i].鍗曟嵁鍙�
+ , "HSourceBillType": dataArray[i].HBillType
+ , "HRelationQty": "0"
+ , "HRelationMoney": "0"
- , 'HPOOrderInterID': "0"
- , 'HPOOrderEntryID': "0"
- , 'HPOOrderBillNo': ""
+ , 'HPOOrderInterID': "0"
+ , 'HPOOrderEntryID': "0"
+ , 'HPOOrderBillNo': ""
- , 'HSeOrderTaxPrice': dealDoubleToFixed(dataArray[i].鍚◣鍗曚环, 3)
- , "HSeOrderInterID": dataArray[i].HSourceBillType == "1401" ? dataArray[i].HSourceInterID : "0"
- , "HSeOrderEntryID": dataArray[i].HSourceBillType == "1401" ? dataArray[i].HSourceEntryID : "0"
- , "HSeOrderBillNo": dataArray[i].HSourceBillType == "1401" ? dataArray[i].婧愬崟鍗曞彿 : ""
- }
- );
+ , 'HSeOrderTaxPrice': dealDoubleToFixed(dataArray[i].鍚◣鍗曚环, 3)
+ , "HSeOrderInterID": dataArray[i].HSourceBillType == "1401" ? dataArray[i].HSourceInterID : "0"
+ , "HSeOrderEntryID": dataArray[i].HSourceBillType == "1401" ? dataArray[i].HSourceEntryID : "0"
+ , "HSeOrderBillNo": dataArray[i].HSourceBillType == "1401" ? dataArray[i].婧愬崟鍗曞彿 : ""
+ }
+ );
+ }
+ }
+ catch (error) {
+ layer.alert(error.Message, { icon: 5 });
}
optionEntry.data = JSON.parse(JSON.stringify(rowdataEntry));
@@ -3539,7 +3544,7 @@
async: false, //鏄惁寮�鍚紓姝�
type: "GET", //璇锋眰绫诲瀷
data: { //瀹氫箟鍙戦�佸埌鏈嶅姟鍣ㄧ殑鏁版嵁
- "HMaterID": HMaterID // 灏唄materid浣滀负璇锋眰鍙傛暟鍙戦��
+ "HMaterID": HMaterID // 灏咹MaterID浣滀负璇锋眰鍙傛暟鍙戦��
},
success: function (result) { // 褰撹姹傛垚鍔熸椂锛屾墽琛岃繖涓嚱鏁�
if (result.code == 1) { // 濡傛灉鏈嶅姟鍣ㄨ繑鍥炵殑鏁版嵁涓殑`code瀛楁绛変簬1锛岃繖鍙兘琛ㄧず瀹℃牳鎿嶄綔鎴愬姛鎵ц
diff --git "a/WebTM/views/\351\241\271\347\233\256\347\256\241\347\220\206/\345\267\245\344\275\234\344\273\273\345\212\241/PM_WorkTaskBillList.html" "b/WebTM/views/\351\241\271\347\233\256\347\256\241\347\220\206/\345\267\245\344\275\234\344\273\273\345\212\241/PM_WorkTaskBillList.html"
index a0a6128..ab6095f 100644
--- "a/WebTM/views/\351\241\271\347\233\256\347\256\241\347\220\206/\345\267\245\344\275\234\344\273\273\345\212\241/PM_WorkTaskBillList.html"
+++ "b/WebTM/views/\351\241\271\347\233\256\347\256\241\347\220\206/\345\267\245\344\275\234\344\273\273\345\212\241/PM_WorkTaskBillList.html"
@@ -178,6 +178,7 @@
<!--<button type="button" class="layui-btn layui-btn-sm" lay-event="get_view"><i class="layui-icon layui-icon-form"></i>娴忚</button>-->
<button type="button" class="layui-btn layui-btn-sm" lay-event="set_DeleteBill" id="set_DeleteBill"><i class="layui-icon layui-icon-delete"></i>鍒犻櫎</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="get_Refresh" id="get_Refresh"><i class="layui-icon layui-icon-refresh-3"></i>鍒锋柊</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="get_export" id="get_export"><i class="layui-icon layui-icon-export"></i>瀵煎嚭</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Audit" id="Audit"><i class="layui-icon layui-icon-radio"></i>瀹℃牳</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeAudit" id="DeAudit"><i class="layui-icon layui-icon-circle"></i>鍙嶅鏍�</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-BatchAudit" id="BatchAudit"><i class="layui-icon layui-icon-radio"></i>鎵归噺瀹℃牳</button>
@@ -280,6 +281,10 @@
break;
//鍒锋柊
case 'get_Refresh': get_Refresh();
+ break;
+ //瀵煎嚭excel
+ case 'get_export':
+ get_Export();
break;
//鍌績鎸夐挳
case 'get_HHasten': get_HHasten();
@@ -595,7 +600,7 @@
option.cols = [col];
option.data = data1.data;
laypage.render(optionPage);
- table.render(option);
+ ins= table.render(option);
//鍒锋柊琛ㄦ牸鏁版嵁
DisPlay_HideColumn();
if ($("#Comparator").val() == 0 && $("#ColContent").val() == "") {
@@ -875,6 +880,196 @@
}
//#endregion
+ //#region 瀵煎嚭Execel
+ function get_Export() {
+ //var ModRightNameCheck = "Gy_RoutingBillList_ExportExcel";
+ //var wait = layer.load();
+ var data = getExportData();
+ data.forEach((item) => {
+ for (let itemobj in item) {
+ if (item[itemobj] == null) {
+ item[itemobj] = "";
+ }
+ if (item[itemobj].length > 0) { // 鍋囪瀛楁鍚嶄负field
+ item[itemobj] = item[itemobj].toString().replace(/[\r\n]+/g, ''); // 灏嗘崲琛岀鏇挎崲涓虹┖瀛楃涓�
+ }
+ }
+ });
+ table.exportFile(ins.config.id, data, "xls");
+ //閫昏緫瀹℃牳鏂规硶
+ //$.ajax({
+ // type: "GET",
+ // url: GetWEBURL() + "/LMES/getReportByModRightNameCheck", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ // async: true,
+ // data: { "ModRightNameCheck": ModRightNameCheck, "user": sessionStorage["HUserName"] },
+ // success: function (result) {
+
+ // var data = getExportData();
+ // data.forEach((item) => {
+ // for (let itemobj in item) {
+ // if (item[itemobj] == null) {
+ // item[itemobj] = "";
+ // }
+ // if (item[itemobj].length > 0) { // 鍋囪瀛楁鍚嶄负field
+ // item[itemobj] = item[itemobj].toString().replace(/[\r\n]+/g, ''); // 灏嗘崲琛岀鏇挎崲涓虹┖瀛楃涓�
+ // }
+ // }
+ // });
+ // if (result.count == 1) {
+ // table.exportFile(ins.config.id, data, "xls");
+ // layer.close(wait);
+ // } else {
+ // layer.alert("褰撳墠妯″潡娌℃湁瀵煎嚭鏉冮檺!", { icon: 5 });
+ // layer.close(wait);
+ // }
+ // }, error: function () {
+ // layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ // layer.close(wait);
+ // }
+ //});
+ }
+ //#endregion
+
+ //#region 鑾峰彇瀵煎嚭鏁版嵁
+ function getExportData() {
+ var data;//瀵煎嚭鐨勬暟鎹�
+ var ajaxLoad = layer.load();
+ //鑾峰彇鐧诲綍璐︽埛瀵瑰簲鑱屽憳鍚嶇О
+ var HUserName = getHEmpByHUserName();
+ if (HUserName != "" && HUserName != null) {
+ sWhere += " and (娲惧崟浜� = '" + HUserName + "' or 鎺ュ崟浜� = '" + HUserName + "' or 鎶勯�佷汉 like '%" + HUserName + "%') ";
+ }
+
+ var HOrgID = "";
+ var HBillNo = $("#HBillNo").val(); //鍗曟嵁鍙�
+ var HProNumber = $("#HProNumber").val();//椤圭洰浠g爜
+ var HName = $("#HName").val();//宸ヤ綔鍚嶇О
+ var HBillStatus = $("#HBillStatus").val();//鍗曟嵁鐘舵��
+ var HReceiveEmp = $("#HReceiveEmp").val();//鎺ュ崟浜�
+ var ColName = $("#ColName").val();//澶嶉�夋
+ var Comparator = $("#Comparator").val()
+ var ColContent = $("#ColContent").val();
+ var ColName1 = $("#ColName1").val();//澶嶉�夋
+ var Comparator1 = $("#Comparator1").val()
+ var ColContent1 = $("#ColContent1").val();
+ var ColName2 = $("#ColName2").val();//澶嶉�夋
+ var Comparator2 = $("#Comparator2").val()
+ var ColContent2 = $("#ColContent2").val();
+
+ if (ColName != 0 && Comparator != 0) {
+ var com = "";
+ switch (Comparator) {
+ case "7":
+ com = "like'%" + ColContent + "%'";
+ break;
+ case "8":
+ com = "like'%" + ColContent + "'";
+ break;
+ case "9":
+ com = "like'" + ColContent + "%'";
+ break;
+ case "10":
+ com = "not like'%" + ColContent + "%'";
+ break;
+ default:
+ com = "" + Comparator + "'" + ColContent + "'";
+ break;
+ }
+ sWhere += " and " + ColName + " " + com;
+ }
+ if (ColName1 != 0 && Comparator1 != 0) {
+ var com1 = "";
+ switch (Comparator1) {
+ case "7":
+ com1 = "like'%" + ColContent1 + "%'";
+ break;
+ case "8":
+ com1 = "like'%" + ColContent1 + "'";
+ break;
+ case "9":
+ com1 = "like'" + ColContent1 + "%'";
+ break;
+ case "10":
+ com1 = "not like'%" + ColContent1 + "%'";
+ break;
+ default:
+ com1 = "" + Comparator1 + "'" + ColContent1 + "'";
+ break;
+ }
+ sWhere += " and " + ColName1 + " " + com1;
+ }
+ if (ColName2 != 0 && Comparator2 != 0) {
+ var com2 = "";
+ switch (Comparator2) {
+ case "7":
+ com2 = "like'%" + ColContent2 + "%'";
+ break;
+ case "8":
+ com2 = "like'%" + ColContent2 + "'";
+ break;
+ case "9":
+ com2 = "like'" + ColContent2 + "%'";
+ break;
+ case "10":
+ com2 = "not like'%" + ColContent2 + "%'";
+ break;
+ default:
+ com2 = "" + Comparator + "'" + ColContent + "'";
+ break;
+ }
+ sWhere += " and " + ColName2 + " " + com2;
+ }
+ if (addSWhereByOpenType()) {
+ HOrgID = $("#HOrgID").val();//缁勭粐
+ }
+ else {
+ HOrgID = $("#HOrgID").val();//缁勭粐
+ }
+ if (HBillNo) {
+ sWhere += " and 鍗曟嵁鍙� like '%" + HBillNo + "%'";
+ }
+ if (HProNumber) {
+ sWhere += " and 椤圭洰浠g爜 like '%" + HProNumber + "%'";
+ }
+ if (HName) {
+ sWhere += " and 浠诲姟鍚嶇О like '%" + HName + "%'";
+ }
+ if (HOrgID) {
+ sWhere += " and HOrgID = '" + HOrgID + "'";
+ }
+ if (HBillStatus) {
+ sWhere += " and 鍗曟嵁鐘舵�� like '%" + HBillStatus + "%'";
+ }
+ if (HReceiveEmp) {
+ sWhere += " and 鎺ュ崟浜� like '%" + HReceiveEmp + "%'";
+ }
+ //鏌ヨ璇彞
+ $.ajax({
+ url: GetWEBURL() + '/PM_WorkTaskBill/list',
+ type: "GET",
+ async: false,
+ data: { "sWhere": sWhere, "user": sessionStorage["HUserName"]},
+ success: function (data1) {
+ if (data1.count == 1) {
+ data = data1.data;//鍒楀瓧娈垫暟鎹�
+ layer.close(ajaxLoad);
+ //layer.alert("鏌ヨ鎴愬姛", { icon: 1 });
+ } else {
+ layer.close(ajaxLoad);
+ layer.alert(data1.code + data1.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.close(ajaxLoad);
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ sWhere = "";
+ return data;
+
+ }
+ //#endregion
+
+
//#region 鍙嶅鏍�/瀹℃牳鏁版嵁
function set_CheckBill(num) {
var checkStatus = table.checkStatus('mainTable')
diff --git "a/WebTM/views/\351\242\206\346\226\231\345\217\221\350\264\247/\351\224\200\345\224\256\345\207\272\345\272\223/Kf_SellOutBillList.html" "b/WebTM/views/\351\242\206\346\226\231\345\217\221\350\264\247/\351\224\200\345\224\256\345\207\272\345\272\223/Kf_SellOutBillList.html"
index 576797e..5556ea2 100644
--- "a/WebTM/views/\351\242\206\346\226\231\345\217\221\350\264\247/\351\224\200\345\224\256\345\207\272\345\272\223/Kf_SellOutBillList.html"
+++ "b/WebTM/views/\351\242\206\346\226\231\345\217\221\350\264\247/\351\224\200\345\224\256\345\207\272\345\272\223/Kf_SellOutBillList.html"
@@ -213,11 +213,12 @@
<button type="button" class="layui-btn layui-btn-sm" lay-event="set_AbandonCheck_Flow" id="AbandonCheck_Flow"><i class="layui-icon layui-icon-form"></i>澶氱骇鍙嶅鏍�</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="set_RejectCheck_Flow" id="RejectCheck_Flow"><i class="layui-icon layui-icon-form"></i>椹冲洖</button>
<!--<button type="button" class="layui-btn layui-btn-sm" lay-event="set_CloseBill" id="set_CloseBill"><i class="layui-icon layui-icon-form"></i>鍏抽棴</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="set_CancelCloseBill" id="set_CancelCloseBill"><i class="layui-icon layui-icon-form"></i>鍙嶅叧闂�</button>-->
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_CancelCloseBill" id="set_CancelCloseBill"><i class="layui-icon layui-icon-form"></i>鍙嶅叧闂�</button>-->
<!--<button type="button" class="layui-btn layui-btn-sm" lay-event="set_Drop" id="set_Drop"><i class="layui-icon layui-icon-radio"></i>浣滃簾</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="set_DeDrop" id="set_DeDrop"><i class="layui-icon layui-icon-radio"></i>鍙嶄綔搴�</button>-->
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_DeDrop" id="set_DeDrop"><i class="layui-icon layui-icon-radio"></i>鍙嶄綔搴�</button>-->
<button type="button" class="layui-btn layui-btn-sm" lay-event="get_BarCodeNote" id="get_BarCodeNote"><i class="layui-icon layui-icon-refresh-3"></i>鏉$爜鏄庣粏</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="get_LookDown" id="get_LookDown"><i class="layui-icon layui-icon-refresh-3"></i>涓嬫煡</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="get_LookDown_ReceivableBill" id="get_LookDown_ReceivableBill"><i class="layui-icon layui-icon-refresh-3"></i>涓嬫煡(搴旀敹鍗�)</button>
<button type="button" class="layui-btn layui-btn-sm" id="btn-print" lay-event="btn-print"><i class="layui-icon layui-icon-form"></i>鎵撳嵃</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="get_export" id="get_export"><i class="layui-icon layui-icon-export"></i>瀵煎嚭</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="get_Exit" id="get_Exit"><i class="layui-icon layui-icon-logout"></i>閫�鍑�</button>
@@ -395,6 +396,10 @@
//涓嬫煡
case 'get_LookDown':
set_LookDown();
+ break;
+ //涓嬫煡
+ case 'get_LookDown_ReceivableBill':
+ set_LookDownReceivableBill();
break;
//鎵撳嵃
case 'btn-print': get_PrintReport();
@@ -1712,6 +1717,35 @@
}
//#endregion
+ //#region 涓嬫煡搴旀敹鍗�
+ function set_LookDownReceivableBill() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var hID = data[0].hmainid.toString();
+ layer.open({
+ type: 2
+ , area: ['100%', '100%']
+ , title: '涓嬫煡搴旀敹鍗�'
+ , closeBtn: 1
+ , shade: 0.6 //閬僵閫忔槑搴�
+ , maxmin: true //鍏佽鍏ㄥ睆鏈�灏忓寲
+ , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
+ , content: '../../鍩虹璧勬枡/閫氱敤鍩虹璧勬枡/Gy_GeneralLookDown.html?linterid=' + hID + '&HModName=Xs_ReceivableBillList'
+ , resize: false,
+ end: function () {
+
+ }
+ , cancel: function () {
+
+ }
+ })
+ } else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹紪杈戯紒');
+ }
+ }
+ //#endregion
+
//#region 鎵撳嵃
function get_PrintReport() {
var checkStatus = table.checkStatus('mainTable')
diff --git "a/WebTM/views/\351\252\214\346\224\266\345\205\245\345\272\223/\345\244\226\350\264\255\345\205\245\345\272\223/Kf_POStockInBillList.html" "b/WebTM/views/\351\252\214\346\224\266\345\205\245\345\272\223/\345\244\226\350\264\255\345\205\245\345\272\223/Kf_POStockInBillList.html"
index cb2a817..a307dc2 100644
--- "a/WebTM/views/\351\252\214\346\224\266\345\205\245\345\272\223/\345\244\226\350\264\255\345\205\245\345\272\223/Kf_POStockInBillList.html"
+++ "b/WebTM/views/\351\252\214\346\224\266\345\205\245\345\272\223/\345\244\226\350\264\255\345\205\245\345\272\223/Kf_POStockInBillList.html"
@@ -206,6 +206,7 @@
<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Edit" id="Edit"><i class="layui-icon layui-icon-form"></i>缂栬緫</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Delete" id="Delete"><i class="layui-icon layui-icon-delete"></i>鍒犻櫎</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="get_Refresh" id="Refresh"><i class="layui-icon layui-icon-refresh-3"></i>鍒锋柊</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="get_LookDown_PayableBill" id="get_LookDown_PayableBill"><i class="layui-icon layui-icon-refresh-3"></i>涓嬫煡(搴斾粯鍗�)</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-BarCodeDetail" id="BarCodeDetail"><i class="layui-icon layui-icon-form"></i>鏉$爜鏄庣粏</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-PushPayableBills" id="btn-PushPayableBills"><i class="layui-icon layui-icon-delete"></i>澶氳涓嬫帹(搴斾粯鍗�)</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_CheckBill" id="CheckBill"><i class="layui-icon layui-icon-form"></i>瀹℃牳</button>
@@ -728,6 +729,10 @@
//鍒锋柊
case 'get_Refresh': get_Refresh();
break;
+ //涓嬫煡搴斾粯鍗�
+ case 'get_LookDown_PayableBill':
+ set_LookDown_PayableBill();
+ break;
//鎵撳嵃
case 'btn-print':
get_PrintReport();
@@ -980,6 +985,35 @@
}
//#endregion
+ //#region 涓嬫煡搴斾粯鍗�
+ function set_LookDown_PayableBill() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var hID = data[0].hmainid.toString();
+ layer.open({
+ type: 2
+ , area: ['100%', '100%']
+ , title: '涓嬫煡搴斾粯鍗�'
+ , closeBtn: 1
+ , shade: 0.6 //閬僵閫忔槑搴�
+ , maxmin: true //鍏佽鍏ㄥ睆鏈�灏忓寲
+ , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
+ , content: '../../鍩虹璧勬枡/閫氱敤鍩虹璧勬枡/Gy_GeneralLookDown.html?linterid=' + hID + '&HModName=Cg_PayableBillList'
+ , resize: false,
+ end: function () {
+
+ }
+ , cancel: function () {
+
+ }
+ })
+ } else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹紪杈戯紒');
+ }
+ }
+ //#endregion
+
//#region 鐐瑰嚮琛岄�変腑楂樹寒
table.on('row(mainTable)', function (obj) {
//閫変腑琛屾敼鍙橀鑹�
--
Gitblit v1.9.1