From 4a9c64d6092a389a357001a86634c7a9ab94b024 Mon Sep 17 00:00:00 2001
From: yusijie <ysj@hz-kingdee.com>
Date: 星期三, 26 三月 2025 15:04:19 +0800
Subject: [PATCH] 单据模块优化(器具保养记录单、器具点检计划单、器具点检记录单、上模单、下模单、模具投产验收单、器具故障登记单、器具维修派工单、器具维修记录单、器具维修验收单)
---
WebTM/views/模治具管理/模治具管理/Sc_MouldDotCheckPlanBillList.html | 607 +++++
WebTM/views/模治具管理/模治具管理/Sc_Add_MouldMaintainBillList.html | 106
WebTM/views/模治具管理/器具维修派工单/Sc_MouldRepairSendWorkBillEdit.html | 120 +
WebTM/views/模治具管理/模治具管理/Sc_Add_MouldRepairCheckBillList.html | 102
WebTM/views/模治具管理/上模单/Sc_MouldLowerBillList.html | 229 -
WebTM/views/模治具管理/器具维修派工单/Sc_MouldRepairSendWorkBillList.html | 478 ++++
WebTM/views/模治具管理/模具投产验收单/Sc_MouldBatchWorkCheckBillEdit.html | 10
WebTM/views/模治具管理/模治具管理/Sc_MouldMaintainPlanBillList.html | 27
WebTM/views/模治具管理/上模单/Sc_MouldUpperBillList.html | 226 -
WebTM/views/模治具管理/模治具管理/Sc_MouldMaintainBillList.html | 594 ++++-
WebTM/views/模治具管理/模治具管理/Sc_Add_MouldConkBookBillList.html | 105
WebTM/views/模治具管理/上模单/Sc_MouldLowerBillEdit.html | 12
WebTM/views/基础资料/基础资料/Gy_RepairList.html | 17
WebTM/views/模治具管理/模治具管理/Sb_Add_MouldRepairWorkBillList.html | 121
WebTM/views/基础资料/基础资料/Gy_DotCheckItemClassList.html | 28
WebTM/views/模治具管理/模治具管理/Sc_MouldConkBookBillList.html | 655 ++++-
WebTM/views/模治具管理/模治具管理/Sc_MouldRepairCheckBillList.html | 514 ++++
WebTM/views/设备管理/设备档案/Gy_EquipFileMainList.html | 30
WebTM/views/基础资料/生产基础资料/Gy_ShiftsList.html | 27
WebTM/views/模治具管理/上模单/Sc_MouldUpperBillEdit.html | 6
WebTM/views/模治具管理/模具投产验收单/Sc_MouldBatchWorkCheckBillList.html | 314 +-
WebTM/views/模治具管理/模治具管理/Sc_MouldDotCheckBillList.html | 675 ++++-
WebTM/views/基础资料/基础资料/Gy_ConkReasonList.html | 28
WebTM/views/基础资料/基础资料/Gy_DotCheckList.html | 28
WebTM/views/基础资料/基础资料/Gy_DotCheckItemMethodList.html | 28
WebTM/views/基础资料/基础资料/Gy_RepairCheckList.html | 28
WebTM/views/模治具管理/器具点检规程单/Sc_MouldDotCheckRuleBillList.html | 15
WebTM/views/模治具管理/模治具管理/Sb_MouldRepairWorkBillList.html | 631 ++++-
WebTM/views/模治具管理/模治具管理/Sc_Add_MouldDotCheckBillList.html | 111
WebTM/views/模治具管理/模治具管理/Sc_Add_MouldDotCheckPlanBillList.html | 115
WebTM/views/基础资料/公用基础资料/Gy_ConkType.html | 14
31 files changed, 4,680 insertions(+), 1,321 deletions(-)
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_ConkType.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_ConkType.html"
index 1ca00a1..6aea22f 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_ConkType.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_ConkType.html"
@@ -349,6 +349,7 @@
//#region 鏌ヨ
function get_Display(sWhere) {
var ajaxLoad = layer.load();
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
$.ajax({
url: GetWEBURL() + '/Gy_ConkType/list',
type: "GET",
@@ -779,6 +780,19 @@
function get_Export() {
table.exportFile(ins.config.id, option.data, "xls");
}
+ //#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and isnull(绂佺敤浜�,'') = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
//#endregion
//#endregion
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_ConkReasonList.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_ConkReasonList.html"
index 6abb630..cd6bcc7 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_ConkReasonList.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_ConkReasonList.html"
@@ -334,7 +334,8 @@
//鏌ヨ
function get_Display(sWhere) {
var index = layer.load(0, { shade: false });
- var ajaxLoad = layer.load();
+ var ajaxLoad = layer.load();
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
//杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
$.ajax({
url: GetWEBURL() + '/Gy_ConkReasonBill/Get_ConkReasonBillList',
@@ -796,6 +797,31 @@
}
//#endregion
+ //#region 鑾峰彇鍙傛暟
+ function getUrlVars() {
+ var vars = [], hash;
+ var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
+ for (var i = 0; i < hashes.length; i++) {
+ hash = hashes[i].split('=');
+ vars.push(hash[0]);
+ vars[hash[0]] = hash[1];
+ }
+ return vars;
+ }
+ //#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and 绂佺敤浜� = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
//#region 銆愯繃婊ゆ柟妗堛��
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemClassList.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemClassList.html"
index fbbb495..26fdc0f 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemClassList.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemClassList.html"
@@ -284,6 +284,7 @@
//鏌ヨ
function get_Display(sWhere) {
var ajaxLoad = layer.load();
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
//杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
$.ajax({
url: GetWEBURL() + '/Gy_DotCheckItemClass/GetDotCheckItemClassList',
@@ -686,6 +687,33 @@
form.render('select');
}
//#endregion
+
+ //#region 鑾峰彇鍙傛暟
+ function getUrlVars() {
+ var vars = [], hash;
+ var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
+ for (var i = 0; i < hashes.length; i++) {
+ hash = hashes[i].split('=');
+ vars.push(hash[0]);
+ vars[hash[0]] = hash[1];
+ }
+ return vars;
+ }
+ //#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and 绂佺敤浜� = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
+
//#region 銆愯繃婊ゆ柟妗堛��
//鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemMethodList.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemMethodList.html"
index 17fc606..bdfa193 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemMethodList.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckItemMethodList.html"
@@ -283,6 +283,7 @@
//鏌ヨ
function get_Display(sWhere) {
var ajaxLoad = layer.load();
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
//杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
$.ajax({
url: GetWEBURL() + '/Gy_DotCheckItemMethod/GetDotCheckItemMethodList',
@@ -701,6 +702,33 @@
form.render('select');
}
//#endregion
+
+ //#region 鑾峰彇鍙傛暟
+ function getUrlVars() {
+ var vars = [], hash;
+ var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
+ for (var i = 0; i < hashes.length; i++) {
+ hash = hashes[i].split('=');
+ vars.push(hash[0]);
+ vars[hash[0]] = hash[1];
+ }
+ return vars;
+ }
+ //#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and 绂佺敤浜� = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
+
//#region 銆愯繃婊ゆ柟妗堛��
//鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckList.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckList.html"
index 66bdf95..debab41 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckList.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DotCheckList.html"
@@ -402,6 +402,7 @@
//鏌ヨ
function get_Display(sWhere) {
var ajaxLoad = layer.load();
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
//杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
$.ajax({
url: GetWEBURL() + '/Gy_DotCheck/GetDotCheckList',
@@ -948,6 +949,33 @@
form.render('select');
}
//#endregion
+
+ //#region 鑾峰彇鍙傛暟
+ function getUrlVars() {
+ var vars = [], hash;
+ var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
+ for (var i = 0; i < hashes.length; i++) {
+ hash = hashes[i].split('=');
+ vars.push(hash[0]);
+ vars[hash[0]] = hash[1];
+ }
+ return vars;
+ }
+ //#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and 绂佺敤浜� = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
+
//#region 銆愯繃婊ゆ柟妗堛��
//鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_RepairCheckList.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_RepairCheckList.html"
index 103aa86..ce2a45e 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_RepairCheckList.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_RepairCheckList.html"
@@ -390,6 +390,7 @@
//鏌ヨ
function get_Display(sWhere) {
var ajaxLoad = layer.load();
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
//杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
$.ajax({
url: GetWEBURL() + '/Gy_RepairCheck/GetRepairCheckList',
@@ -940,6 +941,33 @@
form.render('select');
}
//#endregion
+
+ //#region 鑾峰彇鍙傛暟
+ function getUrlVars() {
+ var vars = [], hash;
+ var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
+ for (var i = 0; i < hashes.length; i++) {
+ hash = hashes[i].split('=');
+ vars.push(hash[0]);
+ vars[hash[0]] = hash[1];
+ }
+ return vars;
+ }
+ //#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and isnull(绂佺敤浜�,'') = '' and isnull(瀹℃牳浜�,'') != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
+
//#region 銆愯繃婊ゆ柟妗堛��
//鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_RepairList.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_RepairList.html"
index 166a03b..57333d0 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_RepairList.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\237\272\347\241\200\350\265\204\346\226\231/Gy_RepairList.html"
@@ -408,6 +408,7 @@
//鏌ヨ
function get_Display(sWhere) {
var ajaxLoad = layer.load();
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
//杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
$.ajax({
url: GetWEBURL() + '/Gy_Repair/GetRepairList',
@@ -877,7 +878,7 @@
$("#ColName2").append(Organization);
form.render('select');
}
- //#endregion
+ //#endregion
//#region 鑾峰彇鍙傛暟
function getUrlVars() {
@@ -891,6 +892,20 @@
return vars;
}
//#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and 绂佺敤浜� = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
+
//#region 銆愯繃婊ゆ柟妗堛��
//鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
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_ShiftsList.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_ShiftsList.html"
index 06853ee..dabe1f5 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_ShiftsList.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_ShiftsList.html"
@@ -851,6 +851,7 @@
else {
sWhere += " and 绂佺敤鏍囪='' and 瀹℃牳浜�<>''";
}
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
var ajaxLoad = layer.load();
$.ajax({
type: "GET",
@@ -948,6 +949,32 @@
}
//#endregion
+ //#region 鑾峰彇鍙傛暟
+ function getUrlVars() {
+ var vars = [], hash;
+ var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
+ for (var i = 0; i < hashes.length; i++) {
+ hash = hashes[i].split('=');
+ vars.push(hash[0]);
+ vars[hash[0]] = hash[1];
+ }
+ return vars;
+ }
+ //#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and 绂佺敤浜� = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
+
//#region 銆愯繃婊ゆ柟妗堛��
//鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldLowerBillEdit.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldLowerBillEdit.html"
index 134914d..6541648 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldLowerBillEdit.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldLowerBillEdit.html"
@@ -143,7 +143,7 @@
<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="" id="" style="background-color:#efefef4d;" readonly>
+ <input type="text" class="layui-input" name="HCloseMan" id="HCloseMan" style="background-color:#efefef4d;" readonly>
</div>
</div>
<div class="layui-inline">
@@ -157,7 +157,7 @@
<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="" id="" style="background-color:#efefef4d;" readonly>
+ <input type="text" class="layui-input" name="HCloseDate" id="HCloseDate" style="background-color:#efefef4d;" readonly>
</div>
</div>
<div class="layui-inline">
@@ -387,7 +387,7 @@
, area: ['90%', '90%']//澶у皬
, title: '閮ㄩ棬鍒楄〃'//鏍囬
, shift: 2//寮瑰嚭鍔ㄧ敾
- , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html?openType=2&HOrgName=' + sessionStorage["Organization"], 'yes']
, btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮规椤甸潰
@@ -532,7 +532,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["90%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ["../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html", "yes"]
+ , content: ["../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html?openType=2", "yes"]
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鎸夐挳涓� 鐨勫洖璋�
@@ -564,7 +564,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["90%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ["../../鍩虹璧勬枡/鐢熶骇鍩虹璧勬枡/Gy_Source.html", "yes"]
+ , content: ["../../鍩虹璧勬枡/鐢熶骇鍩虹璧勬枡/Gy_Source.html?Htype=&openType=2", "yes"]
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鎸夐挳涓� 鐨勫洖璋�
@@ -654,6 +654,8 @@
, "hupdatedate": d.data[0].淇敼鏃ユ湡 == null ? "" : Format(new Date(d.data[0].淇敼鏃ユ湡), "yyyy-MM-dd")
, "hdeleteman": d.data[0].浣滃簾浜�
, "hdeletedate": d.data[0].浣滃簾鏃ユ湡 == null ? "" : Format(new Date(d.data[0].浣滃簾鏃ユ湡), "yyyy-MM-dd")
+ , "HCloseMan": d.data[0].鍏抽棴浜�
+ , "HCloseDate": d.data[0].鍏抽棴鏃ユ湡 == null ? "" : Format(new Date(d.data[0].鍏抽棴鏃ユ湡), "yyyy-MM-dd")
});
//瀛愯〃 璧嬪��
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldLowerBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldLowerBillList.html"
index 292aa60..adf9aef 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldLowerBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldLowerBillList.html"
@@ -13,7 +13,8 @@
<script src="../../../layuiadmin/soulTable.slim.js"></script>
<script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
<script src="../../../layuiadmin/PageTitle.js"></script>
- <script src="../../../layuiadmin/HideButton.js"></script>
+ <script src="../../../layuiadmin/SetColumn.js"></script>
+ <script src="../../../layuiadmin/HideButton_New.js"></script>
</head>
<body>
<div class="layui-fluid">
@@ -26,6 +27,13 @@
<div class="layui-colla-title layui-inline">
<div class="layui-inline">
<span>鏇村</span>
+ </div>
+ </div>
+ <div class="layui-inline">
+ <label class="layui-form-label">鏃ユ湡闂撮殧</label>
+ <div class="layui-input-block">
+ <select name="HInitTimeCycle" id="HInitTimeCycle" class="ForFilteringSchemes" lay-filter="HInitTimeCycle" style="width:190px;">
+ </select>
</div>
</div>
<div class="layui-inline">
@@ -47,8 +55,8 @@
</div>
</div>
- <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" style="display:none;" lay-filter="btnSearch" id="btnSearch">鏌ヨ</button>
- <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" style="display:none;" lay-filter="btnReSearch" id="btnReSearch">閲嶇疆</button>
+ <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>
<!--鏄剧ず褰撳墠杩囨护鏂规-->
<div class="layui-inline" style="margin-left:5px;">
<div style="text-align:center;font-size:15px;font-weight:bold;color:#fc9393" id="HFilterScheme_Now"></div>
@@ -142,7 +150,7 @@
<table class="" id="mainTable" lay-filter="mainTable"></table>
<div id="page" style="position: relative; bottom: 0;"></div>
<script type="text/html" id="toolbarDemo">
- <div class="layui-btn-container">
+ <div class="layui-btn-container" id="toolbarDemo_ButtonSet">
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" id="set_AddNew" lay-event="set_AddNew"><i class="layui-icon layui-icon-form"></i>鏂板</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" id="set_ShowBill" lay-event="set_ShowBill"><i class="layui-icon layui-icon-form"></i>缂栬緫</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" id="set_DeleteBill" lay-event="set_DeleteBill"><i class="layui-icon layui-icon-form"></i>鍒犻櫎</button>
@@ -197,6 +205,8 @@
var HModName = "Sc_MouldLowerBillList";
var page = 1;//鍒嗛〉鏁版嵁
var size = 50;
+ var HBillType = "3847";
+ var set_HideButton_ID = "toolbarDemo_ButtonSet";//闇�瑕佽缃殑鎸夐挳鐨勭埗绾ц妭鐐圭殑id
//#endregion
//#region 杩涘叆椤甸潰鍗冲姞杞�
@@ -246,14 +256,11 @@
set_CheckBill(2);
break;
//鍒楄缃�
- case 'set_HideColumn':
- get_HideColumn();
+ case 'set_HideColumn': get_HideColumnNoPage(HModName, sessionStorage["HUserName"], option, get_FastQuery);
break;
//鎸夐挳璁剧疆
case 'set_HideButton':
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- var HBillType = "3847";
- get_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ get_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
break;
//鍒锋柊
case 'get_Refresh': get_Refresh();
@@ -304,6 +311,24 @@
set_ClearQuery();
});
+ //鏃ユ湡闂撮殧涓嬫媺鍒楄〃鐩戝惉
+ form.on('select(HInitTimeCycle)', function (data) {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+ });
//#endregion
@@ -314,7 +339,19 @@
set_InitGrid();
//鏌ヨ褰撳墠鐧诲綍鐢ㄦ埛鏈夋病鏈夊湪褰撳墠妯″潡璁剧疆榛樿杩囨护鏂规
get_DefaultModule();
- $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
+
+ //鍒濆鍖栨棩鏈熼棿闅斻�佸紑濮嬫棩鏈熴�佺粨鏉熸棩鏈�
+ setSelect_HInitTimeCycle();
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
$("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
//get_FastQuery();
}
@@ -394,7 +431,7 @@
com2 = "not like'%" + ColContent2 + "%'";
break;
default:
- com2 = "" + Comparator + "'" + ColContent + "'";
+ com2 = "" + Comparator2 + "'" + ColContent2 + "'";
break;
}
sWhere += " and " + ColName2 + " " + com2;
@@ -457,6 +494,7 @@
data: { "sWhere": sWhere, "user": sessionStorage["HUserName"], "page": page, "size": size },
success: function (data1) {
option.limit = size;//鏀瑰彉琛ㄦ牸椤靛ぇ灏�
+ optionPage.count = data1.count;
if (data1.code == 1) {
optionPage.count = data1.count;//鏀瑰彉鍒楄〃鏁版嵁鎬绘暟
var data = [];
@@ -501,8 +539,11 @@
option.totalRow = true;
laypage.render(optionPage);
- //鍒锋柊琛ㄦ牸鏁版嵁
- DisPlay_HideColumn();
+ //鍒楄缃�
+ DisPlay_HideColumn(HModName, sessionStorage["HUserName"], option, titleData);
+
+ ////鍒锋柊琛ㄦ牸鏁版嵁
+ ins = table.render(option);
layer.close(ajaxLoad);
if ($("#Comparator").val() == 0 && $("#ColContent").val() == "") {
@@ -510,9 +551,7 @@
}
//鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- var HBillType = "3847";
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ Display_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
} else {
layer.close(ajaxLoad);
@@ -790,7 +829,8 @@
//閲嶇疆
function set_ClearQuery() {
- $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
$("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
$("#HBillNo").val("");//鍗曟嵁鍙�
$("#ColContent").val("");
@@ -805,43 +845,6 @@
form.render('select');
sWhere = "";
get_FastQuery();
- }
-
- //闅愯棌鍒楄缃�
- function get_HideColumn() {
- var colName = "";
- var contentUrl = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
- }
- var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
- var urlLen = urlStr.split('/');
- for (var i = 0; i < urlLen.length - 4; i++) {
- contentUrl += "../";
- }
- colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
-
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
-
- layer.open({
- type: 2
- , skin: "layui-layer-rim" //鍔犱笂杈规
- , title: "闅愯棌鍒楄缃�" //鏍囬
- , closeBtn: 1 //绐椾綋鍙充笂瑙掑叧闂� 鐨� 鏍峰紡
- , shift: 2 //寮瑰嚭鍔ㄧ敾
- , area: ["50%", "90%"] //绐椾綋澶у皬
- , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: [contentUrl, "yes"]
- , btn: ["纭畾", "鍙栨秷"]
- , btn1: function (index, laero) {
- //鍒锋柊琛ㄦ牸鏁版嵁
- DisPlay_HideColumn();
- //鍒锋柊椤甸潰,
- location.reload();
- //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹�
- layer.close(index);//鍏抽棴寮圭獥
- }
- })
}
//#region 鐐瑰嚮琛岄�変腑楂樹寒
@@ -863,97 +866,25 @@
}
});
})
- //#endregion
+ //#endregion
- //鏄剧ず鍒楁暟鎹�
- 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) {
+ //#region 鍒濆鏃ユ湡闂撮殧 涓嬫媺鍒楄〃
+ function setSelect_HInitTimeCycle() {
+ var valueList = [0, 1, 2, 3, 4, 5, 6, 29];
+ var titleList = ["浠婂ぉ", "杩戜袱澶�", "杩戜笁澶�", "杩戝洓澶�", "杩戜簲澶�", "杩戝叚澶�", "杩戜竷澶�", "杩�30澶�"];
+ var HInitTimeCycle_ArrayList = '<option value="-1" selected="selected" >浠绘剰闂撮殧</option>';
+ for (var i = 0; i < valueList.length; i++) {
+ HInitTimeCycle_ArrayList += '<option style="color:blue;" value="' + valueList[i] + '">' + titleList[i] + '</option>';
+ }
- var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- var titleData = ["hmainid", "hentryid", "HEntryID", "HSourceID", "HMaterID", "HFirstCheckEmp", "HQCCheckItemID", "HUnitID", "HSampleSchemeID"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
+ $("#HInitTimeCycle").empty();
+ $("#HInitTimeCycle").append(HInitTimeCycle_ArrayList);
+ form.render('select');
- 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;
- }
- option.cols[0][i + 1]["fixed"] = "left";
- }
- }
- table.render(option);
- } else {
- table.render(option);
- }
-
- //鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- var HBillType = "3847";
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
- }, error: function () {
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- })
+ $("#HInitTimeCycle").val("29");
}
+ //#endregion
//鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
function get_DefaultModule() {
@@ -983,6 +914,24 @@
$("#" + data[i].杩囨护瀛楁ID).find("option[value='" + data[i].杩囨护鍊� + "']").attr("selected", true);
}
}
+
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+
//鎵ц鏌ヨ鏂规硶
get_FastQuery()
form.render("select");
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldUpperBillEdit.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldUpperBillEdit.html"
index cd1b5f0..f63e350 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldUpperBillEdit.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldUpperBillEdit.html"
@@ -387,7 +387,7 @@
, area: ['90%', '90%']//澶у皬
, title: '閮ㄩ棬鍒楄〃'//鏍囬
, shift: 2//寮瑰嚭鍔ㄧ敾
- , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html?openType=2&HOrgName=' + sessionStorage["Organization"], 'yes']
, btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮规椤甸潰
@@ -532,7 +532,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["90%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ["../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html", "yes"]
+ , content: ["../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html?openType=2", "yes"]
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鎸夐挳涓� 鐨勫洖璋�
@@ -564,7 +564,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["90%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ["../../鍩虹璧勬枡/鐢熶骇鍩虹璧勬枡/Gy_Source.html", "yes"]
+ , content: ["../../鍩虹璧勬枡/鐢熶骇鍩虹璧勬枡/Gy_Source.html?Htype=&openType=2", "yes"]
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鎸夐挳涓� 鐨勫洖璋�
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldUpperBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldUpperBillList.html"
index 8ec8f28..45ea54e 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldUpperBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\344\270\212\346\250\241\345\215\225/Sc_MouldUpperBillList.html"
@@ -13,7 +13,8 @@
<script src="../../../layuiadmin/soulTable.slim.js"></script>
<script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
<script src="../../../layuiadmin/PageTitle.js"></script>
- <script src="../../../layuiadmin/HideButton.js"></script>
+ <script src="../../../layuiadmin/SetColumn.js"></script>
+ <script src="../../../layuiadmin/HideButton_New.js"></script>
</head>
<body>
<div class="layui-fluid">
@@ -26,6 +27,13 @@
<div class="layui-colla-title layui-inline">
<div class="layui-inline">
<span>鏇村</span>
+ </div>
+ </div>
+ <div class="layui-inline">
+ <label class="layui-form-label">鏃ユ湡闂撮殧</label>
+ <div class="layui-input-block">
+ <select name="HInitTimeCycle" id="HInitTimeCycle" class="ForFilteringSchemes" lay-filter="HInitTimeCycle" style="width:190px;">
+ </select>
</div>
</div>
<div class="layui-inline">
@@ -47,8 +55,8 @@
</div>
</div>
- <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" style="display:none;" lay-filter="btnSearch" id="btnSearch">鏌ヨ</button>
- <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" style="display:none;" lay-filter="btnReSearch" id="btnReSearch">閲嶇疆</button>
+ <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>
<!--鏄剧ず褰撳墠杩囨护鏂规-->
<div class="layui-inline" style="margin-left:5px;">
<div style="text-align:center;font-size:15px;font-weight:bold;color:#fc9393" id="HFilterScheme_Now"></div>
@@ -142,7 +150,7 @@
<table class="" id="mainTable" lay-filter="mainTable"></table>
<div id="page" style="position: relative; bottom: 0;"></div>
<script type="text/html" id="toolbarDemo">
- <div class="layui-btn-container">
+ <div class="layui-btn-container" id="toolbarDemo_ButtonSet">
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" id="set_AddNew" lay-event="set_AddNew"><i class="layui-icon layui-icon-form"></i>鏂板</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" id="set_ShowBill" lay-event="set_ShowBill"><i class="layui-icon layui-icon-form"></i>缂栬緫</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" id="set_DeleteBill" lay-event="set_DeleteBill"><i class="layui-icon layui-icon-form"></i>鍒犻櫎</button>
@@ -195,6 +203,8 @@
var option = [];
var titleData = [];
var HModName = "Sc_MouldUpperBillList";
+ var HBillType = "3846";
+ var set_HideButton_ID = "toolbarDemo_ButtonSet";//闇�瑕佽缃殑鎸夐挳鐨勭埗绾ц妭鐐圭殑id
var page = 1;//鍒嗛〉鏁版嵁
var size = 50;
//#endregion
@@ -246,14 +256,11 @@
set_CheckBill(2);
break;
//鍒楄缃�
- case 'set_HideColumn':
- get_HideColumn();
+ case 'set_HideColumn': get_HideColumnNoPage(HModName, sessionStorage["HUserName"], option, get_FastQuery);
break;
//鎸夐挳璁剧疆
case 'set_HideButton':
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- var HBillType = "3846";
- get_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ get_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
break;
//鍒锋柊
case 'get_Refresh': get_Refresh();
@@ -304,6 +311,24 @@
set_ClearQuery();
});
+ //鏃ユ湡闂撮殧涓嬫媺鍒楄〃鐩戝惉
+ form.on('select(HInitTimeCycle)', function (data) {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+ });
//#endregion
@@ -314,7 +339,18 @@
set_InitGrid();
//鏌ヨ褰撳墠鐧诲綍鐢ㄦ埛鏈夋病鏈夊湪褰撳墠妯″潡璁剧疆榛樿杩囨护鏂规
get_DefaultModule();
- $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
+ //鍒濆鍖栨棩鏈熼棿闅斻�佸紑濮嬫棩鏈熴�佺粨鏉熸棩鏈�
+ setSelect_HInitTimeCycle();
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
$("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
//get_FastQuery();
}
@@ -360,6 +396,7 @@
data: { "sWhere": sWhere, "user": sessionStorage["HUserName"], "page": page, "size": size },
success: function (data1) {
option.limit = size;//鏀瑰彉琛ㄦ牸椤靛ぇ灏�
+ optionPage.count = data1.count;
if (data1.code == 1) {
optionPage.count = data1.count;//鏀瑰彉鍒楄〃鏁版嵁鎬绘暟
var data = [];
@@ -404,8 +441,11 @@
option.totalRow = true;
laypage.render(optionPage);
+ //鍒楄缃�
+ DisPlay_HideColumn(HModName, sessionStorage["HUserName"], option, titleData);
+
//鍒锋柊琛ㄦ牸鏁版嵁
- DisPlay_HideColumn();
+ ins = table.render(option);
layer.close(ajaxLoad);
if ($("#Comparator").val() == 0 && $("#ColContent").val() == "") {
@@ -413,9 +453,7 @@
}
//鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- var HBillType = "3846";
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ Display_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
} else {
layer.close(ajaxLoad);
@@ -504,7 +542,7 @@
com2 = "not like'%" + ColContent2 + "%'";
break;
default:
- com2 = "" + Comparator + "'" + ColContent + "'";
+ com2 = "" + Comparator2 + "'" + ColContent2 + "'";
break;
}
sWhere += " and " + ColName2 + " " + com2;
@@ -812,7 +850,8 @@
//閲嶇疆
function set_ClearQuery() {
- $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
$("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
$("#HBillNo").val("");//鍗曟嵁鍙�
$("#ColContent").val("");
@@ -829,133 +868,24 @@
get_FastQuery();
}
- //闅愯棌鍒楄缃�
- function get_HideColumn() {
- var colName = "";
- var contentUrl = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ //#region 鍒濆鏃ユ湡闂撮殧 涓嬫媺鍒楄〃
+ function setSelect_HInitTimeCycle() {
+ var valueList = [0, 1, 2, 3, 4, 5, 6, 29];
+ var titleList = ["浠婂ぉ", "杩戜袱澶�", "杩戜笁澶�", "杩戝洓澶�", "杩戜簲澶�", "杩戝叚澶�", "杩戜竷澶�", "杩�30澶�"];
+
+ var HInitTimeCycle_ArrayList = '<option value="-1" selected="selected" >浠绘剰闂撮殧</option>';
+ for (var i = 0; i < valueList.length; i++) {
+ HInitTimeCycle_ArrayList += '<option style="color:blue;" value="' + valueList[i] + '">' + titleList[i] + '</option>';
}
- var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
- var urlLen = urlStr.split('/');
- for (var i = 0; i < urlLen.length - 4; i++) {
- contentUrl += "../";
- }
- colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
+ $("#HInitTimeCycle").empty();
+ $("#HInitTimeCycle").append(HInitTimeCycle_ArrayList);
+ form.render('select');
- 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();
- //鍒锋柊椤甸潰,
- location.reload();
- //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹�
- layer.close(index);//鍏抽棴寮圭獥
- }
- })
+ $("#HInitTimeCycle").val("29");
}
-
- //鏄剧ず鍒楁暟鎹�
- function DisPlay_HideColumn() {
- $.ajax({
- url: GetWEBURL() + '/Xt_grdAlignment_WMES/grdAlignmentWMESList',
- type: "GET",
- data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
- success: function (data1) {
- if (data1.data.length != 0) {
-
-
- var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- var titleData = ["hmainid", "hentryid", "HEntryID", "HSourceID", "HMaterID", "HFirstCheckEmp", "HQCCheckItemID", "HUnitID", "HSampleSchemeID"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
-
- 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;
- }
- option.cols[0][i + 1]["fixed"] = "left";
- }
- }
- table.render(option);
- } else {
- table.render(option);
- }
-
- //鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- var HBillType = "3846";
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
- }, error: function () {
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- })
- }
-
+ //#endregion
+
//鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
function get_DefaultModule() {
$.ajax({
@@ -984,6 +914,24 @@
$("#" + data[i].杩囨护瀛楁ID).find("option[value='" + data[i].杩囨护鍊� + "']").attr("selected", true);
}
}
+
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+
//鎵ц鏌ヨ鏂规硶
get_FastQuery()
form.render("select");
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\345\231\250\345\205\267\347\202\271\346\243\200\350\247\204\347\250\213\345\215\225/Sc_MouldDotCheckRuleBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\345\231\250\345\205\267\347\202\271\346\243\200\350\247\204\347\250\213\345\215\225/Sc_MouldDotCheckRuleBillList.html"
index e5f97eb..33651fc 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\345\231\250\345\205\267\347\202\271\346\243\200\350\247\204\347\250\213\345\215\225/Sc_MouldDotCheckRuleBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\345\231\250\345\205\267\347\202\271\346\243\200\350\247\204\347\250\213\345\215\225/Sc_MouldDotCheckRuleBillList.html"
@@ -375,6 +375,7 @@
//鏌ヨ
function get_Display(sWhere) {
var ajaxLoad = layer.load();
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
//杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
$.ajax({
url: GetWEBURL() + '/Sc_MouldDotCheckRuleBill/Sc_MouldDotCheckRuleList',
@@ -864,6 +865,20 @@
form.render('select');
}
//#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and 鍏抽棴浜� = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
+
//#region 銆愯繃婊ゆ柟妗堛��
//鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\345\231\250\345\205\267\347\273\264\344\277\256\346\264\276\345\267\245\345\215\225/Sc_MouldRepairSendWorkBillEdit.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\345\231\250\345\205\267\347\273\264\344\277\256\346\264\276\345\267\245\345\215\225/Sc_MouldRepairSendWorkBillEdit.html"
index fc391f6..d898908 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\345\231\250\345\205\267\347\273\264\344\277\256\346\264\276\345\267\245\345\215\225/Sc_MouldRepairSendWorkBillEdit.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\345\231\250\345\205\267\347\273\264\344\277\256\346\264\276\345\267\245\345\215\225/Sc_MouldRepairSendWorkBillEdit.html"
@@ -30,15 +30,14 @@
<div class="layui-card-body" style="padding: 1px;">
<form class="layui-form" action="" lay-filter="formData" style="background-color:white;">
<div style="padding: 10px;">
- <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">棰勮</button>
- <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">鏂板</button>
- <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">淇敼</button>
<button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnSave" id="btnSave">淇濆瓨</button>
+ <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="Exit" id="Exit">閫�鍑�</button>
</div>
<div class="layui-tab" lay-filter="tab-POStockInBill">
<h1 style="text-align:center;"><b>鍣ㄥ叿缁翠慨娲惧伐鍗�</b></h1>
<ul class="layui-tab-title" lay-filter="tab-all">
<li lay-id="1" style="padding:1px;" class="layui-this">鍩烘湰淇℃伅</li>
+ <li lay-id="2" style="padding:1px;" class="layui-this">鍒跺崟淇℃伅</li>
</ul>
<div class="layui-tab-content">
<!--鍩烘湰淇℃伅-->
@@ -233,10 +232,78 @@
<div class="layui-inline" style="width: 56%;">
<label class="layui-form-label" style="width: 85px;">澶囨敞</label>
<div class="layui-input-block" style="margin-left: 120px;">
- <input type="hidden" class="layui-input" name="HMaker" id="HMaker" lay-verify="HMaker" value="">
- <input type="hidden" class="layui-input" name="HUpDater" id="HUpDater" lay-verify="HUpDater" value="">
<input type="text" class="layui-input" name="HRemark" id="HRemark" lay-verify="HRemark" placeholder="璇疯緭鍏ュ唴瀹�" onmouseover="this.title=this.value">
</div>
+ </div>
+ </div>
+ </div>
+ </div>
+ <!--鍒跺崟淇℃伅-->
+ <div class="layui-tab-item">
+ <div class="layui-form-item">
+ <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="HMaker" id="HMaker" style="background-color:#efefef4d;" readonly>
+ </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="HChecker" id="HChecker" style="background-color:#efefef4d;" readonly>
+ </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="HCloseMan" id="HCloseMan" style="background-color:#efefef4d;" readonly>
+ </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="HUpDater" id="HUpDater" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+
+ </div>
+ <div class="layui-form-item">
+ <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="HMakeDate" id="HMakeDate" style="background-color:#efefef4d;" readonly>
+ </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="HCheckDate" id="HCheckDate" style="background-color:#efefef4d;" readonly>
+ </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="HCloseDate" id="HCloseDate" style="background-color:#efefef4d;" readonly>
+ </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="HUpDateDate" id="HUpDateDate" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+ </div>
+ <div class="layui-form-item">
+ <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="HDeleteMan" id="HDeleteMan" style="background-color:#efefef4d;" readonly>
+ </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="HDeleteDate" id="HDeleteDate" style="background-color:#efefef4d;" readonly>
</div>
</div>
</div>
@@ -394,6 +461,18 @@
}
});
+ //閫�鍑�
+ form.on('submit(Exit)', function (data) {//
+ if (linterid == undefined) {
+ //鍏抽棴椤电
+ Pub_Close(2);
+ }
+ else {
+ //鍏抽棴椤电
+ Pub_Close(1);
+ }
+ });
+
//#region 瀛愯〃澶撮儴瑙﹀彂浜嬩欢
//澶村伐鍏锋爮浜嬩欢
table.on('toolbar(mainTable)', function (obj) {
@@ -448,8 +527,6 @@
}
//鍒跺崟浜�
$("#HMaker").val(sessionStorage["HUserName"]);
- //淇敼浜�
- $("#HUpDater").val(sessionStorage["HUserName"]);
//鍒濆鍖栨棩鏈�
$("#HRepairBeginDate").val(Format(new Date(), "yyyy-MM-dd"));
$("#HRepairEndDate").val(Format(new Date(), "yyyy-MM-dd"));
@@ -463,7 +540,7 @@
, area: ['90%', '90%']//澶у皬
, title: '鍣ㄥ叿琛�'//鏍囬
, shift: 2//寮瑰嚭鍔ㄧ敾
- , content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html', 'yes']
+ , content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html?openType=2', 'yes']
, btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮规椤甸潰
@@ -490,7 +567,7 @@
, area: ['90%', '90%'] //澶у皬
, title: '缁翠慨椤圭洰琛�' //鏍囬
, shift: 2 //寮瑰嚭鍔ㄧ敾
- , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_RepairList.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_RepairList.html?openType=2', 'yes']
, btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {//鎸夐挳涓� 鐨勫洖璋�
var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮圭獥椤甸潰
@@ -517,7 +594,7 @@
, area: ['90%', '90%'] //澶у皬
, title: '缁翠慨閮ㄩ棬琛�' //鏍囬
, shift: 2 //寮瑰嚭鍔ㄧ敾
- , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html?openType=2&HOrgName=' + sessionStorage["Organization"], 'yes']
, btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {//鎸夐挳涓� 鐨勫洖璋�
var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮圭獥椤甸潰
@@ -595,7 +672,7 @@
, area: ['90%', '90%'] //澶у皬
, title: '渚涘簲鍟嗚〃' //鏍囬
, shift: 2 //寮瑰嚭鍔ㄧ敾
- , content: ['../../鍩虹璧勬枡/閲囪喘鍩虹璧勬枡/Gy_Supplier.html?Type=HSup', 'yes']
+ , content: ['../../鍩虹璧勬枡/閲囪喘鍩虹璧勬枡/Gy_Supplier.html?Htype=HSup&HOrgName=' + sessionStorage["Organization"], 'yes']
, btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {//鎸夐挳涓� 鐨勫洖璋�
var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮圭獥椤甸潰
@@ -621,7 +698,7 @@
, area: ['90%', '90%'] //澶у皬
, title: '璁惧琛�' //鏍囬
, shift: 2 //寮瑰嚭鍔ㄧ敾
- , content: ['../../璁惧绠$悊/璁惧妗f/Gy_EquipFileMainList.html', 'yes']
+ , content: ['../../璁惧绠$悊/璁惧妗f/Gy_EquipFileMainList.html?openType=2', 'yes']
, btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {//鎸夐挳涓� 鐨勫洖璋�
var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮圭獥椤甸潰
@@ -671,7 +748,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["90%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_RepairList.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_RepairList.html?openType=2', 'yes']
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鎸夐挳涓� 鐨勫洖璋�
@@ -702,7 +779,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["90%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html?Type=HEmp', 'yes']
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鎸夐挳涓� 鐨勫洖璋�
@@ -763,9 +840,9 @@
var sWhere = " and hmainid ='" + linterid + "'";
$.ajax({
- url: GetWEBURL() + '/Sc_MouldRepairSendWorkBill/GetMouldRepairSendWorkBillList',
+ url: GetWEBURL() + '/Sc_MouldRepairSendWorkBill/Sc_MouldRepairSendWorkBill_Edit',
type: "GET",
- data: { "sWhere": sWhere, "user": sessionStorage["HUserName"] },
+ data: { "linterid": linterid, "user": sessionStorage["HUserName"] },
success: function (d) {
//涓昏〃
form.val("formData", { //formTest 鍗� class="layui-form" 鎵�鍦ㄥ厓绱犲睘鎬� lay-filter="" 瀵瑰簲鐨勫��
@@ -799,8 +876,17 @@
, "HEquipID": d.data[0].HEquipID
, "HRepairContent": d.data[0].缁翠慨鍐呭
, "HExplanation": d.data[0].缁翠慨瑕佹眰
- , "HMaker": d.data[0].鍒跺崟浜�
, "HRemark": d.data[0].澶囨敞
+ , "HMaker": d.data[0].鍒跺崟浜�
+ , "HMakeDate": d.data[0].鍒跺崟鏃ユ湡 == null ? "" : Format(new Date(d.data[0].鍒跺崟鏃ユ湡), "yyyy-MM-dd")
+ , "HChecker": d.data[0].瀹℃牳浜�
+ , "HCheckDate": d.data[0].瀹℃牳鏃ユ湡 == null ? "" : Format(new Date(d.data[0].瀹℃牳鏃ユ湡), "yyyy-MM-dd")
+ , "HUpDater": d.data[0].淇敼浜�
+ , "HUpDateDate": d.data[0].淇敼鏃ユ湡 == null ? "" : Format(new Date(d.data[0].淇敼鏃ユ湡), "yyyy-MM-dd")
+ , "HCloseMan": d.data[0].鍏抽棴浜�
+ , "HCloseDate": d.data[0].鍏抽棴鏃ユ湡 == null ? "" : Format(new Date(d.data[0].鍏抽棴鏃ユ湡), "yyyy-MM-dd")
+ , "HDeleteMan": d.data[0].浣滃簾浜�
+ , "HDeleteDate": d.data[0].浣滃簾鏃ユ湡 == null ? "" : Format(new Date(d.data[0].浣滃簾鏃ユ湡), "yyyy-MM-dd")
});
//瀛愯〃
var rowdata = [];
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\345\231\250\345\205\267\347\273\264\344\277\256\346\264\276\345\267\245\345\215\225/Sc_MouldRepairSendWorkBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\345\231\250\345\205\267\347\273\264\344\277\256\346\264\276\345\267\245\345\215\225/Sc_MouldRepairSendWorkBillList.html"
index 86e5c49..16c1062 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\345\231\250\345\205\267\347\273\264\344\277\256\346\264\276\345\267\245\345\215\225/Sc_MouldRepairSendWorkBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\345\231\250\345\205\267\347\273\264\344\277\256\346\264\276\345\267\245\345\215\225/Sc_MouldRepairSendWorkBillList.html"
@@ -12,9 +12,10 @@
<script src="../../../layuiadmin/Scripts/webConfig.js"></script>
<script src="../../../layuiadmin/PubCustom.js"></script>
<script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
- <script src="../../../layuiadmin/HideButton.js"></script>
<script src="../../../layuiadmin/soulTable.slim.js"></script>
<script src="../../../layuiadmin/PageTitle.js"></script>
+ <script src="../../../layuiadmin/SetColumn.js"></script>
+ <script src="../../../layuiadmin/HideButton_New.js"></script>
<style type="text/css">
input.layui-input.layui-unselect {
@@ -36,38 +37,49 @@
</div>
</div>
<div class="layui-inline">
+ <label class="layui-form-label">鏃ユ湡闂撮殧</label>
+ <div class="layui-input-block">
+ <select name="HInitTimeCycle" id="HInitTimeCycle" class="ForFilteringSchemes" lay-filter="HInitTimeCycle" style="width:190px;">
+ </select>
+ </div>
+ </div>
+ <div class="layui-inline">
<label class="layui-form-label">寮�濮嬫棩鏈�</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" id="HBeginDate" style="width:190px;">
+ <input type="date" class="layui-input ForFilteringSchemes" id="HBeginDate" style="width:190px;">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">缁撴潫鏃ユ湡</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" id="HEndDate" style="width:190px;">
+ <input type="date" class="layui-input ForFilteringSchemes" id="HEndDate" style="width:190px;">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">鍗曟嵁鍙�</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="HBillNo" id="HBillNo" style="width:190px;">
+ <input type="text" class="layui-input ForFilteringSchemes" name="HBillNo" id="HBillNo" style="width:190px;">
</div>
</div>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">
<i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
</button>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnReSearch" id="btnReSearch" style="padding:0 5px">閲嶇疆</button>
- <div class="layui-colla-content">
+ <!--鏄剧ず褰撳墠杩囨护鏂规-->
+ <div class="layui-inline" style="margin-left:5px;">
+ <div style="text-align:center;font-size:15px;font-weight:bold;color:#fc9393" id="HFilterScheme_Now"></div>
+ </div>
+ <div class="layui-colla-content">
<div class="layui-row">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName" id="ColName" lay-filter="ColName" style="width:190px;">
+ <select name="ColName" id="ColName" class="ForFilteringSchemes" lay-filter="ColName" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator" id="Comparator" lay-filter="Comparator" style="width:190px;">
+ <select name="Comparator" id="Comparator" class="ForFilteringSchemes" lay-filter="Comparator" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -82,19 +94,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent" id="ColContent">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent" id="ColContent">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName1" id="ColName1" lay-filter="ColName1" style="width:190px;">
+ <select name="ColName1" id="ColName1" class="ForFilteringSchemes" lay-filter="ColName1" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator1" id="Comparator1" lay-filter="Comparator1" style="width:190px;">
+ <select name="Comparator1" id="Comparator1" class="ForFilteringSchemes" lay-filter="Comparator1" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -109,19 +121,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent1" id="ColContent1">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent1" id="ColContent1">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName2" id="ColName2" lay-filter="ColName2" style="width:190px;">
+ <select name="ColName2" id="ColName2" class="ForFilteringSchemes" lay-filter="ColName2" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator2" id="Comparator2" lay-filter="Comparator2" style="width:190px;">
+ <select name="Comparator2" id="Comparator2" class="ForFilteringSchemes" lay-filter="Comparator2" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -136,7 +148,7 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent2" id="ColContent2">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent2" id="ColContent2">
</div>
</div>
</div>
@@ -145,7 +157,7 @@
<table class="" id="mainTable" lay-filter="mainTable"></table>
<div id="page" style="position: relative; bottom: 0;"></div>
<script type="text/html" id="toolbarDemo">
- <div class="layui-btn-container">
+ <div class="layui-btn-container" id="toolbarDemo_ButtonSet">
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Add" id="btn-Add"><i class="layui-icon layui-icon-file-b"></i>鏂板</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" 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>
@@ -153,10 +165,14 @@
<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="btn-Audit" id="btn-Audit"><i class="layui-icon layui-icon-radio"></i>瀹℃牳</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-DeAudit" id="btn-DeAudit"><i class="layui-icon layui-icon-circle"></i>鍙嶅鏍�</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Close" id="Close"><i class="layui-icon layui-icon-radio"></i>鍏抽棴</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeClose" id="DeClose"><i class="layui-icon layui-icon-radio"></i>鍙嶅叧闂�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-view" id="btn-view"><i class="layui-icon layui-icon-tips"></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="set_HideColumn" id="set_HideColumn"><i class="layui-icon layui-icon-form"></i>鍒楄缃�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_HideButton" id="HideButton"><i class="layui-icon layui-icon-form"></i>鎸夐挳璁剧疆</button>
-
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_SaveScheme" id="set_SaveScheme"><i class="layui-icon layui-icon-template"></i>淇濆瓨鏂规</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_ReadScheme" id="set_ReadScheme"><i class="layui-icon layui-icon-set"></i>璇诲彇鏂规</button>
</div>
</script>
</form>
@@ -190,6 +206,18 @@
var titleData = [];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
var page = 1;//鍒嗛〉鏁版嵁
var size = 50;
+ var set_HideButton_ID = "toolbarDemo_ButtonSet";//闇�瑕佽缃殑鎸夐挳鐨勭埗绾ц妭鐐圭殑id
+ //#endregion
+
+ //#region 銆愯繃婊ゆ柟妗堛��
+ //杩囨护鏉′欢鐨刢lass绫�
+ var HClassTag = "ForFilteringSchemes";
+ //妯″潡鍚嶇О锛堜腑鏂囩増锛� 姣忎釜妯″潡椤甸潰閮介渶瑕佷慨鏀�
+ window.HModuleName = "鍣ㄥ叿缁翠慨娲惧伐鍗�";
+ //鏄惁宸茬粡閫夋嫨浜嗚繃婊ゆ柟妗堬紙鍏ㄥ眬鍙橀噺锛�
+ window.HDefaultFilter = "";
+ //閫夋嫨鐨勮繃婊ゆ柟妗堝唴鐮侊紙鍏ㄥ眬鍙橀噺锛�
+ window.HInterID_Choose = 0;
//#endregion
//#region 銆愬姩鎬佽幏鍙栨ā鍧楀悕绉般��
@@ -283,6 +311,14 @@
case 'btn-DeAudit':
set_DeAuditBill();
break;
+ //鍏抽棴鎸夐挳 锛�0:鍏抽棴銆�1:鍙嶅叧闂級
+ case 'btn-Close':
+ set_CloseBill(0);
+ break;
+ //鍙嶅叧闂寜閽�
+ case 'btn-DeClose':
+ set_CloseBill(1);
+ break;
//鎵撳嵃
case 'btn-print': get_PrintReport();
break;
@@ -292,10 +328,18 @@
//閫�鍑烘寜閽�
case 'get_Exit': Pub_Close(2);
break;
+ //鍒楄缃�
+ case 'set_HideColumn': get_HideColumnNoPage(HModName, sessionStorage["HUserName"], option, get_FastQuery);
+ break;
//鎸夐挳璁剧疆
case 'set_HideButton':
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- get_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ get_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
+ break;
+ //淇濆瓨鏂规
+ case 'set_SaveScheme': set_SaveScheme();
+ break;
+ //璇诲彇鏂规
+ case 'set_ReadScheme': set_ReadScheme();
break;
};
});
@@ -310,20 +354,51 @@
});
//#endregion
+ //鏃ユ湡闂撮殧涓嬫媺鍒楄〃鐩戝惉
+ form.on('select(HInitTimeCycle)', function (data) {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+ });
+
//#endregion
//#region 姝ら〉闈㈡墍鏈夌殑鏂规硶
// 鍒濆鍖栫晫闈�
function set_ClearBill() {
+ //鍒濆鍖栨棩鏈熼棿闅斻�佸紑濮嬫棩鏈熴�佺粨鏉熸棩鏈�
+ setSelect_HInitTimeCycle();
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
//鍒濆鍖栨棩鏈�
- //褰卞搷鍒板揩閫熻繃婊ょ殑鏌ヨ锛屾墍浠ュ厛娉ㄩ噴
- $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
$("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
//鍒濆鍖栬〃鏍�
set_InitGrid();
//鏌ヨ
//get_Display(sWhere);
get_FastQuery();
+ //鏌ヨ褰撳墠鐧诲綍鐢ㄦ埛鏈夋病鏈夊湪褰撳墠妯″潡璁剧疆榛樿杩囨护鏂规
+ get_DefaultModule();
}
//鍒濆鍖栬〃鏍�
@@ -423,12 +498,14 @@
//鍒嗛〉鏌ヨ
function get_DisplayPage(sWhere) {
var ajaxLoad = layer.load();
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
$.ajax({
url: GetWEBURL() + '/Sc_MouldRepairSendWorkBill/GetMouldRepairSendWorkBillListPage',
type: "GET",
data: { "sWhere": sWhere, "user": sessionStorage["HUserName"], "page": page, "size": size },
success: function (data1) {
option.limit = size;//鏀瑰彉琛ㄦ牸椤靛ぇ灏�
+ optionPage.count = data1.count;
if (data1.code == 1) {
optionPage.count = data1.count;//鏀瑰彉鍒楄〃鏁版嵁鎬绘暟
var data = [];
@@ -472,13 +549,16 @@
option.data = data1.data;
option.totalRow = true;
laypage.render(optionPage);
- table.render(option);
+ //table.render(option);
layer.close(ajaxLoad);
+ //鍒楄缃�
+ DisPlay_HideColumn(HModName, sessionStorage["HUserName"], option, titleData);
+
+ ////鍒锋柊琛ㄦ牸鏁版嵁
+ ins = table.render(option);
//鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
-
+ Display_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
if ($("#Comparator").val() == 0 && $("#ColContent").val() == "") {
ColFilter();
@@ -602,7 +682,7 @@
com2 = "not like'%" + ColContent2 + "%'";
break;
default:
- com2 = "" + Comparator + "'" + ColContent + "'";
+ com2 = "" + Comparator2 + "'" + ColContent2 + "'";
break;
}
sWhere += " and " + ColName2 + " " + com2;
@@ -646,7 +726,8 @@
// 閲嶇疆杩囨护鏉′欢
function set_ClearQuery() {
- $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
$("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
$("#HBillNo").val("");//鍗曟嵁鍙�
$("#ColContent").val("");
@@ -791,6 +872,41 @@
}
}
+ //#region 鍙嶅叧闂�/鍏抽棴鏁版嵁
+ function set_CloseBill(num) {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var InterID = data[0].hmainid.toString();
+ //閫昏緫瀹℃牳鏂规硶
+ $.ajax({
+ type: "GET",
+ url: GetWEBURL() + "/Sc_MouldRepairSendWorkBill/CloseSc_MouldRepairSendWorkBill", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ data: { "HInterID": InterID, "IsAudit": num, "CurUserName": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ $("#btnSearch").trigger('click');
+ });
+
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹叧闂紒');
+ }
+ }
+ //#endregion
//#region 鍒楁槑鏄剧ず涓嬫媺妗�
function ColFilter() {
@@ -809,8 +925,318 @@
form.render('select');
}
//#endregion
+
+ //#region 鍒濆鏃ユ湡闂撮殧 涓嬫媺鍒楄〃
+ function setSelect_HInitTimeCycle() {
+ var valueList = [0, 1, 2, 3, 4, 5, 6, 29];
+ var titleList = ["浠婂ぉ", "杩戜袱澶�", "杩戜笁澶�", "杩戝洓澶�", "杩戜簲澶�", "杩戝叚澶�", "杩戜竷澶�", "杩�30澶�"];
+
+ var HInitTimeCycle_ArrayList = '<option value="-1" selected="selected" >浠绘剰闂撮殧</option>';
+ for (var i = 0; i < valueList.length; i++) {
+ HInitTimeCycle_ArrayList += '<option style="color:blue;" value="' + valueList[i] + '">' + titleList[i] + '</option>';
+ }
+
+ $("#HInitTimeCycle").empty();
+ $("#HInitTimeCycle").append(HInitTimeCycle_ArrayList);
+ form.render('select');
+
+ $("#HInitTimeCycle").val("29");
+ }
+ //#endregion
+
+ //#endregion
+
+ //#region 鑾峰彇鍙傛暟
+ function getUrlVars() {
+ var vars = [], hash;
+ var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
+ for (var i = 0; i < hashes.length; i++) {
+ hash = hashes[i].split('=');
+ vars.push(hash[0]);
+ vars[hash[0]] = hash[1];
+ }
+ return vars;
+ }
+ //#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and 鍏抽棴浜� = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
+
+ //#region 銆愯繃婊ゆ柟妗堛��
+
+ //鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
+ function get_DefaultModule() {
+ $.ajax({
+ url: GetWEBURL() + '/Xt_FastICScheme/Chooselist',
+ type: "GET",
+ 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].HInterID;
+ //杩囨护鏂规鍐呯爜
+ HInterID = data[0].HInterID
+ //杩囨护鏂规鍚嶇О
+ 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) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery(2)
+ form.render("select");
+ } else {
+ //褰撳墠鐢ㄦ埛娌℃湁璁剧疆榛樿鐨勮繃婊ゆ柟妗�
+ //闅愯棌鏄剧ず杩囨护鏂规鐨勬爣绛句俊鎭�
+ document.getElementById("HFilterScheme_Now").style.display = "none";
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery(1)
+ 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");
+ }
+ }
+ })
+ }
+
//#endregion
});
+
+ //#region 銆愯繃婊ゆ柟妗堣繑鍥炴暟鎹��
+ function HFilterScheme(obj) //杩斿洖杩囨护鏂规
+ {
+ var HInterID = obj[0].HInterID;
+ HInterID_Choose = obj[0].HInterID;
+ $.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].HInterID
+ //鏍规嵁閫夋嫨鐨勮繃婊ゆ柟妗堝洖濉暟鎹埌鍒楄〃杩囨护鏉′欢
+ 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
</script>
</body>
</html>
\ No newline at end of file
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\345\205\267\346\212\225\344\272\247\351\252\214\346\224\266\345\215\225/Sc_MouldBatchWorkCheckBillEdit.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\345\205\267\346\212\225\344\272\247\351\252\214\346\224\266\345\215\225/Sc_MouldBatchWorkCheckBillEdit.html"
index 6f1a5a1..fbfa9ef 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\345\205\267\346\212\225\344\272\247\351\252\214\346\224\266\345\215\225/Sc_MouldBatchWorkCheckBillEdit.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\345\205\267\346\212\225\344\272\247\351\252\214\346\224\266\345\215\225/Sc_MouldBatchWorkCheckBillEdit.html"
@@ -2,7 +2,7 @@
<html>
<head>
<meta charset="utf-8" />
- <title>涓婃ā鍗曠紪杈�</title>
+ <title>妯″叿鎶曚骇楠屾敹鍗曠紪杈�</title>
<meta name="renderer" content="webkit">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
@@ -402,7 +402,7 @@
, area: ['90%', '90%']//澶у皬
, title: '閮ㄩ棬鍒楄〃'//鏍囬
, shift: 2//寮瑰嚭鍔ㄧ敾
- , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html?openType=2&HOrgName=' + sessionStorage["Organization"], 'yes']
, btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮规椤甸潰
@@ -499,7 +499,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["90%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ["../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html", "yes"]
+ , content: ["../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html?openType=2", "yes"]
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鎸夐挳涓� 鐨勫洖璋�
@@ -531,7 +531,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["90%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Material.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Material.html?openType=2', 'yes']
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鎸夐挳涓� 鐨勫洖璋�
@@ -562,7 +562,7 @@
, shift: 2 //寮瑰嚭鍔ㄧ敾
, area: ["90%", "90%"] //绐椾綋澶у皬
, maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Material.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Material.html?openType=2', 'yes']
, btn: ["纭畾", "鍙栨秷"]
, btn1: function (index, laero) {
//鎸夐挳涓� 鐨勫洖璋�
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\345\205\267\346\212\225\344\272\247\351\252\214\346\224\266\345\215\225/Sc_MouldBatchWorkCheckBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\345\205\267\346\212\225\344\272\247\351\252\214\346\224\266\345\215\225/Sc_MouldBatchWorkCheckBillList.html"
index 1e2d31a..203e60d 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\345\205\267\346\212\225\344\272\247\351\252\214\346\224\266\345\215\225/Sc_MouldBatchWorkCheckBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\345\205\267\346\212\225\344\272\247\351\252\214\346\224\266\345\215\225/Sc_MouldBatchWorkCheckBillList.html"
@@ -15,6 +15,8 @@
<script src="../../../layuiadmin/PubCustom.js"></script>
<script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
<script src="../../../layuiadmin/PageTitle.js"></script>
+ <script src="../../../layuiadmin/SetColumn.js"></script>
+ <script src="../../../layuiadmin/HideButton_New.js"></script>
</head>
<body>
@@ -150,20 +152,21 @@
</div>
<table class="" id="mainTable" lay-filter="mainTable"></table>
<script type="text/html" id="toolbarDemo">
- <div class="layui-btn-container">
- <button type="button" class="layui-btn layui-btn-sm" lay-event="set_AddNew"><i class="layui-icon layui-icon-file-b"></i>鏂板</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="set_ShowBill"><i class="layui-icon layui-icon-form"></i>缂栬緫</button>
+ <div class="layui-btn-container" id="toolbarDemo_ButtonSet">
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_AddNew" id="set_AddNew"><i class="layui-icon layui-icon-file-b"></i>鏂板</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_ShowBill" id="set_ShowBill"><i class="layui-icon layui-icon-form"></i>缂栬緫</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="set_Copy" id="set_Copy"><i class="layui-icon layui-icon-form"></i>澶嶅埗</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="set_DeleteBill"><i class="layui-icon layui-icon-delete"></i>鍒犻櫎</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="get_Refresh"><i class="layui-icon layui-icon-refresh-3"></i>鍒锋柊</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Audit"><i class="layui-icon layui-icon-radio"></i>瀹℃牳</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeAudit"><i class="layui-icon layui-icon-circle"></i>鍙嶅鏍�</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Close"><i class="layui-icon layui-icon-radio"></i>鍏抽棴</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeClose"><i class="layui-icon layui-icon-radio"></i>鍙嶅叧闂�</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Drop"><i class="layui-icon layui-icon-radio"></i>浣滃簾</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeDrop"><i class="layui-icon layui-icon-radio"></i>鍙嶄綔搴�</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="get_Exit"><i class="layui-icon layui-icon-logout"></i>閫�鍑�</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="set_HideColumn"><i class="layui-icon layui-icon-form"></i>鍒楄缃�</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_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="btn-Audit" id="btn-Audit"><i class="layui-icon layui-icon-radio"></i>瀹℃牳</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeAudit" id="btn-DeAudit"><i class="layui-icon layui-icon-circle"></i>鍙嶅鏍�</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Close" id="btn-Close"><i class="layui-icon layui-icon-radio"></i>鍏抽棴</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeClose" id="btn-DeClose"><i class="layui-icon layui-icon-radio"></i>鍙嶅叧闂�</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Drop" id="btn-Drop"><i class="layui-icon layui-icon-radio"></i>浣滃簾</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeDrop" id="btn-DeDrop"><i class="layui-icon layui-icon-radio"></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>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_HideColumn" id="set_HideColumn"><i class="layui-icon layui-icon-form"></i>鍒楄缃�</button>
+ <button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_HideButton" id="HideButton"><i class="layui-icon layui-icon-form"></i>鎸夐挳璁剧疆</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="set_SaveScheme" id="set_SaveScheme"><i class="layui-icon layui-icon-template"></i>淇濆瓨鏂规</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="set_ReadScheme" id="set_ReadScheme"><i class="layui-icon layui-icon-set"></i>璇诲彇鏂规</button>
</div>
@@ -191,6 +194,15 @@
var option = [];
var sWhere = "";
var HModName = "Sc_MouldBatchWorkCheckBillList";
+ var optionPage = [];
+
+ var ins; //鐢ㄤ簬瀵煎嚭excel
+ var page = 1;//鍒嗛〉鏁版嵁
+ var size = 50;
+ var HBillType = "3848";
+ var set_HideButton_ID = "toolbarDemo_ButtonSet";//闇�瑕佽缃殑鎸夐挳鐨勭埗绾ц妭鐐圭殑id
+ //涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
+ var titleData = [];
//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
var titleData = ["HInterID", "HEntryID", "HDeptID", "HMangerID", "HEmpID", "HMaterID_Prod", "HMaterID", "HMouldID"];
@@ -272,7 +284,11 @@
case 'get_Exit': Pub_Close(2);
break;
//鍒楄缃�
- case 'set_HideColumn': get_HideColumn();
+ case 'set_HideColumn': get_HideColumnNoPage(HModName, sessionStorage["HUserName"], option, get_FastQuery);
+ break;
+ //鎸夐挳璁剧疆
+ case 'set_HideButton':
+ get_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
break;
//淇濆瓨鏂规
case 'set_SaveScheme': set_SaveScheme();
@@ -373,6 +389,25 @@
, limit: 50
, limits: [50, 500, 5000, 20000]
};
+
+ optionPage = {
+ elem: 'page', //娉ㄦ剰锛岃繖閲岀殑 page 鏄� ID锛屼笉鐢ㄥ姞 # 鍙�
+ count: 10000, //鏁版嵁鎬绘暟锛屼粠鏈嶅姟绔緱鍒�
+ limit: 50,
+ limits: [50, 500, 5000, 50000],
+ layout: ['count', 'prev', 'page', 'next', 'limit', 'skip'],
+ jump: function (obj, first) {
+
+ //棣栨涓嶆墽琛�
+ if (!first) {
+ //do something
+ page = obj.curr;
+ size = obj.limit;
+ get_FastQuery();
+ }
+ }
+ }
+ laypage.render(optionPage);
}
//#endregion
@@ -475,15 +510,100 @@
}
//#endregion
+ //鍒嗛〉鏌ヨ
+ function get_DisplayPage(sWhere) {
+ var ajaxLoad = layer.load();
+ $.ajax({
+ url: GetWEBURL() + '/Sc_MouldBatchWorkCheckBill/GetMouldBatchWorkCheckBillListPage',
+ type: "GET",
+ data: { "sWhere": sWhere, "user": sessionStorage["HUserName"], "page": page, "size": size },
+ success: function (data1) {
+ option.limit = size;//鏀瑰彉琛ㄦ牸椤靛ぇ灏�
+ optionPage.count = data1.count;
+ if (data1.code == 1) {
+ optionPage.count = data1.count;//鏀瑰彉鍒楄〃鏁版嵁鎬绘暟
+ 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 ($.inArray(data[i].name, titleData) > -1) {
+ col.push({ field: data[i].id, title: data[i].name, align: 'center', hide: true }); //闅愯棌id鍒�
+ }
+ 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 });
+ }
+ }
+ }
+
+ columns = col;
+ option.cols = [col];
+ option.data = data1.data;
+ option.totalRow = true;
+ laypage.render(optionPage);
+ //鍒楄缃�
+ DisPlay_HideColumn(HModName, sessionStorage["HUserName"], option, titleData);
+
+ ////鍒锋柊琛ㄦ牸鏁版嵁
+ ins = table.render(option);
+
+ layer.close(ajaxLoad);
+
+ //鍒锋柊鎸夐挳鏄剧ず
+ Display_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
+
+ if ($("#Comparator").val() == 0 && $("#ColContent").val() == "") {
+ ColFilter();
+ }
+
+ } else {
+ layer.close(ajaxLoad);
+ layer.alert(data1.code + data1.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.close(ajaxLoad);
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+
//#region 蹇�熻繃婊�
function get_FastQuery(number) {
var HBillNo = $("#HBillNo").val(); //鍗曟嵁鍙�
var HDate = $("#HBeginDate").val();//寮�濮嬫棩鏈�
var HDate1 = $("#HEndDate").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 = "";
@@ -506,6 +626,49 @@
}
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 = "" + Comparator2 + "'" + ColContent2 + "'";
+ break;
+ }
+ sWhere += " and " + ColName2 + " " + com2;
+ }
+
if (HDate) {
sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + HDate + "'";
}
@@ -518,7 +681,7 @@
}
- get_Display(sWhere);
+ get_DisplayPage(sWhere);
sWhere = "";//璋冪敤鎺ュ彛鍚庢竻绌簊Where缂撳瓨
}
//#endregion
@@ -773,125 +936,6 @@
}
}
//#endregion
-
- //#region 闅愯棌鍒楄缃�
- function get_HideColumn() {
- var colName = "";
- var contentUrl = "";
- for (var i = 1; i < option.cols[0].length; i++) {
- colName += option.cols[0][i]["title"] + ",";
- }
- var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
- var urlLen = urlStr.split('/');
- for (var i = 0; i < urlLen.length - 4; i++) {
- contentUrl += "../";
- }
- colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
-
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
-
- layer.open({
- type: 2
- , skin: "layui-layer-rim" //鍔犱笂杈规
- , title: "闅愯棌鍒楄缃�" //鏍囬
- , closeBtn: 1 //绐椾綋鍙充笂瑙掑叧闂� 鐨� 鏍峰紡
- , shift: 2 //寮瑰嚭鍔ㄧ敾
- , area: ["50%", "90%"] //绐椾綋澶у皬
- , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: [contentUrl, "yes"]
- , btn: ["纭畾", "鍙栨秷"]
- , btn1: function (index, laero) {
- //鍒锋柊琛ㄦ牸鏁版嵁
- DisPlay_HideColumn();
- //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹�
- layer.close(index);//鍏抽棴寮圭獥
- }
- })
- }
- //#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) {
-
- var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- //var titleData = ["鍗曟嵁ID", "HMouldID", "hsubid", "HManagerID", "婧愬崟涓诲唴鐮�", "婧愬崟瀛愬唴鐮�"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
- var titleData = ["HInterID", "HEntryID", "HDeptID", "HReceiveDeptID", "HErrMsgBackTypeID", "HOrgID", "HDutyID"];
- 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;
- }
- option.cols[0][i + 1]["fixed"] = "left";
- }
- }
- table.render(option);
- } else {
- table.render(option);
- }
- }, error: function () {
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- })
- }
- //#endregion
-
//#region 浠绘剰瀛楁杩囨护锛氬垪鍚嶆樉绀轰笅鎷夋
function ColFilter() {
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sb_Add_MouldRepairWorkBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sb_Add_MouldRepairWorkBillList.html"
index 68d6a3b..504e9fc 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sb_Add_MouldRepairWorkBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sb_Add_MouldRepairWorkBillList.html"
@@ -23,21 +23,17 @@
<form id="form0" class="layui-form" lay-filter="component-form-group" action="">
<div class="layui-card-header">
<div class="layui-btn-group">
-
<button type="button" id="Saver" class="layui-btn layui-btn-normal layui-btn-radius" lay-submit="" lay-filter="Saver">淇濆瓨</button>
<button type="button" class="layui-btn layui-btn-normal layui-btn-radius" lay-submit="" lay-filter="Exit">閫�鍑�</button>
-
-
</div>
-
</div>
<div class="layui-card-body">
<div class="layui-tab layui-tab-brief" lay-filter="docDemoTabBrief">
- <!--<ul class="layui-tab-title">
- <li class="layui-this">鍩烘湰淇℃伅</li>-->
- <!--<li>鍏朵粬淇℃伅</li>-->
- <!--</ul>-->
<h1 style="text-align:center;"><b>鍣ㄥ叿缁翠慨璁板綍鍗�</b></h1>
+ <ul class="layui-tab-title" lay-filter="tab-all">
+ <li lay-id="1" style="padding:1px;" class="layui-this">鍩烘湰淇℃伅</li>
+ <li lay-id="2" style="padding:1px;">鍒跺崟淇℃伅</li>
+ </ul>
<div class="layui-tab-content">
<div class="layui-tab-item layui-show">
<div class="layui-form-item">
@@ -145,7 +141,7 @@
<i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i>
</button>
</div>
- </div>
+ </div>
</div>
<div class="layui-form-item">
<div class="layui-inline">
@@ -231,7 +227,7 @@
<div class="layui-inline">
<label class="layui-form-label">缁翠慨鍙楃悊鏃ユ湡</label>
<div class="layui-input-inline">
- <input class="layui-input" name="HRepairAccepDate" id="HRepairAccepDate" autocomplete="off" model="datetime" dateFormat="yyyy-MM-dd" placeholder="yyyy-MM-dd">
+ <input class="layui-input" name="HRepairAccepDate" id="HRepairAccepDate" autocomplete="off" model="datetime" dateFormat="yyyy-MM-dd" placeholder="yyyy-MM-dd">
</div>
</div>
</div>
@@ -252,6 +248,76 @@
<label class="layui-form-label">澶囨敞</label>
<div class="layui-input-inline">
<textarea placeholder="璇疯緭鍏ョ淮澶囨敞" class="layui-textarea" name="HRemark" id="HRemark"></textarea>
+ </div>
+ </div>
+ </div>
+ </div>
+ <!--鍒跺崟淇℃伅-->
+ <div class="layui-tab-item">
+ <div class="layui-form-item">
+ <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="HMaker" id="HMaker" style="background-color:#efefef4d;" readonly>
+ </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="HChecker" id="HChecker" style="background-color:#efefef4d;" readonly>
+ </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="HCloseMan" id="HCloseMan" style="background-color:#efefef4d;" readonly>
+ </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="HUpDater" id="HUpDater" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+
+ </div>
+ <div class="layui-form-item">
+ <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="HMakeDate" id="HMakeDate" style="background-color:#efefef4d;" readonly>
+ </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="HCheckDate" id="HCheckDate" style="background-color:#efefef4d;" readonly>
+ </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="HCloseDate" id="HCloseDate" style="background-color:#efefef4d;" readonly>
+ </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="HUpDateDate" id="HUpDateDate" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+ </div>
+ <div class="layui-form-item">
+ <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="HDeleteMan" id="HDeleteMan" style="background-color:#efefef4d;" readonly>
+ </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="HDeleteDate" id="HDeleteDate" style="background-color:#efefef4d;" readonly>
</div>
</div>
</div>
@@ -312,6 +378,7 @@
<script src="../../../layuiadmin/Scripts/webConfig.js"></script>
<script src="../../../layuiadmin/PubCustom.js"></script>
<script src="../../../layuiadmin/PageTitle.js"></script>
+ <script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
<script>
//鑾峰彇鍙傛暟
var params = get_UrlVars();
@@ -452,7 +519,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html', 'yes'],
+ content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -492,7 +559,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_RepairList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_RepairList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -530,7 +597,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html?openType=2&HOrgName=' + sessionStorage["Organization"], 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -644,7 +711,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/閲囪喘鍩虹璧勬枡/Gy_Supplier.html?Type=HSup', 'yes'],
+ content: ['../../鍩虹璧勬枡/閲囪喘鍩虹璧勬枡/Gy_Supplier.html?Htype=HSup&HOrgName=' + sessionStorage["Organization"], 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -682,7 +749,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../璁惧绠$悊/璁惧妗f/Gy_EquipFileMainList.html', 'yes'],
+ content: ['../../璁惧绠$悊/璁惧妗f/Gy_EquipFileMainList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -720,7 +787,7 @@
title: '鍣ㄥ叿鏁呴殰鐧昏鍗曞垪琛�',
shift: 2,
area: ['90%', '90%'],
- content: ['../妯℃不鍏风鐞�/Sc_MouldConkBookBillList.html', 'yes'],
+ content: ['../妯℃不鍏风鐞�/Sc_MouldConkBookBillList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -829,7 +896,7 @@
title: '鍣ㄥ叿缁翠慨娲惧伐鍗曞垪琛�',
shift: 2,
area: ['90%', '90%'],
- content: ['../鍣ㄥ叿缁翠慨娲惧伐鍗�/Sc_MouldRepairSendWorkBillList.html', 'yes'],
+ content: ['../鍣ㄥ叿缁翠慨娲惧伐鍗�/Sc_MouldRepairSendWorkBillList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮规椤甸潰
@@ -1014,7 +1081,7 @@
$("#HBillNo").val(d.data[0].HBillNo);
$("#HDate").val(Pub_Format(new Date(), "yyyy-MM-dd"));
$("#HRepairBeginDate").val(Pub_Format(new Date(), "yyyy-MM-dd"));
- $("#HRepairEndDate").val(Pub_Format(new Date(), "yyyy-MM-dd"));
+ $("#HRepairEndDate").val(Pub_Format(new Date(), "yyyy-MM-dd"));
$("#HRepairAccepDate").val(Pub_Format(new Date(), "yyyy-MM-dd"));
}
});
@@ -1076,6 +1143,16 @@
, "HMainSourceInterID": data.HMainSourceInterID
, "HMainSourceEntryID": data.HMainSourceEntryID
, "HRepairAccepDate": formatDate(data.缁翠慨鍙楃悊鏃ユ湡)
+ , "HMaker": data.鍒跺崟浜�
+ , "HMakeDate": data.鍒跺崟鏃ユ湡 == null ? "" : Format(new Date(data.鍒跺崟鏃ユ湡), "yyyy-MM-dd")
+ , "HChecker": data.瀹℃牳浜�
+ , "HCheckDate": data.瀹℃牳鏃ユ湡 == null ? "" : Format(new Date(data.瀹℃牳鏃ユ湡), "yyyy-MM-dd")
+ , "HUpDater": data.淇敼浜�
+ , "HUpDateDate": data.淇敼鏃ユ湡 == null ? "" : Format(new Date(data.淇敼鏃ユ湡), "yyyy-MM-dd")
+ , "HCloseMan": data.鍏抽棴浜�
+ , "HCloseDate": data.鍏抽棴鏃ユ湡 == null ? "" : Format(new Date(data.鍏抽棴鏃ユ湡), "yyyy-MM-dd")
+ , "HDeleteMan": data.浣滃簾浜�
+ , "HDeleteDate": data.浣滃簾鏃ユ湡 == null ? "" : Format(new Date(data.浣滃簾鏃ユ湡), "yyyy-MM-dd")
});
} else {
@@ -1177,7 +1254,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_RepairList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_RepairList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -1217,7 +1294,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html?Type=HManager', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -1270,7 +1347,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Material.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Material.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -1307,7 +1384,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true,
- content: ['../../../views/鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Unit.html', 'yes'],
+ content: ['../../../views/鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Unit.html?Type=HUnitList', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sb_MouldRepairWorkBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sb_MouldRepairWorkBillList.html"
index d8755ad..9f73e4c 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sb_MouldRepairWorkBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sb_MouldRepairWorkBillList.html"
@@ -9,9 +9,10 @@
<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/HideButton.js"></script>
<script src="../../../layuiadmin/soulTable.slim.js"></script>
<script src="../../../layuiadmin/PageTitle.js"></script>
+ <script src="../../../layuiadmin/SetColumn.js"></script>
+ <script src="../../../layuiadmin/HideButton_New.js"></script>
<style type="text/css">
input.layui-input.layui-unselect {
padding-right: 0;
@@ -34,7 +35,7 @@
<div class="layui-inline">
<label class="layui-form-label">鐘舵��</label>
<div class="layui-input-block">
- <select name="Status" lay-filter="Status" style="width:190px;">
+ <select name="Status" lay-filter="Status" id="Status" class="ForFilteringSchemes" style="width:190px;">
<option value="-1" selected="selected">鍏ㄩ儴</option>
<option value="0">鏈鏍�</option>
<option value="1">宸插鏍�</option>
@@ -43,58 +44,69 @@
</div>
</div>
<div class="layui-inline">
+ <label class="layui-form-label">鏃ユ湡闂撮殧</label>
+ <div class="layui-input-block">
+ <select name="HInitTimeCycle" id="HInitTimeCycle" class="ForFilteringSchemes" lay-filter="HInitTimeCycle" style="width:190px;">
+ </select>
+ </div>
+ </div>
+ <div class="layui-inline">
<label class="layui-form-label">寮�濮嬫棩鏈�</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" id="HDate" style="width:190px;">
+ <input type="date" class="layui-input ForFilteringSchemes" id="HBeginDate" style="width:190px;">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">缁撴潫鏃ユ湡</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" id="HDate1" style="width:190px;">
+ <input type="date" class="layui-input ForFilteringSchemes" id="HEndDate" style="width:190px;">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">鍗曟嵁鍙�</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="HBillNo" id="HBillNo" style="width:190px;">
+ <input type="text" class="layui-input ForFilteringSchemes" name="HBillNo" id="HBillNo" style="width:190px;">
</div>
</div>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">
<i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
</button>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnReSearch" id="btnReSearch" style="padding:0 5px">閲嶇疆</button>
- <div class="layui-colla-content">
+ <!--鏄剧ず褰撳墠杩囨护鏂规-->
+ <div class="layui-inline" style="margin-left:5px;">
+ <div style="text-align:center;font-size:15px;font-weight:bold;color:#fc9393" id="HFilterScheme_Now"></div>
+ </div>
+ <div class="layui-colla-content">
<div class="layui-row">
<div class="layui-inline">
<label class="layui-form-label">鍣ㄥ叿缂栫爜</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="HMouldNumber" id="HMouldNumber" style="width:190px;">
+ <input type="text" class="layui-input ForFilteringSchemes" name="HMouldNumber" id="HMouldNumber" style="width:190px;">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">鍣ㄥ叿鍚嶇О</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="HMouldName" id="HMouldName" style="width:190px;">
+ <input type="text" class="layui-input ForFilteringSchemes" name="HMouldName" id="HMouldName" style="width:190px;">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">缁翠慨椤圭洰</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="RepairItem" id="RepairItem" style="width:190px;">
+ <input type="text" class="layui-input ForFilteringSchemes" name="RepairItem" id="RepairItem" style="width:190px;">
</div>
</div>
</div>
- <div class="layui-row" style="margin-top:5px">
+ <div class="layui-row">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName" id="ColName" lay-filter="ColName" style="width:190px;">
+ <select name="ColName" id="ColName" class="ForFilteringSchemes" lay-filter="ColName" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator" id="Comparator" lay-filter="Comparator" style="width:190px;">
+ <select name="Comparator" id="Comparator" class="ForFilteringSchemes" lay-filter="Comparator" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -109,19 +121,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent" id="ColContent">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent" id="ColContent">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName1" id="ColName1" lay-filter="ColName1" style="width:190px;">
+ <select name="ColName1" id="ColName1" class="ForFilteringSchemes" lay-filter="ColName1" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator1" id="Comparator1" lay-filter="Comparator1" style="width:190px;">
+ <select name="Comparator1" id="Comparator1" class="ForFilteringSchemes" lay-filter="Comparator1" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -136,19 +148,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent1" id="ColContent1">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent1" id="ColContent1">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName2" id="ColName2" lay-filter="ColName2" style="width:190px;">
+ <select name="ColName2" id="ColName2" class="ForFilteringSchemes" lay-filter="ColName2" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator2" id="Comparator2" lay-filter="Comparator2" style="width:190px;">
+ <select name="Comparator2" id="Comparator2" class="ForFilteringSchemes" lay-filter="Comparator2" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -163,7 +175,7 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent2" id="ColContent2">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent2" id="ColContent2">
</div>
</div>
</div>
@@ -185,13 +197,15 @@
</div>
<div id="page" style="position: relative; bottom: 0;"></div>
<script type="text/html" id="toolbarDemo">
- <div class="layui-btn-container">
+ <div class="layui-btn-container" id="toolbarDemo_ButtonSet">
<!--<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-getCheckData"><i class="layui-icon layui-icon-tips"></i>棰勮</button>-->
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Add" id="btn-Add"><i class="layui-icon layui-icon-add-1"></i>鏂板</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Edit" id="btn-Edit"><i class="layui-icon layui-icon-edit"></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="btn-Audit" id="btn-Audit"><i class="layui-icon layui-icon-radio"></i>瀹℃牳</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-DeAudit" id="btn-DeAudit"><i class="layui-icon layui-icon-circle"></i>鍙嶅鏍�</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Close" id="Close"><i class="layui-icon layui-icon-radio"></i>鍏抽棴</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeClose" id="DeClose"><i class="layui-icon layui-icon-radio"></i>鍙嶅叧闂�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-reload" id="btn-reload"><i class="layui-icon layui-icon-refresh"></i>鍒锋柊</button>
<!--<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-confirm" id="btn_confirm"><i class="layui-icon layui-icon-ok-circle"></i>纭</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-back" id="btn_back"><i class="layui-icon layui-icon-close-fill"></i>椹冲洖</button>
@@ -200,6 +214,8 @@
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-exit" id="btn-exit"><i class="layui-icon layui-icon-return"></i>閫�鍑�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_HideColumn" id="set_HideColumn"><i class="layui-icon layui-icon-form"></i>鍒楄缃�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_HideButton" id="HideButton"><i class="layui-icon layui-icon-form"></i>鎸夐挳璁剧疆</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_SaveScheme" id="set_SaveScheme"><i class="layui-icon layui-icon-template"></i>淇濆瓨鏂规</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_ReadScheme" id="set_ReadScheme"><i class="layui-icon layui-icon-set"></i>璇诲彇鏂规</button>
</div>
</script>
<script type="text/html" id="xuhao">
@@ -208,7 +224,8 @@
<script type="text/html" id="xuhao1">
{{d.LAY_TABLE_INDEX+1}}
</script>
-</form>
+ </div>
+ </form>
</div>
</div>
</div>
@@ -243,6 +260,18 @@
var titleData = ["hmainid", "鍗曟嵁ID", "鍗曟嵁绫诲瀷", "HMouldID", "HEquipID", "HEmpID", "HManagerID", "HDeptID", "HSupID", "hsubid", "HRepairID", "婧愬崟涓诲唴鐮�", "婧愬崟瀛愬唴鐮�", "HBillType"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
var page = 1;//鍒嗛〉鏁版嵁
var size = 50;
+ var set_HideButton_ID = "toolbarDemo_ButtonSet";//闇�瑕佽缃殑鎸夐挳鐨勭埗绾ц妭鐐圭殑id
+ //#endregion
+
+ //#region 銆愯繃婊ゆ柟妗堛��
+ //杩囨护鏉′欢鐨刢lass绫�
+ var HClassTag = "ForFilteringSchemes";
+ //妯″潡鍚嶇О锛堜腑鏂囩増锛� 姣忎釜妯″潡椤甸潰閮介渶瑕佷慨鏀�
+ window.HModuleName = "鍣ㄥ叿缁翠慨璁板綍鍗�";
+ //鏄惁宸茬粡閫夋嫨浜嗚繃婊ゆ柟妗堬紙鍏ㄥ眬鍙橀噺锛�
+ window.HDefaultFilter = "";
+ //閫夋嫨鐨勮繃婊ゆ柟妗堝唴鐮侊紙鍏ㄥ眬鍙橀噺锛�
+ window.HInterID_Choose = 0;
//#endregion
//#region 銆愬姩鎬佽幏鍙栨ā鍧楀悕绉般��
@@ -338,19 +367,29 @@
//鍙嶅鏍�
case 'btn-DeAudit': set_DeAuditBill();
break;
- //鍒楄缃�
- case 'get_HideColumn1': get_HideColumn1();
+ //鍏抽棴鎸夐挳 锛�0:鍏抽棴銆�1:鍙嶅叧闂級
+ case 'btn-Close':
+ set_CloseBill(0);
break;
+ //鍙嶅叧闂寜閽�
+ case 'btn-DeClose':
+ set_CloseBill(1);
+ break;
//鍒楄缃�
- case 'set_HideColumn': get_HideColumn();
+ case 'set_HideColumn': get_HideColumnNoPage(HModName, sessionStorage["HUserName"], option, get_FastQuery);
break;
////閫�鍑烘寜閽�
//case 'get_Exit': Pub_Close(2);
// break;
//鎸夐挳璁剧疆
case 'set_HideButton':
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- get_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ get_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
+ break;
+ //淇濆瓨鏂规
+ case 'set_SaveScheme': set_SaveScheme();
+ break;
+ //璇诲彇鏂规
+ case 'set_ReadScheme': set_ReadScheme();
break;
};
});
@@ -379,14 +418,44 @@
});
//#endregion
+ //鏃ユ湡闂撮殧涓嬫媺鍒楄〃鐩戝惉
+ form.on('select(HInitTimeCycle)', function (data) {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+ });
+
//#endregion
//#region 褰撳墠椤甸潰鍔犺浇鎵�鏈夋柟娉�
// 鍒濆鍖栫晫闈�
function set_ClearBill() {
+ //鍒濆鍖栨棩鏈熼棿闅斻�佸紑濮嬫棩鏈熴�佺粨鏉熸棩鏈�
+ setSelect_HInitTimeCycle();
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
//鍒濆鍖栨棩鏈�
- $("#HDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
- $("#HDate1").val(Format(new Date(), "yyyy-MM-dd"));
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
//鍒濆鍖栬〃鏍�
set_InitGrid();
//鍒濆鍖栬〃鏍�(瀛愯〃1)
@@ -396,6 +465,8 @@
//鏌ヨ
//get_Display(sWhere);
get_FastQuery();
+ //鏌ヨ褰撳墠鐧诲綍鐢ㄦ埛鏈夋病鏈夊湪褰撳墠妯″潡璁剧疆榛樿杩囨护鏂规
+ get_DefaultModule();
}
//鍒濆鍖栬〃鏍�
@@ -499,12 +570,14 @@
//鍒嗛〉鏌ヨ
function get_DisplayPage(sWhere) {
var ajaxLoad = layer.load();
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
$.ajax({
url: GetWEBURL() + '/Sb_MouldRepairWorkBill/GetMouldRepairWorkBillListPage',
type: "GET",
data: { "sWhere": sWhere, "user": sessionStorage["HUserName"], "page": page, "size": size },
success: function (data1) {
option.limit = size;//鏀瑰彉琛ㄦ牸椤靛ぇ灏�
+ optionPage.count = data1.count;
if (data1.code == 1) {
optionPage.count = data1.count;//鏀瑰彉鍒楄〃鏁版嵁鎬绘暟
var data = [];
@@ -549,8 +622,14 @@
option.totalRow = true;
laypage.render(optionPage);
- //鍒锋柊琛ㄦ牸鏁版嵁
- DisPlay_HideColumn();
+ //鍒楄缃�
+ DisPlay_HideColumn(HModName, sessionStorage["HUserName"], option, titleData);
+
+ ////鍒锋柊琛ㄦ牸鏁版嵁
+ ins = table.render(option);
+
+ //鍒锋柊鎸夐挳鏄剧ず
+ Display_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
layer.close(ajaxLoad);
if ($("#Comparator").val() == 0 && $("#ColContent").val() == "") {
@@ -874,11 +953,47 @@
}
}
+ //#region 鍙嶅叧闂�/鍏抽棴鏁版嵁
+ function set_CloseBill(num) {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var InterID = data[0].hmainid.toString();
+ //閫昏緫瀹℃牳鏂规硶
+ $.ajax({
+ type: "GET",
+ url: GetWEBURL() + "/Sb_MouldRepairWorkBill/CloseSb_MouldRepairWorkBill", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ data: { "HInterID": InterID, "IsAudit": num, "CurUserName": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ $("#btnSearch").trigger('click');
+ });
+
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹叧闂紒');
+ }
+ }
+ //#endregion
+
//蹇�熻繃婊�
function get_FastQuery() {
var Status = $("select[name='Status']").val();//鐘舵��
- var HDate = $("#HDate").val();//寮�濮嬫棩鏈�
- var HDate1 = $("#HDate1").val();//缁撴潫鏃ユ湡
+ var HBeginDate = $("#HBeginDate").val();//寮�濮嬫棩鏈�
+ var HEndDate = $("#HEndDate").val();//缁撴潫鏃ユ湡
var HBillNo = $("#HBillNo").val(); //鍗曟嵁鍙�
var HMouldNumber = $("#HMouldNumber").val(); //妯℃不鍏风紪鐮�
var HMouldName = $("#HMouldName").val(); //妯℃不鍏峰悕绉�
@@ -952,7 +1067,7 @@
com2 = "not like'%" + ColContent2 + "%'";
break;
default:
- com2 = "" + Comparator + "'" + ColContent + "'";
+ com2 = "" + Comparator2 + "'" + ColContent2 + "'";
break;
}
sWhere += " and " + ColName2 + " " + com2;
@@ -974,11 +1089,11 @@
}
}
- if (HDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + HDate + "'";
+ if (HBeginDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + HBeginDate + "'";
}
- if (HDate1) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + HDate1 + "'";
+ if (HEndDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + HEndDate + "'";
}
if (HBillNo) {
sWhere += " and 鍗曟嵁鍙� like '%" + HBillNo + "%'";
@@ -1001,9 +1116,10 @@
//閲嶇疆杩囨护鏉′欢鏂规硶
function set_ClearQuery() {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
$('#Status').find("option[value='-1']").attr("selected", true);
- $("#HDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
- $("#HDate1").val(Format(new Date(), "yyyy-MM-dd"));
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
$("#HBillNo").val("");
$("#HMouldNumber").val("");
$("#HMouldName").val("");
@@ -1021,129 +1137,7 @@
form.render('select');
sWhere = "";
}
-
- //闅愯棌鍒楄缃�
- function get_HideColumn() {
- var colName = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
- }
-
- 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.html?HModName=' + HModName + '&colName=' + colName, "yes"]
- , btn: ["纭畾", "鍙栨秷"]
- , btn1: function (index, laero) {
- //鍒锋柊琛ㄦ牸鏁版嵁
- DisPlay_HideColumn();
- //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹�
- layer.close(index);//鍏抽棴寮圭獥
- }
- })
- }
-
- //鏄剧ず鍒楁暟鎹�
- function DisPlay_HideColumn() {
- $.ajax({
- url: GetWEBURL() + '/Xt_grdAlignment_WMES/grdAlignmentWMESList',
- type: "GET",
- data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
- success: function (data1) {
- if (data1.data.length != 0) {
-
-
- var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- /*var titleData = ["鍗曟嵁ID", "鍗曟嵁绫诲瀷", "HMouldID", "HEquipID", "HEmpID", "HManagerID", "HDeptID", "HSupID", "hsubid", "HRepairID", "婧愬崟涓诲唴鐮�", "婧愬崟瀛愬唴鐮�", "HBillType"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�*/
-
- 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;
- }
- option.cols[0][i + 1]["fixed"] = "left";
- }
- }
- table.render(option);
-
- //鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
- } else {
- table.render(option);
-
- //鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
- }
- }, error: function () {
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- })
- }
-
-
+
//#region 鍒楁槑鏄剧ず涓嬫媺妗�
function ColFilter() {
var Organization = '<option value="0" selected="selected" ></option>';
@@ -1163,20 +1157,319 @@
//#endregion
//#endregion
+ //#region 鑾峰彇鍙傛暟
+ function getUrlVars() {
+ var vars = [], hash;
+ var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
+ for (var i = 0; i < hashes.length; i++) {
+ hash = hashes[i].split('=');
+ vars.push(hash[0]);
+ vars[hash[0]] = hash[1];
+ }
+ return vars;
+ }
+ //#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and 鍏抽棴浜� = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
//#endregion
- //laydate.render({
- // elem: '#HDate'
- // , type: 'datetime'
- // , trigger: 'click'
- // , format:'yyyy-MM-dd HH:mm'
- //});
+ //#region 鍒濆鏃ユ湡闂撮殧 涓嬫媺鍒楄〃
+ function setSelect_HInitTimeCycle() {
+ var valueList = [0, 1, 2, 3, 4, 5, 6, 29];
+ var titleList = ["浠婂ぉ", "杩戜袱澶�", "杩戜笁澶�", "杩戝洓澶�", "杩戜簲澶�", "杩戝叚澶�", "杩戜竷澶�", "杩�30澶�"];
+
+ var HInitTimeCycle_ArrayList = '<option value="-1" selected="selected" >浠绘剰闂撮殧</option>';
+ for (var i = 0; i < valueList.length; i++) {
+ HInitTimeCycle_ArrayList += '<option style="color:blue;" value="' + valueList[i] + '">' + titleList[i] + '</option>';
+ }
+
+ $("#HInitTimeCycle").empty();
+ $("#HInitTimeCycle").append(HInitTimeCycle_ArrayList);
+ form.render('select');
+
+ $("#HInitTimeCycle").val("29");
+ }
+ //#endregion
+
+ //#region 銆愯繃婊ゆ柟妗堛��
+
+ //鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
+ function get_DefaultModule() {
+ $.ajax({
+ url: GetWEBURL() + '/Xt_FastICScheme/Chooselist',
+ type: "GET",
+ 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].HInterID;
+ //杩囨护鏂规鍐呯爜
+ HInterID = data[0].HInterID
+ //杩囨护鏂规鍚嶇О
+ 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) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery(2)
+ form.render("select");
+ } else {
+ //褰撳墠鐢ㄦ埛娌℃湁璁剧疆榛樿鐨勮繃婊ゆ柟妗�
+ //闅愯棌鏄剧ず杩囨护鏂规鐨勬爣绛句俊鎭�
+ document.getElementById("HFilterScheme_Now").style.display = "none";
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery(1)
+ 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");
+ }
+ }
+ })
+ }
+
+ //#endregion
+
//浠ヤ笂鏄痩ayui妯″潡
});
- </script>
+ //#region 銆愯繃婊ゆ柟妗堣繑鍥炴暟鎹��
+ function HFilterScheme(obj) //杩斿洖杩囨护鏂规
+ {
+ var HInterID = obj[0].HInterID;
+ HInterID_Choose = obj[0].HInterID;
+ $.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].HInterID
+ //鏍规嵁閫夋嫨鐨勮繃婊ゆ柟妗堝洖濉暟鎹埌鍒楄〃杩囨护鏉′欢
+ 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
+ </script>
</body>
</html>
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldConkBookBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldConkBookBillList.html"
index 3b7ea8c..3a4fbdc 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldConkBookBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldConkBookBillList.html"
@@ -23,21 +23,17 @@
<form id="form0" class="layui-form" lay-filter="component-form-group" action="">
<div class="layui-card-header">
<div class="layui-btn-group">
-
<button type="button" id="add-btn" class="layui-btn layui-btn-normal layui-btn-radius" lay-submit="" lay-filter="Saver">淇濆瓨</button>
<button type="button" class="layui-btn layui-btn-normal layui-btn-radius" lay-submit="" lay-filter="Exit">閫�鍑�</button>
-
-
</div>
-
</div>
<div class="layui-card-body">
<div class="layui-tab layui-tab-brief" lay-filter="docDemoTabBrief">
- <!--<ul class="layui-tab-title">
- <li class="layui-this">鍩烘湰淇℃伅</li>-->
- <!--<li>鍏朵粬淇℃伅</li>-->
- <!--</ul>-->
<h1 style="text-align:center;"><b>鍣ㄥ叿鏁呴殰鐧昏琛�</b></h1>
+ <ul class="layui-tab-title" lay-filter="tab-all">
+ <li lay-id="1" style="padding:1px;" class="layui-this">鍩烘湰淇℃伅</li>
+ <li lay-id="2" style="padding:1px;">鍒跺崟淇℃伅</li>
+ </ul>
<div class="layui-tab-content">
<div class="layui-tab-item layui-show">
<div class="layui-form-item">
@@ -143,6 +139,76 @@
</div>
</div>
</div>
+ <!--鍒跺崟淇℃伅-->
+ <div class="layui-tab-item">
+ <div class="layui-form-item">
+ <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="HMaker" id="HMaker" style="background-color:#efefef4d;" readonly>
+ </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="HChecker" id="HChecker" style="background-color:#efefef4d;" readonly>
+ </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="HCloseMan" id="HCloseMan" style="background-color:#efefef4d;" readonly>
+ </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="HUpDater" id="HUpDater" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+
+ </div>
+ <div class="layui-form-item">
+ <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="HMakeDate" id="HMakeDate" style="background-color:#efefef4d;" readonly>
+ </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="HCheckDate" id="HCheckDate" style="background-color:#efefef4d;" readonly>
+ </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="HCloseDate" id="HCloseDate" style="background-color:#efefef4d;" readonly>
+ </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="HUpDateDate" id="HUpDateDate" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+ </div>
+ <div class="layui-form-item">
+ <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="HDeleteMan" id="HDeleteMan" style="background-color:#efefef4d;" readonly>
+ </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="HDeleteDate" id="HDeleteDate" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+ </div>
+ </div>
</div>
</div>
</div>
@@ -174,6 +240,7 @@
<script src="../../../layuiadmin/Scripts/webConfig.js"></script>
<script src="../../../layuiadmin/PubCustom.js"></script>
<script src="../../../layuiadmin/PageTitle.js"></script>
+ <script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
<script>
//鑾峰彇鍙傛暟
var params = get_UrlVars();
@@ -211,7 +278,7 @@
//閫氳繃鍗曟嵁绫诲瀷锛屼粠鏁版嵁搴撳姩鎬佽幏鍙栧崟鎹ā鍧楀懡鍚�,寮曠敤js鏂囦欢 PageTitle.js
var HPageTitle = get_PageTitle(HModuleType) == "" ? $("h1").html() : get_PageTitle(HModuleType);
$("h1").html('<b>' + HPageTitle + '</b>');
- //#endregion
+ //#endregion
//鍒濆鍖栬〃鏍�
set_InitGrid();
@@ -268,7 +335,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html', 'yes'],
+ content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -306,7 +373,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_ConkType.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_ConkType.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -420,7 +487,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html?openType=2&HOrgName=' + sessionStorage["Organization"], 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -613,6 +680,16 @@
, "HDeptName": data.浣跨敤閮ㄩ棬 //浣跨敤閮ㄩ棬
, "HExplanation": data.鎽樿
, "HRemark": data.澶囨敞
+ , "HMaker": data.鍒跺崟浜�
+ , "HMakeDate": data.鍒跺崟鏃ユ湡 == null ? "" : Format(new Date(data.鍒跺崟鏃ユ湡), "yyyy-MM-dd")
+ , "HChecker": data.瀹℃牳浜�
+ , "HCheckDate": data.瀹℃牳鏃ユ湡 == null ? "" : Format(new Date(data.瀹℃牳鏃ユ湡), "yyyy-MM-dd")
+ , "HUpDater": data.淇敼浜�
+ , "HUpDateDate": data.淇敼鏃ユ湡 == null ? "" : Format(new Date(data.淇敼鏃ユ湡), "yyyy-MM-dd")
+ , "HCloseMan": data.鍏抽棴浜�
+ , "HCloseDate": data.鍏抽棴鏃ユ湡 == null ? "" : Format(new Date(data.鍏抽棴鏃ユ湡), "yyyy-MM-dd")
+ , "HDeleteMan": data.浣滃簾浜�
+ , "HDeleteDate": data.浣滃簾鏃ユ湡 == null ? "" : Format(new Date(data.浣滃簾鏃ユ湡), "yyyy-MM-dd")
});
} else {
@@ -697,7 +774,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_ConkReasonList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_ConkReasonList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -737,7 +814,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html?Type=HManager', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldDotCheckBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldDotCheckBillList.html"
index 0e0dc56..2cf9722 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldDotCheckBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldDotCheckBillList.html"
@@ -41,9 +41,10 @@
</div>
<div class="layui-card-body">
<div class="layui-tab layui-tab-brief" lay-filter="docDemoTabBrief">
- <ul class="layui-tab-title">
+ <ul class="layui-tab-title">
<li class="layui-this">鍩烘湰淇℃伅</li>
<li>闄勪欢淇℃伅</li>
+ <li>鍒跺崟淇℃伅</li>
</ul>
<h1 style="text-align:center;"><b>鍣ㄥ叿鐐规璁板綍琛�</b></h1>
<div class="layui-tab-content">
@@ -81,11 +82,11 @@
</div>
<div class="layui-form-item">
<!--<div class="layui-inline">
- <label class="layui-form-label">鐐规璁″垝缂栧彿</label>
- <div class="layui-input-inline">
- <input type="text" name="HPlanNo" id="HPlanNo" class="layui-input">
- </div>
- </div>-->
+ <label class="layui-form-label">鐐规璁″垝缂栧彿</label>
+ <div class="layui-input-inline">
+ <input type="text" name="HPlanNo" id="HPlanNo" class="layui-input">
+ </div>
+ </div>-->
<div class="layui-inline">
<label class="layui-form-label">鐐规璁″垝缂栧彿<label style="color:red"> * </label></label>
<div class="layui-input-inline">
@@ -193,6 +194,76 @@
<tbody id="ProImgByList" class="ProImgByList">
</tbody>
</table>
+ </div>
+ </div>
+ </div>
+ </div>
+ <!--鍒跺崟淇℃伅-->
+ <div class="layui-tab-item">
+ <div class="layui-form-item">
+ <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="HMaker" id="HMaker" style="background-color:#efefef4d;" readonly>
+ </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="HChecker" id="HChecker" style="background-color:#efefef4d;" readonly>
+ </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="HCloseMan" id="HCloseMan" style="background-color:#efefef4d;" readonly>
+ </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="HUpDater" id="HUpDater" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+
+ </div>
+ <div class="layui-form-item">
+ <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="HMakeDate" id="HMakeDate" style="background-color:#efefef4d;" readonly>
+ </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="HCheckDate" id="HCheckDate" style="background-color:#efefef4d;" readonly>
+ </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="HCloseDate" id="HCloseDate" style="background-color:#efefef4d;" readonly>
+ </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="HUpDateDate" id="HUpDateDate" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+ </div>
+ <div class="layui-form-item">
+ <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="HDeleteMan" id="HDeleteMan" style="background-color:#efefef4d;" readonly>
+ </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="HDeleteDate" id="HDeleteDate" style="background-color:#efefef4d;" readonly>
</div>
</div>
</div>
@@ -355,7 +426,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../妯℃不鍏风鐞�/Sc_MouldDotCheckPlanBillList.html', 'yes'],
+ content: ['../妯℃不鍏风鐞�/Sc_MouldDotCheckPlanBillList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -393,7 +464,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true
- , content: ['../../鍩虹璧勬枡/鐢熶骇鍩虹璧勬枡/Gy_ShiftsList.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鐢熶骇鍩虹璧勬枡/Gy_ShiftsList.html?openType=2', 'yes']
, btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -428,7 +499,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html', 'yes'],
+ content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -466,7 +537,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../妯℃不鍏风鐞�/鍣ㄥ叿鐐规瑙勭▼鍗�/Sc_MouldDotCheckRuleBillList.html', 'yes'],
+ content: ['../../妯℃不鍏风鐞�/鍣ㄥ叿鐐规瑙勭▼鍗�/Sc_MouldDotCheckRuleBillList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -529,7 +600,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html?Type=HManager', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -566,7 +637,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -601,7 +672,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true
- , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckItemClassList.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckItemClassList.html?openType=2', 'yes']
, btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -634,7 +705,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true
- , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckItemMethodList.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckItemMethodList.html?openType=2', 'yes']
, btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -961,7 +1032,7 @@
async: false,
success: function (result) {
if (result.code == 1) { // 璇存槑楠岃瘉鎴愬姛浜嗭紝
- var data = result.data.h_v_Sc_MouldDotCheckBillList[0];
+ var data = result.data.h_v_Sc_MouldDotCheckBillMain_Edit[0];
form.val("component-form-group", { //formTest 鍗� class="layui-form" 鎵�鍦ㄥ厓绱犲睘鎬� lay-filter="" 瀵瑰簲鐨勫��
"HBillNo": data.鍗曟嵁鍙�
, "HDate": formatDate(data.鏃ユ湡)
@@ -983,6 +1054,16 @@
, "HDotCheckNote": data.鐐规鏁版嵁 //鐐规鏁版嵁
, "HShiftsID": data.HShiftsID == undefined ? 0 : data.HShiftsID
, "HShiftsName": data.鐝鍚嶇О //鐝鍚嶇О
+ , "HMaker": data.鍒跺崟浜�
+ , "HMakeDate": data.鍒跺崟鏃ユ湡 == null ? "" : Format(new Date(data.鍒跺崟鏃ユ湡), "yyyy-MM-dd")
+ , "HChecker": data.瀹℃牳浜�
+ , "HCheckDate": data.瀹℃牳鏃ユ湡 == null ? "" : Format(new Date(data.瀹℃牳鏃ユ湡), "yyyy-MM-dd")
+ , "HUpDater": data.淇敼浜�
+ , "HUpDateDate": data.淇敼鏃ユ湡 == null ? "" : Format(new Date(data.淇敼鏃ユ湡), "yyyy-MM-dd")
+ , "HCloseMan": data.鍏抽棴浜�
+ , "HCloseDate": data.鍏抽棴鏃ユ湡 == null ? "" : Format(new Date(data.鍏抽棴鏃ユ湡), "yyyy-MM-dd")
+ , "HDeleteMan": data.浣滃簾浜�
+ , "HDeleteDate": data.浣滃簾鏃ユ湡 == null ? "" : Format(new Date(data.浣滃簾鏃ユ湡), "yyyy-MM-dd")
});
if (data.鏈�缁堢粨璁� == "涓嶅悎鏍�") {
document.querySelectorAll("[name='HLastResult']")[0].removeAttribute('checked'); //鍒犻櫎閫夋嫨灞炴��
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldDotCheckPlanBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldDotCheckPlanBillList.html"
index ca74902..b982715 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldDotCheckPlanBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldDotCheckPlanBillList.html"
@@ -33,6 +33,10 @@
<div class="layui-card-body">
<div class="layui-tab layui-tab-brief" lay-filter="docDemoTabBrief">
<h1 style="text-align:center;"><b>鍣ㄥ叿鐐规璁″垝琛�</b></h1>
+ <ul class="layui-tab-title" lay-filter="tab-all">
+ <li lay-id="1" style="padding:1px;" class="layui-this">鍩烘湰淇℃伅</li>
+ <li lay-id="2" style="padding:1px;">鍒跺崟淇℃伅</li>
+ </ul>
<div class="layui-tab-content">
<div class="layui-tab-item layui-show">
<div class="layui-form-item">
@@ -122,12 +126,12 @@
</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="text" class="layui-input" lay-verify="HDeptName" name="HDeptName" id="HDeptName" style="background-color:#efefef4d;width: 61%;display: inline-block;" readonly>
+ <label class="layui-form-label" style="width: 85px;">閮ㄩ棬</label>
+ <div class="layui-input-inline">
+ <input type="text" name="HDeptName" id="HDeptName" class="layui-input" value="" style="float:left;width:150px;">
<input type="hidden" name="HDeptID" id="HDeptID" lay-verify="HDeptID" value="0">
- <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnHDept" id="btnHDept" style="padding: 0 10px;float: right;margin-right: 3px;">
- <i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
+ <button type="button" lay-submit="" class="layui-btn" lay-filter="btnHDept" id="btnHDept"style="width:40px;">
+ <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i>
</button>
</div>
</div>
@@ -138,6 +142,76 @@
<select name="HUSEORGID" id="HUSEORGID" lay-verify="HUSEORGID">
<!--鍔ㄦ�佹覆鏌撶粍缁�-->
</select>
+ </div>
+ </div>
+ </div>
+ </div>
+ <!--鍒跺崟淇℃伅-->
+ <div class="layui-tab-item">
+ <div class="layui-form-item">
+ <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="HMaker" id="HMaker" style="background-color:#efefef4d;" readonly>
+ </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="HChecker" id="HChecker" style="background-color:#efefef4d;" readonly>
+ </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="HCloseMan" id="HCloseMan" style="background-color:#efefef4d;" readonly>
+ </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="HUpDater" id="HUpDater" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+
+ </div>
+ <div class="layui-form-item">
+ <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="HMakeDate" id="HMakeDate" style="background-color:#efefef4d;" readonly>
+ </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="HCheckDate" id="HCheckDate" style="background-color:#efefef4d;" readonly>
+ </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="HCloseDate" id="HCloseDate" style="background-color:#efefef4d;" readonly>
+ </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="HUpDateDate" id="HUpDateDate" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+ </div>
+ <div class="layui-form-item">
+ <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="HDeleteMan" id="HDeleteMan" style="background-color:#efefef4d;" readonly>
+ </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="HDeleteDate" id="HDeleteDate" style="background-color:#efefef4d;" readonly>
</div>
</div>
</div>
@@ -186,6 +260,7 @@
<script src="../../../layuiadmin/Scripts/webConfig.js"></script>
<script src="../../../layuiadmin/PubCustom.js"></script>
<script src="../../../layuiadmin/PageTitle.js"></script>
+ <script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
<script>
//鑾峰彇鍙傛暟
var params = get_UrlVars();
@@ -221,7 +296,7 @@
//閫氳繃鍗曟嵁绫诲瀷锛屼粠鏁版嵁搴撳姩鎬佽幏鍙栧崟鎹ā鍧楀懡鍚�,寮曠敤js鏂囦欢 PageTitle.js
var HPageTitle = get_PageTitle(HModuleType) == "" ? $("h1").html() : get_PageTitle(HModuleType);
$("h1").html('<b>' + HPageTitle + '</b>');
- //#endregion
+ //#endregion
//鍒濆鍖栬〃鍗曟彃浠�
set_InitFrom();
@@ -253,7 +328,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html', 'yes'],
+ content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -291,7 +366,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../妯℃不鍏风鐞�/鍣ㄥ叿鐐规瑙勭▼鍗�/Sc_MouldDotCheckRuleBillList.html', 'yes'],
+ content: ['../../妯℃不鍏风鐞�/鍣ㄥ叿鐐规瑙勭▼鍗�/Sc_MouldDotCheckRuleBillList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -330,7 +405,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html?openType=2&HOrgName=' + sessionStorage["Organization"], 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -507,7 +582,7 @@
}
// 鐐规淇℃伅 閰嶄欢淇℃伅
- window.get_DocCheckItem2 = function(data) {
+ window.get_DocCheckItem2 = function (data) {
$.ajax({
url: GetWEBURL() + "/Sc_MouldDotCheckRuleBill/Sc_MouldDotCheckRuleBillSubAndSubItem",
type: "GET",
@@ -617,7 +692,7 @@
},
success: function (result) {
if (result.code == 1) { // 璇存槑楠岃瘉鎴愬姛浜嗭紝
- var data = result.data.h_v_Sc_MouldDotCheckPlanBillList[0];
+ var data = result.data.h_v_Sc_MouldDotCheckPlanBillMain_Edit[0];
form.val("component-form-group", { //formTest 鍗� class="layui-form" 鎵�鍦ㄥ厓绱犲睘鎬� lay-filter="" 瀵瑰簲鐨勫��
"HBillNo": data.鍗曟嵁鍙�
, "HDate": data.鏃ユ湡
@@ -638,6 +713,16 @@
, "HUSEORGID": data.HUSEORGID
, "HDeptID": data.HDeptID
, "HDeptName": data.閮ㄩ棬鍚嶇О
+ , "HMaker": data.鍒跺崟浜�
+ , "HMakeDate": data.鍒跺崟鏃ユ湡 == null ? "" : Format(new Date(data.鍒跺崟鏃ユ湡), "yyyy-MM-dd")
+ , "HChecker": data.瀹℃牳浜�
+ , "HCheckDate": data.瀹℃牳鏃ユ湡 == null ? "" : Format(new Date(data.瀹℃牳鏃ユ湡), "yyyy-MM-dd")
+ , "HUpDater": data.淇敼浜�
+ , "HUpDateDate": data.淇敼鏃ユ湡 == null ? "" : Format(new Date(data.淇敼鏃ユ湡), "yyyy-MM-dd")
+ , "HCloseMan": data.鍏抽棴浜�
+ , "HCloseDate": data.鍏抽棴鏃ユ湡 == null ? "" : Format(new Date(data.鍏抽棴鏃ユ湡), "yyyy-MM-dd")
+ , "HDeleteMan": data.浣滃簾浜�
+ , "HDeleteDate": data.浣滃簾鏃ユ湡 == null ? "" : Format(new Date(data.浣滃簾鏃ユ湡), "yyyy-MM-dd")
});
if ($("#HUSEORGID").val() == null || $("#HUSEORGID").val() == "" || $("#HUSEORGID").val() == undefined) {
$("#HUSEORGID").val(sessionStorage["OrganizationID"])
@@ -796,7 +881,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -834,7 +919,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html?Type=HManager', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -870,7 +955,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true
- , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckItemClassList.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckItemClassList.html?openType=2', 'yes']
, btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -903,7 +988,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true
- , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckItemMethodList.html', 'yes']
+ , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckItemMethodList.html?openType=2', 'yes']
, btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldMaintainBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldMaintainBillList.html"
index b9208c0..c50ca4f 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldMaintainBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldMaintainBillList.html"
@@ -46,6 +46,7 @@
<ul class="layui-tab-title">
<li class="layui-this">鍩烘湰淇℃伅</li>
<li>闄勪欢淇℃伅</li>
+ <li>鍒跺崟淇℃伅</li>
</ul>
<h1 style="text-align:center;"><b>鍣ㄥ叿淇濆吇璁板綍琛�</b></h1>
<div class="layui-tab-content">
@@ -131,7 +132,7 @@
<div class="layui-inline">
<label class="layui-form-label">瑕佹眰瀹屾垚鏃ユ湡</label>
<div class="layui-input-inline">
- <input class="layui-input" id="HRequestComDate" name="HRequestComDate" autocomplete="off" model="datetime" dateFormat="yyyy-MM-dd" placeholder="yyyy-MM-dd">
+ <input class="layui-input" id="HRequestComDate" name="HRequestComDate" autocomplete="off" model="datetime" dateFormat="yyyy-MM-dd" placeholder="yyyy-MM-dd">
</div>
</div>
<div class="layui-inline">
@@ -143,13 +144,13 @@
<div class="layui-inline">
<label class="layui-form-label">绱妯℃暟</label>
<div class="layui-input-inline">
- <input class="layui-input" name="HCumulativeModule" lay-verify="HCumulativeModule" id="HCumulativeModule" value="0" autocomplete="off">
+ <input class="layui-input" name="HCumulativeModule" lay-verify="HCumulativeModule" id="HCumulativeModule" value="0" autocomplete="off">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">鏈鐢熶骇妯℃暟</label>
<div class="layui-input-inline">
- <input class="layui-input" name="HProductionModule" lay-verify="HProductionModule" id="HProductionModule" value="0" autocomplete="off">
+ <input class="layui-input" name="HProductionModule" lay-verify="HProductionModule" id="HProductionModule" value="0" autocomplete="off">
</div>
</div>
</div>
@@ -194,6 +195,76 @@
<tbody id="ProImgByList" class="ProImgByList">
</tbody>
</table>
+ </div>
+ </div>
+ </div>
+ </div>
+ <!--鍒跺崟淇℃伅-->
+ <div class="layui-tab-item">
+ <div class="layui-form-item">
+ <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="HMaker" id="HMaker" style="background-color:#efefef4d;" readonly>
+ </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="HChecker" id="HChecker" style="background-color:#efefef4d;" readonly>
+ </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="HCloseMan" id="HCloseMan" style="background-color:#efefef4d;" readonly>
+ </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="HUpDater" id="HUpDater" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+
+ </div>
+ <div class="layui-form-item">
+ <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="HMakeDate" id="HMakeDate" style="background-color:#efefef4d;" readonly>
+ </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="HCheckDate" id="HCheckDate" style="background-color:#efefef4d;" readonly>
+ </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="HCloseDate" id="HCloseDate" style="background-color:#efefef4d;" readonly>
+ </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="HUpDateDate" id="HUpDateDate" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+ </div>
+ <div class="layui-form-item">
+ <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="HDeleteMan" id="HDeleteMan" style="background-color:#efefef4d;" readonly>
+ </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="HDeleteDate" id="HDeleteDate" style="background-color:#efefef4d;" readonly>
</div>
</div>
</div>
@@ -264,6 +335,7 @@
<script src="../../../layuiadmin/Scripts/webConfig.js"></script>
<script src="../../../layuiadmin/PubCustom.js"></script>
<script src="../../../layuiadmin/PageTitle.js"></script>
+ <script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
<script>
//鑾峰彇椤甸潰璺宠浆鍙傛暟
var params = get_UrlVars();
@@ -421,7 +493,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../妯℃不鍏风鐞�/Sc_MouldMaintainPlanBillList.html', 'yes'],
+ content: ['../妯℃不鍏风鐞�/Sc_MouldMaintainPlanBillList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -462,7 +534,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_MaintainLev.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_MaintainLev.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -499,7 +571,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../妯℃不鍏风鐞�/Gy_MouldFileList.html', 'yes'],
+ content: ['../妯℃不鍏风鐞�/Gy_MouldFileList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -539,7 +611,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Sc_MouldMaintainRuleBillList.html', 'yes'],
+ content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Sc_MouldMaintainRuleBillList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -596,7 +668,7 @@
var PJData = result.list[1];//閰嶄欢
var rowdate1 = layui.table.cache["mainTable"];
var rowdate2 = layui.table.cache["mainTable1"];
- option.data = [{ "HMaintainItemID": 0, "HMaintainItemNumber": " ", "HMaintainItem": " ", "HMaintainPart": " ", "HClaim": " ", "HManagerID": "0 ", "HManagerNumber": " ", "HManagerName": " ", "HRemark": " ", "HMaintainResult": "Y"}];
+ option.data = [{ "HMaintainItemID": 0, "HMaintainItemNumber": " ", "HMaintainItem": " ", "HMaintainPart": " ", "HClaim": " ", "HManagerID": "0 ", "HManagerNumber": " ", "HManagerName": " ", "HRemark": " ", "HMaintainResult": "Y" }];
option2.data = [{ "HMaterID": 0, "HMaterNumber": " ", "HMaterName": " ", "HMaterSpec": " ", "HUnitID": "0", "HUnitNumber": " ", "HUnitName": " ", "HQty": "0", "HQtyMust": "0", "HRemark": " " }];
table.render(option);
table.render(option2);
@@ -794,7 +866,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_MaintainList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_MaintainList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -831,7 +903,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html?Type=HManager', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -882,7 +954,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Material.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Material.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
@@ -921,7 +993,7 @@
shift: 2,
area: ['90%', '90%'],
maxmin: true,
- content: ['../../../views/鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Unit.html', 'yes'],
+ content: ['../../../views/鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Unit.html?Type=HUnitList', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -1196,6 +1268,16 @@
, "HRecentMainModule": data.鏈�杩戜繚鍏绘ā鏁�
, "HCumulativeModule": data.绱妯℃暟
, "HProductionModule": data.鏈鐢熶骇妯℃暟
+ , "HMaker": data.鍒跺崟浜�
+ , "HMakeDate": data.鍒跺崟鏃ユ湡 == null ? "" : Format(new Date(data.鍒跺崟鏃ユ湡), "yyyy-MM-dd")
+ , "HChecker": data.瀹℃牳浜�
+ , "HCheckDate": data.瀹℃牳鏃ユ湡 == null ? "" : Format(new Date(data.瀹℃牳鏃ユ湡), "yyyy-MM-dd")
+ , "HUpDater": data.淇敼浜�
+ , "HUpDateDate": data.淇敼鏃ユ湡 == null ? "" : Format(new Date(data.淇敼鏃ユ湡), "yyyy-MM-dd")
+ , "HCloseMan": data.鍏抽棴浜�
+ , "HCloseDate": data.鍏抽棴鏃ユ湡 == null ? "" : Format(new Date(data.鍏抽棴鏃ユ湡), "yyyy-MM-dd")
+ , "HDeleteMan": data.浣滃簾浜�
+ , "HDeleteDate": data.浣滃簾鏃ユ湡 == null ? "" : Format(new Date(data.浣滃簾鏃ユ湡), "yyyy-MM-dd")
});
if (data.鏈�缁堢粨璁� == "涓嶅悎鏍�") {
document.querySelectorAll("[name='HLastResult']")[0].removeAttribute('checked'); //鍒犻櫎閫夋嫨灞炴��
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldRepairCheckBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldRepairCheckBillList.html"
index 75b0048..d35864f 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldRepairCheckBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_Add_MouldRepairCheckBillList.html"
@@ -23,21 +23,17 @@
<form id="form0" class="layui-form" lay-filter="component-form-group" action="">
<div class="layui-card-header">
<div class="layui-btn-group">
-
<button type="button" id="add-btn" class="layui-btn layui-btn-normal layui-btn-radius" lay-submit="" lay-filter="Saver">淇濆瓨</button>
<button type="button" class="layui-btn layui-btn-normal layui-btn-radius" lay-submit="" lay-filter="Exit">閫�鍑�</button>
-
-
</div>
-
</div>
<div class="layui-card-body">
<div class="layui-tab layui-tab-brief" lay-filter="docDemoTabBrief">
- <!--<ul class="layui-tab-title">
- <li class="layui-this">鍩烘湰淇℃伅</li>-->
- <!--<li>鍏朵粬淇℃伅</li>-->
- <!--</ul>-->
<h1 style="text-align:center;"><b>鍣ㄥ叿缁翠慨楠屾敹鍗�</b></h1>
+ <ul class="layui-tab-title" lay-filter="tab-all">
+ <li lay-id="1" style="padding:1px;" class="layui-this">鍩烘湰淇℃伅</li>
+ <li lay-id="2" style="padding:1px;">鍒跺崟淇℃伅</li>
+ </ul>
<div class="layui-tab-content">
<div class="layui-tab-item layui-show">
<div class="layui-form-item">
@@ -143,6 +139,76 @@
<label class="layui-form-label">澶囨敞</label>
<div class="layui-input-inline">
<textarea placeholder="璇疯緭鍏ュ娉�" class="layui-textarea" name="HRemark" id="HRemark"></textarea>
+ </div>
+ </div>
+ </div>
+ </div>
+ <!--鍒跺崟淇℃伅-->
+ <div class="layui-tab-item">
+ <div class="layui-form-item">
+ <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="HMaker" id="HMaker" style="background-color:#efefef4d;" readonly>
+ </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="HChecker" id="HChecker" style="background-color:#efefef4d;" readonly>
+ </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="HCloseMan" id="HCloseMan" style="background-color:#efefef4d;" readonly>
+ </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="HUpDater" id="HUpDater" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+
+ </div>
+ <div class="layui-form-item">
+ <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="HMakeDate" id="HMakeDate" style="background-color:#efefef4d;" readonly>
+ </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="HCheckDate" id="HCheckDate" style="background-color:#efefef4d;" readonly>
+ </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="HCloseDate" id="HCloseDate" style="background-color:#efefef4d;" readonly>
+ </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="HUpDateDate" id="HUpDateDate" style="background-color:#efefef4d;" readonly>
+ </div>
+ </div>
+ </div>
+ <div class="layui-form-item">
+ <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="HDeleteMan" id="HDeleteMan" style="background-color:#efefef4d;" readonly>
+ </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="HDeleteDate" id="HDeleteDate" style="background-color:#efefef4d;" readonly>
</div>
</div>
</div>
@@ -273,7 +339,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html', 'yes'],
+ content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Gy_MouldFileList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -349,7 +415,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_DepartmentList.html?openType=2&HOrgName=' + sessionStorage["Organization"], 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -426,7 +492,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Sb_MouldRepairWorkBillList.html', 'yes'],
+ content: ['../../妯℃不鍏风鐞�/妯℃不鍏风鐞�/Sb_MouldRepairWorkBillList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -611,6 +677,16 @@
, "HMainSourceBillNo": data.HMouldRepairWorkNo //缁翠慨璁板綍鍗�
, "HMainSourceInterID": data.HMouldRepairWorkID //缁翠慨璁板綍鍐呯爜
, "HMainSourceEntryID": data.HMouldRepairWorkEntryID == undefined ? 1 : data.HMouldRepairWorkEntryID //缁翠慨璁板綍瀛愬唴鐮�
+ , "HMaker": data.鍒跺崟浜�
+ , "HMakeDate": data.鍒跺崟鏃ユ湡 == null ? "" : Format(new Date(data.鍒跺崟鏃ユ湡), "yyyy-MM-dd")
+ , "HChecker": data.瀹℃牳浜�
+ , "HCheckDate": data.瀹℃牳鏃ユ湡 == null ? "" : Format(new Date(data.瀹℃牳鏃ユ湡), "yyyy-MM-dd")
+ , "HUpDater": data.淇敼浜�
+ , "HUpDateDate": data.淇敼鏃ユ湡 == null ? "" : Format(new Date(data.淇敼鏃ユ湡), "yyyy-MM-dd")
+ , "HCloseMan": data.鍏抽棴浜�
+ , "HCloseDate": data.鍏抽棴鏃ユ湡 == null ? "" : Format(new Date(data.鍏抽棴鏃ユ湡), "yyyy-MM-dd")
+ , "HDeleteMan": data.浣滃簾浜�
+ , "HDeleteDate": data.浣滃簾鏃ユ湡 == null ? "" : Format(new Date(data.浣滃簾鏃ユ湡), "yyyy-MM-dd")
});
} else {
@@ -732,7 +808,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_RepairCheckList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_RepairCheckList.html?openType=2', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
@@ -773,7 +849,7 @@
shift: 2,
area: ['80%', '80%'],
maxmin: true,
- content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html', 'yes'],
+ content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EmployeeList.html?Type=HManager', 'yes'],
btn: ['纭畾', '鍙栨秷']
, btn1: function (index, layero) {
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldConkBookBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldConkBookBillList.html"
index 82386d4..cb74cde 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldConkBookBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldConkBookBillList.html"
@@ -9,9 +9,10 @@
<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/HideButton.js"></script>
<script src="../../../layuiadmin/soulTable.slim.js"></script>
<script src="../../../layuiadmin/PageTitle.js"></script>
+ <script src="../../../layuiadmin/SetColumn.js"></script>
+ <script src="../../../layuiadmin/HideButton_New.js"></script>
<style type="text/css">
input.layui-input.layui-unselect {
@@ -32,44 +33,45 @@
<span>鏇村</span>
</div>
</div>
- <!--<div class="layui-inline">
- <label class="layui-form-label">鍗曟嵁绫诲瀷</label>
- <div class="layui-input-block">
- <select name="HBillType" id="HBillType">
- <option value="">鎵�鏈�</option>
- <option value="ZHXJ">涓嬫灦鎵捐揣鍗�</option>
- <option value="ZHSJ">涓婃灦褰掕繕鍗�</option>
- </select>
- </div>
- </div>-->
<div class="layui-inline">
<label class="layui-form-label">鍗曟嵁鍙�</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="HBillNo" id="HBillNo">
+ <input type="text" class="layui-input ForFilteringSchemes" name="HBillNo" id="HBillNo">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">鍒跺崟浜�</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="HCreateBy" id="HCreateBy">
+ <input type="text" class="layui-input ForFilteringSchemes" name="HCreateBy" id="HCreateBy">
+ </div>
+ </div>
+ <div class="layui-inline">
+ <label class="layui-form-label">鏃ユ湡闂撮殧</label>
+ <div class="layui-input-block">
+ <select name="HInitTimeCycle" id="HInitTimeCycle" class="ForFilteringSchemes" lay-filter="HInitTimeCycle" style="width:190px;">
+ </select>
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">寮�濮嬫椂闂�</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" name="BenginHCreateDate" id="BenginHCreateDate">
+ <input type="date" class="layui-input ForFilteringSchemest" name="HBeginDate" id="HBeginDate">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">缁撴潫鏃堕棿</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" name="EndHCreateDate" id="EndHCreateDate">
+ <input type="date" class="layui-input ForFilteringSchemes" name="HEndDate" id="HEndDate">
</div>
</div>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">
<i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
</button>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnReSearch" id="btnReSearch" style="padding:0 5px">閲嶇疆</button>
+ <!--鏄剧ず褰撳墠杩囨护鏂规-->
+ <div class="layui-inline" style="margin-left:5px;">
+ <div style="text-align:center;font-size:15px;font-weight:bold;color:#fc9393" id="HFilterScheme_Now"></div>
+ </div>
<div class="layui-colla-content">
<div class="layui-row">
<div class="layui-inline">
@@ -82,12 +84,12 @@
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName" id="ColName" lay-filter="ColName" style="width:190px;">
+ <select name="ColName" id="ColName" class="ForFilteringSchemes" lay-filter="ColName" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator" id="Comparator" lay-filter="Comparator" style="width:190px;">
+ <select name="Comparator" id="Comparator" class="ForFilteringSchemes" lay-filter="Comparator" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -102,19 +104,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent" id="ColContent">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent" id="ColContent">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName1" id="ColName1" lay-filter="ColName1" style="width:190px;">
+ <select name="ColName1" id="ColName1" class="ForFilteringSchemes" lay-filter="ColName1" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator1" id="Comparator1" lay-filter="Comparator1" style="width:190px;">
+ <select name="Comparator1" id="Comparator1" class="ForFilteringSchemes" lay-filter="Comparator1" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -129,19 +131,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent1" id="ColContent1">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent1" id="ColContent1">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName2" id="ColName2" lay-filter="ColName2" style="width:190px;">
+ <select name="ColName2" id="ColName2" class="ForFilteringSchemes" lay-filter="ColName2" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator2" id="Comparator2" lay-filter="Comparator2" style="width:190px;">
+ <select name="Comparator2" id="Comparator2" class="ForFilteringSchemes" lay-filter="Comparator2" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -156,7 +158,7 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent2" id="ColContent2">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent2" id="ColContent2">
</div>
</div>
</div>
@@ -164,12 +166,16 @@
<table class="" id="mainTable" lay-filter="mainTable"></table>
<div id="page" style="position: relative; bottom: 0;"></div>
<script type="text/html" id="toolbarDemo">
- <div class="layui-btn-container">
+ <div class="layui-btn-container" id="toolbarDemo_ButtonSet">
<!--<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-getCheckData"><i class="layui-icon layui-icon-tips"></i>棰勮</button>-->
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Add" id="btn-Add"><i class="layui-icon layui-icon-add-1"></i>鏂板</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Edit" id="btn-Edit"><i class="layui-icon layui-icon-edit"></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="btn-reload" id="btn-reload"><i class="layui-icon layui-icon-refresh"></i>鍒锋柊</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_CheckBill" id="CheckBill"><i class="layui-icon layui-icon-form"></i>瀹℃牳</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_AbandonCheck" id="AbandonCheck"><i class="layui-icon layui-icon-form"></i>鍙嶅鏍�</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Close" id="Close"><i class="layui-icon layui-icon-radio"></i>鍏抽棴</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeClose" id="DeClose"><i class="layui-icon layui-icon-radio"></i>鍙嶅叧闂�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-confirm" id="btn_confirm"><i class="layui-icon layui-icon-ok-circle"></i>纭</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-back" id="btn_back"><i class="layui-icon layui-icon-close-fill"></i>椹冲洖</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-details" id="btn-details"><i class="layui-icon layui-icon-form"></i>璇︽儏</button>
@@ -177,10 +183,13 @@
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-exit" id="btn-exit"><i class="layui-icon layui-icon-return"></i>閫�鍑�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_HideColumn" id="set_HideColumn"><i class="layui-icon layui-icon-form"></i>鍒楄缃�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_HideButton" id="HideButton"><i class="layui-icon layui-icon-form"></i>鎸夐挳璁剧疆</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_SaveScheme" id="set_SaveScheme"><i class="layui-icon layui-icon-template"></i>淇濆瓨鏂规</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_ReadScheme" id="set_ReadScheme"><i class="layui-icon layui-icon-set"></i>璇诲彇鏂规</button>
</div>
</script>
-</form>
+ </div>
+ </form>
</div>
</div>
</div>
@@ -215,9 +224,23 @@
var titleData = ["hmainid", "鍗曟嵁ID", "鍗曟嵁绫诲瀷", "hempid", "HConkTypeID", "HDeptID", "HMouldID", "hsubid", "HConkReasonID", "HManagerID", "琛ㄤ綋澶囨敞", "婧愬崟涓诲唴鐮�", "婧愬崟瀛愬唴鐮�", "HEmpID", "HBillType"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
var page = 1;//鍒嗛〉鏁版嵁
var size = 50;
+
+ var set_HideButton_ID = "toolbarDemo_ButtonSet";//闇�瑕佽缃殑鎸夐挳鐨勭埗绾ц妭鐐圭殑id
//#endregion
//#region 杩涘叆椤甸潰鍗冲姞杞�
+
+ //#region 銆愯繃婊ゆ柟妗堛��
+
+ //杩囨护鏉′欢鐨刢lass绫�
+ var HClassTag = "ForFilteringSchemes";
+ //妯″潡鍚嶇О锛堜腑鏂囩増锛� 姣忎釜妯″潡椤甸潰閮介渶瑕佷慨鏀�
+ window.HModuleName = "鍣ㄥ叿鏁呴殰鐧昏鍗�";
+ //鏄惁宸茬粡閫夋嫨浜嗚繃婊ゆ柟妗堬紙鍏ㄥ眬鍙橀噺锛�
+ window.HDefaultFilter = "";
+ //閫夋嫨鐨勮繃婊ゆ柟妗堝唴鐮侊紙鍏ㄥ眬鍙橀噺锛�
+ window.HInterID_Choose = 0;
+ //#endregion
//#region 銆愬姩鎬佽幏鍙栨ā鍧楀悕绉般��
var HModuleType = "3815";
@@ -226,9 +249,7 @@
//#endregion
//鍒濆鍖栫晫闈�
- set_ClearBill();
- //鍒濆鍖栬〃鏍�
- DisPlay_HideColumn();
+ set_ClearBill();
//#endregion
//#region 瑙﹀彂浜嬩欢锛氬寘鎷琭orm.on(){}鏍煎紡鐨勬墍鏈夌偣鍑讳簨浠躲�侀�夋嫨浜嬩欢绛�
@@ -252,12 +273,31 @@
case 'get_Exit': Pub_Close(2);
break;
//鍒楄缃�
- case 'set_HideColumn': get_HideColumn();
+ case 'set_HideColumn': get_HideColumnNoPage(HModName, sessionStorage["HUserName"], option, get_FastQuery);
break;
//鎸夐挳璁剧疆
case 'set_HideButton':
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- get_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ get_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
+ break;
+ //瀹℃牳
+ case 'set_CheckBill': set_CheckBill(1);
+ break;
+ //鍙嶅鏍�
+ case 'set_AbandonCheck': set_CheckBill(2);
+ break;
+ //鍏抽棴鎸夐挳 锛�0:鍏抽棴銆�1:鍙嶅叧闂級
+ case 'btn-Close':
+ set_CloseBill(0);
+ break;
+ //鍙嶅叧闂寜閽�
+ case 'btn-DeClose':
+ set_CloseBill(1);
+ break;
+ //淇濆瓨鏂规
+ case 'set_SaveScheme': set_SaveScheme();
+ break;
+ //璇诲彇鏂规
+ case 'set_ReadScheme': set_ReadScheme();
break;
};
});
@@ -273,10 +313,11 @@
//閲嶇疆鎸夐挳
form.on('submit(btnReSearch)', function (data) {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
$("#HBillNo").val("");//鍗曟嵁鍙�
$("#HCreateBy").val("");//鍒跺崟浜�
- $("#BenginHCreateDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
- $("#EndHCreateDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
$("#btnSearch").click();
$("#ColContent").val("");
$("#ColName").val("0");
@@ -322,17 +363,50 @@
})
//#endregion
+ //鏃ユ湡闂撮殧涓嬫媺鍒楄〃鐩戝惉
+ form.on('select(HInitTimeCycle)', function (data) {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+ });
+
//#endregion
//鍒濆鍖栫晫闈�
function set_ClearBill() {
- $("#BenginHCreateDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
- $("#EndHCreateDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
+ //鍒濆鍖栨棩鏈熼棿闅斻�佸紑濮嬫棩鏈熴�佺粨鏉熸棩鏈�
+ setSelect_HInitTimeCycle();
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
//鍒濆鍖栬〃鏍�
set_InitGrid();
//鏌ヨ
//get_Display(sWhere);
get_FastQuery();
+ //鏌ヨ褰撳墠鐧诲綍鐢ㄦ埛鏈夋病鏈夊湪褰撳墠妯″潡璁剧疆榛樿杩囨护鏂规
+ get_DefaultModule();
}
//鍒濆鍖栬〃鏍�
@@ -503,8 +577,8 @@
function get_FastQuery() {
var HBillNo = $("#HBillNo").val();//鍗曟嵁鍙�
var HCreateBy = $("#HCreateBy").val();//鍒跺崟浜�
- var BenginHCreateDate = $("#BenginHCreateDate").val();//寮�濮嬪埗鍗曟椂闂�
- var EndHCreateDate = $("#EndHCreateDate").val();//缁撴潫鍒跺崟鏃堕棿
+ var HBeginDate = $("#HBeginDate").val();//寮�濮嬪埗鍗曟椂闂�
+ var HEndDate = $("#HEndDate").val();//缁撴潫鍒跺崟鏃堕棿
var ColName = $("#ColName").val();//澶嶉�夋
var Comparator = $("#Comparator").val()
var ColContent = $("#ColContent").val();
@@ -574,7 +648,7 @@
com2 = "not like'%" + ColContent2 + "%'";
break;
default:
- com2 = "" + Comparator + "'" + ColContent + "'";
+ com2 = "" + Comparator2 + "'" + ColContent2 + "'";
break;
}
sWhere += " and " + ColName2 + " " + com2;
@@ -585,11 +659,11 @@
if (HCreateBy) {
sWhere += " and 鍒跺崟浜� like '%" + HCreateBy + "%'";
}
- if (BenginHCreateDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + BenginHCreateDate + "'";
+ if (HBeginDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + HBeginDate + "'";
}
- if (EndHCreateDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + EndHCreateDate + "'";
+ if (HEndDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + HEndDate + "'";
}
//get_Display(sWhere);
get_DisplayPage(sWhere);
@@ -599,12 +673,14 @@
//鍒嗛〉鏌ヨ
function get_DisplayPage(sWhere) {
var ajaxLoad = layer.load();
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
$.ajax({
url: GetWEBURL() + '/Sc_MouldConkBookBill/GetMouldConkBookBillListPage',
type: "GET",
data: { "sWhere": sWhere, "user": sessionStorage["HUserName"], "page": page, "size": size },
success: function (data1) {
option.limit = size;//鏀瑰彉琛ㄦ牸椤靛ぇ灏�
+ optionPage.count = data1.count;
if (data1.code == 1) {
optionPage.count = data1.count;//鏀瑰彉鍒楄〃鏁版嵁鎬绘暟
var data = [];
@@ -649,13 +725,18 @@
option.totalRow = true;
laypage.render(optionPage);
- //鍒锋柊琛ㄦ牸鏁版嵁
- DisPlay_HideColumn();
+ //鍒楄缃�
+ DisPlay_HideColumn(HModName, sessionStorage["HUserName"], option, titleData);
+
+ ////鍒锋柊琛ㄦ牸鏁版嵁
+ ins = table.render(option);
layer.close(ajaxLoad);
if ($("#Comparator").val() == 0 && $("#ColContent").val() == "") {
ColFilter();
}
+ //鍒锋柊鎸夐挳鏄剧ず
+ Display_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
} else {
layer.close(ajaxLoad);
@@ -759,126 +840,75 @@
}
}
- //闅愯棌鍒楄缃�
- function get_HideColumn() {
- var colName = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
- }
+ //瀹℃牳/鍙嶅鏍�
+ function set_CheckBill(num) {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
- 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.html?HModName=' + HModName + '&colName=' + colName, "yes"]
- , btn: ["纭畾", "鍙栨秷"]
- , btn1: function (index, laero) {
- //鍒锋柊琛ㄦ牸鏁版嵁
- DisPlay_HideColumn();
- //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹�
- layer.close(index);//鍏抽棴寮圭獥
- }
- })
- }
-
- //鏄剧ず鍒楁暟鎹�
- function DisPlay_HideColumn() {
- $.ajax({
- url: GetWEBURL() + '/Xt_grdAlignment_WMES/grdAlignmentWMESList',
- type: "GET",
- data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
- success: function (data1) {
- if (data1.data.length != 0) {
-
-
- var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- /* var titleData = ["鍗曟嵁ID", "鍗曟嵁绫诲瀷", "hempid", "HConkTypeID", "HDeptID", "HMouldID", "hsubid", "HConkReasonID", "HManagerID", "琛ㄤ綋澶囨敞", "婧愬崟涓诲唴鐮�","婧愬崟瀛愬唴鐮�"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�*/
-
- 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;";
+ if (data.length == 1) {
+ layer.confirm("纭瑕佸鏍稿悧?", function (index) {
+ var wait = layer.load();
+ var HInterID = data[0].hmainid;
+ $.ajax({
+ url: GetWEBURL() + '/Sc_MouldConkBookBill/CheckSc_MouldConkBookBill',
+ type: "GET",
+ data: { "HInterID": HInterID, "Type": num, "user": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ get_FastQuery();
+ layer.msg(result.Message, { icon: 1 });
+ layer.close(wait);
} else {
- option.cols[0][i + 1]["style"] = "font-size:100%";
+ layer.alert(result.code + result.Message, { icon: 5 });
+ layer.close(wait);
}
- //璁剧疆鍒楀
- //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;
- }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ layer.close(wait);
}
-
- //鍙栨秷鍐荤粨鍒�
- 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);
-
-
- //鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
- } else {
- table.render(option);
-
-
- //鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
- }
- }, error: function () {
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- })
+ });
+ })
+ } else {
+ layer.msg("璇烽�夋嫨涓�鏉℃暟鎹�!");
+ }
}
+ //#region 鍙嶅叧闂�/鍏抽棴鏁版嵁
+ function set_CloseBill(num) {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var InterID = data[0].hmainid.toString();
+ //閫昏緫瀹℃牳鏂规硶
+ $.ajax({
+ type: "GET",
+ url: GetWEBURL() + "/Sc_MouldConkBookBill/CloseSc_MouldConkBookBill", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ data: { "HInterID": InterID, "IsAudit": num, "CurUserName": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ $("#btnSearch").trigger('click');
+ });
+
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹叧闂紒');
+ }
+ }
+ //#endregion
+
//#region 鍒楁槑鏄剧ず涓嬫媺妗�
function ColFilter() {
var Organization = '<option value="0" selected="selected" ></option>';
@@ -897,10 +927,317 @@
}
//#endregion
+ //#region 鍒濆鏃ユ湡闂撮殧 涓嬫媺鍒楄〃
+ function setSelect_HInitTimeCycle() {
+ var valueList = [0, 1, 2, 3, 4, 5, 6, 29];
+ var titleList = ["浠婂ぉ", "杩戜袱澶�", "杩戜笁澶�", "杩戝洓澶�", "杩戜簲澶�", "杩戝叚澶�", "杩戜竷澶�", "杩�30澶�"];
+
+ var HInitTimeCycle_ArrayList = '<option value="-1" selected="selected" >浠绘剰闂撮殧</option>';
+ for (var i = 0; i < valueList.length; i++) {
+ HInitTimeCycle_ArrayList += '<option style="color:blue;" value="' + valueList[i] + '">' + titleList[i] + '</option>';
+ }
+
+ $("#HInitTimeCycle").empty();
+ $("#HInitTimeCycle").append(HInitTimeCycle_ArrayList);
+ form.render('select');
+
+ $("#HInitTimeCycle").val("29");
+ }
+ //#endregion
+
+ //#region 鑾峰彇鍙傛暟
+ function getUrlVars() {
+ var vars = [], hash;
+ var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
+ for (var i = 0; i < hashes.length; i++) {
+ hash = hashes[i].split('=');
+ vars.push(hash[0]);
+ vars[hash[0]] = hash[1];
+ }
+ return vars;
+ }
+ //#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and 鍏抽棴浜� = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
+
+ //#region 銆愯繃婊ゆ柟妗堛��
+
+ //鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
+ function get_DefaultModule() {
+ $.ajax({
+ url: GetWEBURL() + '/Xt_FastICScheme/Chooselist',
+ type: "GET",
+ 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].HInterID;
+ //杩囨护鏂规鍐呯爜
+ HInterID = data[0].HInterID
+ //杩囨护鏂规鍚嶇О
+ 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) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery(2)
+ form.render("select");
+ } else {
+ //褰撳墠鐢ㄦ埛娌℃湁璁剧疆榛樿鐨勮繃婊ゆ柟妗�
+ //闅愯棌鏄剧ず杩囨护鏂规鐨勬爣绛句俊鎭�
+ document.getElementById("HFilterScheme_Now").style.display = "none";
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery(1)
+ 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");
+ }
+ }
+ })
+ }
+
+ //#endregion
+
//浠ヤ笂鏄痩ayui妯″潡
});
+ //#region 銆愯繃婊ゆ柟妗堣繑鍥炴暟鎹��
+ function HFilterScheme(obj) //杩斿洖杩囨护鏂规
+ {
+ var HInterID = obj[0].HInterID;
+ HInterID_Choose = obj[0].HInterID;
+ $.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].HInterID
+ //鏍规嵁閫夋嫨鐨勮繃婊ゆ柟妗堝洖濉暟鎹埌鍒楄〃杩囨护鏉′欢
+ 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
</script>
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldDotCheckBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldDotCheckBillList.html"
index a5fea7f..9ae2d60 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldDotCheckBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldDotCheckBillList.html"
@@ -9,8 +9,9 @@
<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/HideButton.js"></script>
<script src="../../../layuiadmin/soulTable.slim.js"></script>
+ <script src="../../../layuiadmin/SetColumn.js"></script>
+ <script src="../../../layuiadmin/HideButton_New.js"></script>
<style type="text/css">
input.layui-input.layui-unselect {
@@ -34,50 +35,61 @@
<div class="layui-inline">
<label class="layui-form-label">鍗曟嵁鍙�</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="HBillNo" id="HBillNo">
+ <input type="text" class="layui-input ForFilteringSchemes" name="HBillNo" id="HBillNo">
+ </div>
+ </div>
+ <div class="layui-inline">
+ <label class="layui-form-label">鏃ユ湡闂撮殧</label>
+ <div class="layui-input-block">
+ <select name="HInitTimeCycle" id="HInitTimeCycle" class="ForFilteringSchemes" lay-filter="HInitTimeCycle" style="width:190px;">
+ </select>
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">寮�濮嬫椂闂�</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" name="BenginHCreateDate" id="BenginHCreateDate">
+ <input type="date" class="layui-input ForFilteringSchemes" name="HBeginDate" id="HBeginDate">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">缁撴潫鏃堕棿</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" name="EndHCreateDate" id="EndHCreateDate">
+ <input type="date" class="layui-input ForFilteringSchemes" name="HEndDate" id="HEndDate">
</div>
</div>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">
<i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
</button>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnReSearch" id="btnReSearch" style="padding:0 5px">閲嶇疆</button>
+ <!--鏄剧ず褰撳墠杩囨护鏂规-->
+ <div class="layui-inline" style="margin-left:5px;">
+ <div style="text-align:center;font-size:15px;font-weight:bold;color:#fc9393" id="HFilterScheme_Now"></div>
+ </div>
<div class="layui-colla-content">
<div class="layui-row">
<div class="layui-inline">
<label class="layui-form-label">浜у搧鍣ㄥ叿</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="PartModul" id="PartModul">
+ <input type="text" class="layui-input ForFilteringSchemes" name="PartModul" id="PartModul">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">鐐规椤圭洰</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="CheckItem" id="CheckItem">
+ <input type="text" class="layui-input ForFilteringSchemes" name="CheckItem" id="CheckItem">
</div>
</div>
</div>
- <div class="layui-ro" style="margin-top:5px">
+ <div class="layui-row">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName" id="ColName" lay-filter="ColName" style="width:190px;">
+ <select name="ColName" id="ColName" class="ForFilteringSchemes" lay-filter="ColName" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator" id="Comparator" lay-filter="Comparator" style="width:190px;">
+ <select name="Comparator" id="Comparator" class="ForFilteringSchemes" lay-filter="Comparator" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -92,19 +104,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent" id="ColContent">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent" id="ColContent">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName1" id="ColName1" lay-filter="ColName1" style="width:190px;">
+ <select name="ColName1" id="ColName1" class="ForFilteringSchemes" lay-filter="ColName1" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator1" id="Comparator1" lay-filter="Comparator1" style="width:190px;">
+ <select name="Comparator1" id="Comparator1" class="ForFilteringSchemes" lay-filter="Comparator1" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -119,19 +131,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent1" id="ColContent1">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent1" id="ColContent1">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName2" id="ColName2" lay-filter="ColName2" style="width:190px;">
+ <select name="ColName2" id="ColName2" class="ForFilteringSchemes" lay-filter="ColName2" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator2" id="Comparator2" lay-filter="Comparator2" style="width:190px;">
+ <select name="Comparator2" id="Comparator2" class="ForFilteringSchemes" lay-filter="Comparator2" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -146,25 +158,29 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent2" id="ColContent2">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent2" id="ColContent2">
</div>
</div>
</div>
<table class="" id="mainTable" lay-filter="mainTable"></table>
<div id="page" style="position: relative; bottom: 0;"></div>
<script type="text/html" id="toolbarDemo">
- <div class="layui-btn-container">
+ <div class="layui-btn-container" id="toolbarDemo_ButtonSet">
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Add" id="btn-Add"><i class="layui-icon layui-icon-add-1"></i>鏂板</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Edit" id="btn-Edit"><i class="layui-icon layui-icon-edit"></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" lay-event="set_CheckBill" id="CheckBill"><i class="layui-icon layui-icon-form"></i>瀹℃牳</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_AbandonCheck" id="AbandonCheck"><i class="layui-icon layui-icon-form"></i>鍙嶅鏍�</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Close" id="Close"><i class="layui-icon layui-icon-radio"></i>鍏抽棴</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeClose" id="DeClose"><i class="layui-icon layui-icon-radio"></i>鍙嶅叧闂�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-view" id="btn-view"><i class="layui-icon layui-icon-tips"></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_Refresh" id="get_Refresh"><i class="layui-icon layui-icon-refresh-3"></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="set_HideColumn" id="set_HideColumn"><i class="layui-icon layui-icon-form"></i>鍒楄缃�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_HideButton" id="HideButton"><i class="layui-icon layui-icon-form"></i>鎸夐挳璁剧疆</button>
-
-
+ <button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_SaveScheme" id="set_SaveScheme"><i class="layui-icon layui-icon-template"></i>淇濆瓨鏂规</button>
+ <button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_ReadScheme" id="set_ReadScheme"><i class="layui-icon layui-icon-set"></i>璇诲彇鏂规</button>
</div>
</script>
</div>
@@ -206,14 +222,43 @@
var HBillType = "3821";
var titleData = ["hmainid", "HPlanInterID", "HDotCheckItemID", "鍗曟嵁ID", "HMouldID", "hsubid", "HManagerID", "婧愬崟涓诲唴鐮�", "婧愬崟瀛愬唴鐮�", "HBillType", "HMouldDotCheckRuleID", "HShiftsID"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
+ var set_HideButton_ID = "toolbarDemo_ButtonSet";//闇�瑕佽缃殑鎸夐挳鐨勭埗绾ц妭鐐圭殑id
+
var page = 1;//鍒嗛〉鏁版嵁
var size = 50;
//#endregion
//#region 杩涘叆椤甸潰鍗冲姞杞�
+ //鍒濆鍖栨棩鏈熼棿闅斻�佸紑濮嬫棩鏈熴�佺粨鏉熸棩鏈�
+ setSelect_HInitTimeCycle();
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
- $("#BenginHCreateDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
- $("#EndHCreateDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
+
+ //杩囨护鏉′欢鐨刢lass绫�
+ var HClassTag = "ForFilteringSchemes";
+ //妯″潡鍚嶇О锛堜腑鏂囩増锛� 姣忎釜妯″潡椤甸潰閮介渶瑕佷慨鏀�
+ window.HModuleName = "鍣ㄥ叿鐐规璁板綍鍗�";
+ //鏄惁宸茬粡閫夋嫨浜嗚繃婊ゆ柟妗堬紙鍏ㄥ眬鍙橀噺锛�
+ window.HDefaultFilter = "";
+ //閫夋嫨鐨勮繃婊ゆ柟妗堝唴鐮侊紙鍏ㄥ眬鍙橀噺锛�
+ window.HInterID_Choose = 0;
+ //#endregion
+ //#region 銆愬姩鎬佽幏鍙栨ā鍧楀悕绉般��
+ var HModuleType = "3821";
+ //閫氳繃鍗曟嵁绫诲瀷锛屼粠鏁版嵁搴撳姩鎬佽幏鍙栧崟鎹ā鍧楀懡鍚�,寮曠敤js鏂囦欢 PageTitle.js
+ var HPageTitle = get_PageTitle(HModuleType) == "" ? document.title : get_PageTitle(HModuleType);
+ //#endregion
+
//#region 銆愬姩鎬佽幏鍙栨ā鍧楀悕绉般��
var HModuleType = "3821";
@@ -226,6 +271,8 @@
//鍔犺浇鏁版嵁鍒扮綉鏍�
//get_Display(sWhere);
get_FastQuery();
+ //鑾峰彇榛樿鏂规
+ get_DefaultModule();
//#endregion
//#region 瑙﹀彂浜嬩欢锛氬寘鎷琭orm.on(){}鏍煎紡鐨勬墍鏈夌偣鍑讳簨浠躲�侀�夋嫨浜嬩欢绛�
@@ -240,6 +287,20 @@
//缂栬緫
case 'btn-Edit':
set_ShowBill();
+ break;
+ //瀹℃牳
+ case 'set_CheckBill': set_CheckBill(1);
+ break;
+ //鍙嶅鏍�
+ case 'set_AbandonCheck': set_CheckBill(2);
+ break;
+ //鍏抽棴鎸夐挳 锛�0:鍏抽棴銆�1:鍙嶅叧闂級
+ case 'btn-Close':
+ set_CloseBill(0);
+ break;
+ //鍙嶅叧闂寜閽�
+ case 'btn-DeClose':
+ set_CloseBill(1);
break;
//鍒犻櫎
case 'btn-Delete':
@@ -280,13 +341,17 @@
parent.layui.admin.events.closeThisTabs();
break;
//鍒楄缃�
- case 'set_HideColumn':
- get_HideColumn();
+ case 'set_HideColumn': get_HideColumnNoPage(HModName, sessionStorage["HUserName"], option, get_FastQuery);
break;
//鎸夐挳璁剧疆
case 'set_HideButton':
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- get_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ get_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
+ break;
+ //淇濆瓨鏂规
+ case 'set_SaveScheme': set_SaveScheme();
+ break;
+ //璇诲彇鏂规
+ case 'set_ReadScheme': set_ReadScheme();
break;
};
});
@@ -315,14 +380,34 @@
});
})
//#endregion
+
+ //鏃ユ湡闂撮殧涓嬫媺鍒楄〃鐩戝惉
+ form.on('select(HInitTimeCycle)', function (data) {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+ });
//#region 鏈〉闈㈡墍鏈夎璋冪敤鐨勬柟娉�
//閲嶇疆杩囨护鏉′欢
function set_ClearQuery() {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
$("#HBillNo").val("");
$("#PartModul").val("");
- $("#BenginHCreateDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
- $("#EndHCreateDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
$("#ColContent").val("");
$("#ColName").val("0");
$("#Comparator").val("0");
@@ -349,8 +434,8 @@
var HBillNo = $("#HBillNo").val();//鍗曟嵁鍙�
var PartModul = $("#PartModul").val();//浜у搧妯″叿
var CheckItem = $("#CheckItem").val();//鐐规椤圭洰
- var BenginHCreateDate = $("#BenginHCreateDate").val();//寮�濮嬫棩鏈�
- var EndHCreateDate = $("#EndHCreateDate").val();//缁撴潫鏃ユ湡
+ var HBeginDate = $("#HBeginDate").val();//寮�濮嬫棩鏈�
+ var HEndDate = $("#HEndDate").val();//缁撴潫鏃ユ湡
var ColName = $("#ColName").val();//澶嶉�夋
var Comparator = $("#Comparator").val()
var ColContent = $("#ColContent").val();
@@ -420,7 +505,7 @@
com2 = "not like'%" + ColContent2 + "%'";
break;
default:
- com2 = "" + Comparator + "'" + ColContent + "'";
+ com2 = "" + Comparator2 + "'" + ColContent2 + "'";
break;
}
sWhere += " and " + ColName2 + " " + com2;
@@ -435,11 +520,11 @@
if (CheckItem) {
sWhere += " and 鐐规椤圭洰 like '%" + HBillNo + "%'";
}
- if (BenginHCreateDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + BenginHCreateDate + "'";
+ if (HBeginDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + HBeginDate + "'";
}
- if (EndHCreateDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + EndHCreateDate + "'";
+ if (HEndDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + HEndDate + "'";
}
get_DisplayPage(sWhere);
@@ -530,6 +615,7 @@
data: { "sWhere": sWhere, "user": sessionStorage["HUserName"], "page": page, "size": size },
success: function (data1) {
option.limit = size;//鏀瑰彉琛ㄦ牸椤靛ぇ灏�
+ optionPage.count = data1.count;
if (data1.code == 1) {
optionPage.count = data1.count;//鏀瑰彉鍒楄〃鏁版嵁鎬绘暟
var data = [];
@@ -572,15 +658,16 @@
option.cols = [col];
option.data = data1.data;
option.totalRow = true;
+ //鍒楄缃�
+ DisPlay_HideColumn(HModName, sessionStorage["HUserName"], option, []);
+ ins = table.render(option);
laypage.render(optionPage);
- //鍒锋柊琛ㄦ牸鏁版嵁
- DisPlay_HideColumn();
layer.close(ajaxLoad);
//鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ Display_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
+
if ($("#Comparator").val() == 0 && $("#ColContent").val() == "") {
ColFilter();
}
@@ -683,6 +770,76 @@
layer.msg('璇烽�夋嫨涓�琛屾暟鎹垹闄わ紒');
}
};
+
+ //瀹℃牳/鍙嶅鏍�
+ function set_CheckBill(num) {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+
+ if (data.length == 1) {
+ layer.confirm("纭瑕佸鏍稿悧?", function (index) {
+ var wait = layer.load();
+ var HInterID = data[0].hmainid;
+ $.ajax({
+ url: GetWEBURL() + '/Sc_MouldDotCheckBill/CheckSc_MouldDotCheckBill',
+ type: "GET",
+ data: { "HInterID": HInterID, "Type": num, "user": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ get_FastQuery();
+ layer.msg(result.Message, { icon: 1 });
+ layer.close(wait);
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ layer.close(wait);
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ layer.close(wait);
+ }
+ });
+ })
+ } else {
+ layer.msg("璇烽�夋嫨涓�鏉℃暟鎹�!");
+ }
+ }
+
+ //#region 鍙嶅叧闂�/鍏抽棴鏁版嵁
+ function set_CloseBill(num) {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var InterID = data[0].hmainid.toString();
+ //閫昏緫瀹℃牳鏂规硶
+ $.ajax({
+ type: "GET",
+ url: GetWEBURL() + "/Sb_MouldRepairWorkBill/CloseSb_MouldRepairWorkBill", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ data: { "HInterID": InterID, "IsAudit": num, "CurUserName": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ $("#btnSearch").trigger('click');
+ });
+
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹叧闂紒');
+ }
+ }
+ //#endregion
+
//棰勮
function get_ViewReport() {
var checkStatus = table.checkStatus('mainTable')
@@ -801,43 +958,7 @@
}
});
}
-
- //闅愯棌鍒楄缃�
- function get_HideColumn() {
- var colName = "";
- var contentUrl = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
- }
-
- var urlStr = window.document.location.pathname;//鑾峰彇鏂囦欢璺緞
- var urlLen = urlStr.split('/');
- for (var i = 0; i < urlLen.length - 4; i++) {
- contentUrl += "../";
- }
- colName = encodeURI(colName.substring(0, colName.length - 1));//瀵� URI 杩涜缂栫爜
-
- contentUrl += '鍩虹璧勬枡/闅愯棌鍒楄缃�/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
-
- layer.open({
- type: 2
- , skin: "layui-layer-rim" //鍔犱笂杈规
- , title: "闅愯棌鍒楄缃�" //鏍囬
- , closeBtn: 1 //绐椾綋鍙充笂瑙掑叧闂� 鐨� 鏍峰紡
- , shift: 2 //寮瑰嚭鍔ㄧ敾
- , area: ["50%", "90%"] //绐椾綋澶у皬
- , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀�
- , content: [contentUrl, "yes"]
- , btn: ["纭畾", "鍙栨秷"]
- , btn1: function (index, laero) {
- //鍒锋柊琛ㄦ牸鏁版嵁
- DisPlay_HideColumn();
- //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹�
- layer.close(index);//鍏抽棴寮圭獥
- }
- })
- }
-
+
//#region 鐐瑰嚮琛岄�変腑楂樹寒
table.on('row(mainTable)', function (obj) {
//閫変腑琛屾敼鍙橀鑹�
@@ -859,128 +980,6 @@
})
//#endregion
-
- //闅愯棌鍒楄缃�
- //function get_HideColumn() {
- // var colName = "";
- // for (var i = 1; i < option.cols[0].length - 1; i++) {
- // colName += option.cols[0][i]["title"] + ",";
- // }
-
- // 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.html?HModName=' + HModName + '&colName=' + colName, "yes"]
- // , btn: ["纭畾", "鍙栨秷"]
- // , btn1: function (index, laero) {
- // //鍒锋柊琛ㄦ牸鏁版嵁
- // DisPlay_HideColumn();
- // //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹�
- // layer.close(index);//鍏抽棴寮圭獥
- // }
- // })
- //}
-
- //鏄剧ず鍒楁暟鎹�
- function DisPlay_HideColumn() {
- $.ajax({
- url: GetWEBURL() + '/Xt_grdAlignment_WMES/grdAlignmentWMESList',
- type: "GET",
- data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
- success: function (data1) {
- if (data1.data.length != 0) {
-
-
- var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
-
- 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;
- }
- option.cols[0][i + 1]["fixed"] = "left";
- }
- }
- table.render(option);
-
-
- //鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
- } else {
- table.render(option);
-
-
- //鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
- }
- }, error: function () {
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- })
- }
-
//#region 鍒楁槑鏄剧ず涓嬫媺妗�
function ColFilter() {
var Organization = '<option value="0" selected="selected" ></option>';
@@ -998,6 +997,251 @@
form.render('select');
}
//#endregion
+
+ //#region 鍒濆鏃ユ湡闂撮殧 涓嬫媺鍒楄〃
+ function setSelect_HInitTimeCycle() {
+ var valueList = [0, 1, 2, 3, 4, 5, 6, 29];
+ var titleList = ["浠婂ぉ", "杩戜袱澶�", "杩戜笁澶�", "杩戝洓澶�", "杩戜簲澶�", "杩戝叚澶�", "杩戜竷澶�", "杩�30澶�"];
+
+ var HInitTimeCycle_ArrayList = '<option value="-1" selected="selected" >浠绘剰闂撮殧</option>';
+ for (var i = 0; i < valueList.length; i++) {
+ HInitTimeCycle_ArrayList += '<option style="color:blue;" value="' + valueList[i] + '">' + titleList[i] + '</option>';
+ }
+
+ $("#HInitTimeCycle").empty();
+ $("#HInitTimeCycle").append(HInitTimeCycle_ArrayList);
+ form.render('select');
+
+ $("#HInitTimeCycle").val("29");
+ }
+ //#endregion
+
+ //#region 銆愯繃婊ゆ柟妗堛��
+
+ //鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
+ function get_DefaultModule() {
+ $.ajax({
+ url: GetWEBURL() + '/Xt_FastICScheme/Chooselist',
+ type: "GET",
+ 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) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').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");
+ }
+ }
+ })
+ }
+
+ //#endregion
+
});
function GetMouldDotCheckRuleValue(obj) { //鐐规瑙勭▼
@@ -1006,7 +1250,44 @@
get_DocCheckItem2(obj[0].hmainid);
}
+ //#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
</script>
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldDotCheckPlanBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldDotCheckPlanBillList.html"
index c9dcc4f..c735d23 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldDotCheckPlanBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldDotCheckPlanBillList.html"
@@ -9,8 +9,9 @@
<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/HideButton.js"></script>
<script src="../../../layuiadmin/soulTable.slim.js"></script>
+ <script src="../../../layuiadmin/SetColumn.js"></script>
+ <script src="../../../layuiadmin/HideButton_New.js"></script>
<style type="text/css">
input.layui-input.layui-unselect {
@@ -32,47 +33,57 @@
</div>
</div>
<div class="layui-inline">
+ <label class="layui-form-label">鏃ユ湡闂撮殧</label>
+ <div class="layui-input-block">
+ <select name="HInitTimeCycle" id="HInitTimeCycle" class="ForFilteringSchemes" lay-filter="HInitTimeCycle" style="width:190px;">
+ </select>
+ </div>
+ </div>
+ <div class="layui-inline">
<label class="layui-form-label">寮�濮嬫椂闂�</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" name="BenginHCreateDate" id="BenginHCreateDate">
+ <input type="date" class="layui-input ForFilteringSchemes" name="HBeginDate" id="HBeginDate">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">缁撴潫鏃堕棿</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" name="EndHCreateDate" id="EndHCreateDate">
+ <input type="date" class="layui-input ForFilteringSchemes" name="HEndDate" id="HEndDate">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">鍗曟嵁鍙�</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="HBillNo" id="HBillNo">
+ <input type="text" class="layui-input ForFilteringSchemes" name="HBillNo" id="HBillNo">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">鍣ㄥ叿浠g爜</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="PartModul" id="PartModul">
+ <input type="text" class="layui-input ForFilteringSchemes" name="PartModul" id="PartModul">
</div>
</div>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">
<i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
</button>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnReSearch" id="btnReSearch" style="padding:0 5px">閲嶇疆</button>
- <!--<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnReSearch" id="btnReSearch" style="padding:0 5px">閲嶇疆</button>-->
+ <!--鏄剧ず褰撳墠杩囨护鏂规-->
+ <div class="layui-inline" style="margin-left:5px;">
+ <div style="text-align:center;font-size:15px;font-weight:bold;color:#fc9393" id="HFilterScheme_Now"></div>
+ </div>
<div class="layui-colla-content">
<div class="layui-inline">
- <div class="layui-row" style="margin-top:5px">
+ <div class="layui-row">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName" id="ColName" lay-filter="ColName" style="width:190px;">
+ <select name="ColName" id="ColName" class="ForFilteringSchemes" lay-filter="ColName" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator" id="Comparator" lay-filter="Comparator" style="width:190px;">
+ <select name="Comparator" id="Comparator" class="ForFilteringSchemes" lay-filter="Comparator" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -87,19 +98,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent" id="ColContent">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent" id="ColContent">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName1" id="ColName1" lay-filter="ColName1" style="width:190px;">
+ <select name="ColName1" id="ColName1" class="ForFilteringSchemes" lay-filter="ColName1" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator1" id="Comparator1" lay-filter="Comparator1" style="width:190px;">
+ <select name="Comparator1" id="Comparator1" class="ForFilteringSchemes" lay-filter="Comparator1" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -114,19 +125,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent1" id="ColContent1">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent1" id="ColContent1">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName2" id="ColName2" lay-filter="ColName2" style="width:190px;">
+ <select name="ColName2" id="ColName2" class="ForFilteringSchemes" lay-filter="ColName2" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator2" id="Comparator2" lay-filter="Comparator2" style="width:190px;">
+ <select name="Comparator2" id="Comparator2" class="ForFilteringSchemes" lay-filter="Comparator2" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -141,7 +152,7 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent2" id="ColContent2">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent2" id="ColContent2">
</div>
</div>
</div>
@@ -151,18 +162,22 @@
</div>
<table class="" id="mainTable" lay-filter="mainTable"></table>
<script type="text/html" id="toolbarDemo">
- <div class="layui-btn-container">
+ <div class="layui-btn-container" id="toolbarDemo_ButtonSet">
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Add" id="btn-Add"><i class="layui-icon layui-icon-add-1"></i>鏂板</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Edit" id="btn-Edit"><i class="layui-icon layui-icon-edit"></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" lay-event="set_CheckBill" id="CheckBill"><i class="layui-icon layui-icon-form"></i>瀹℃牳</button>
<button type="button" class="layui-btn layui-btn-sm" lay-event="set_AbandonCheck" id="AbandonCheck"><i class="layui-icon layui-icon-form"></i>鍙嶅鏍�</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Close" id="Close"><i class="layui-icon layui-icon-radio"></i>鍏抽棴</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeClose" id="DeClose"><i class="layui-icon layui-icon-radio"></i>鍙嶅叧闂�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-view" id="btn-view"><i class="layui-icon layui-icon-tips"></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_Refresh" id="get_Refresh"><i class="layui-icon layui-icon-refresh-3"></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="set_HideColumn" id="set_HideColumn"><i class="layui-icon layui-icon-form"></i>鍒楄缃�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_HideButton" id="HideButton"><i class="layui-icon layui-icon-form"></i>鎸夐挳璁剧疆</button>
-
+ <button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_SaveScheme" id="set_SaveScheme"><i class="layui-icon layui-icon-template"></i>淇濆瓨鏂规</button>
+ <button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_ReadScheme" id="set_ReadScheme"><i class="layui-icon layui-icon-set"></i>璇诲彇鏂规</button>
</div>
</script>
</form>
@@ -201,9 +216,45 @@
var option2 = [];
var HModName = "Sc_MouldDotCheckPlanBillList";
var HBillType = "3820";
+ var optionPage = [];
+ var ins; //鐢ㄤ簬瀵煎嚭excel
+ var page = 1;//鍒嗛〉鏁版嵁
+ var size = 50;
+ //涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
+ var titleData = [];
+ var set_HideButton_ID = "toolbarDemo_ButtonSet";//闇�瑕佽缃殑鎸夐挳鐨勭埗绾ц妭鐐圭殑id
+ var Organization = sessionStorage["Organization"];
- $("#BenginHCreateDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
- $("#EndHCreateDate").val(Format(new Date(), "yyyy-MM-dd"));
+ //鍒濆鍖栨棩鏈熼棿闅斻�佸紑濮嬫棩鏈熴�佺粨鏉熸棩鏈�
+ setSelect_HInitTimeCycle();
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+ //#region 銆愯繃婊ゆ柟妗堛��
+
+ //杩囨护鏉′欢鐨刢lass绫�
+ var HClassTag = "ForFilteringSchemes";
+ //妯″潡鍚嶇О锛堜腑鏂囩増锛� 姣忎釜妯″潡椤甸潰閮介渶瑕佷慨鏀�
+ window.HModuleName = "鍣ㄥ叿鐐规璁″垝鍗�";
+ //鏄惁宸茬粡閫夋嫨浜嗚繃婊ゆ柟妗堬紙鍏ㄥ眬鍙橀噺锛�
+ window.HDefaultFilter = "";
+ //閫夋嫨鐨勮繃婊ゆ柟妗堝唴鐮侊紙鍏ㄥ眬鍙橀噺锛�
+ window.HInterID_Choose = 0;
+ //#endregion
+ //#region 銆愬姩鎬佽幏鍙栨ā鍧楀悕绉般��
+ var HModuleType = "3820";
+ //閫氳繃鍗曟嵁绫诲瀷锛屼粠鏁版嵁搴撳姩鎬佽幏鍙栧崟鎹ā鍧楀懡鍚�,寮曠敤js鏂囦欢 PageTitle.js
+ var HPageTitle = get_PageTitle(HModuleType) == "" ? document.title : get_PageTitle(HModuleType);
+ //#endregion
//#region 銆愬姩鎬佽幏鍙栨ā鍧楀悕绉般��
var HModuleType = "3820";
@@ -214,7 +265,9 @@
//鍒濆鍖栬〃鏍�
set_InitGrid();
//鍔犺浇鏁版嵁鍒扮綉鏍�
- get_Display(sWhere);
+ get_FastQuery();
+ //鑾峰彇榛樿鏂规
+ get_DefaultModule();
ColFilter();
//澶村伐鍏锋爮浜嬩欢
@@ -255,6 +308,14 @@
//鍙嶅鏍�
case 'set_AbandonCheck': set_CheckBill(2);
break;
+ //鍏抽棴鎸夐挳 锛�0:鍏抽棴銆�1:鍙嶅叧闂級
+ case 'btn-Close':
+ set_CloseBill(0);
+ break;
+ //鍙嶅叧闂寜閽�
+ case 'btn-DeClose':
+ set_CloseBill(1);
+ break;
//棰勮鎸夐挳
case 'btn-Print':
get_PrintReport();
@@ -265,8 +326,16 @@
break;
//鎸夐挳璁剧疆
case 'set_HideButton':
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- get_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ get_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
+ break;
+ //鍒楄缃�
+ case 'set_HideColumn': get_HideColumnNoPage(HModName, sessionStorage["HUserName"], option, get_FastQuery);
+ break;
+ //淇濆瓨鏂规
+ case 'set_SaveScheme': set_SaveScheme();
+ break;
+ //璇诲彇鏂规
+ case 'set_ReadScheme': set_ReadScheme();
break;
};
});
@@ -304,12 +373,31 @@
});
})
+ //鏃ユ湡闂撮殧涓嬫媺鍒楄〃鐩戝惉
+ form.on('select(HInitTimeCycle)', function (data) {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+ });
+
//蹇�熻繃婊�
function get_FastQuery(table, option) {
var HBillNo = $("#HBillNo").val();//鍗曟嵁鍙�
var PartModul = $("#PartModul").val();//浜у搧妯″叿
- var BenginHCreateDate = $("#BenginHCreateDate").val();//寮�濮嬫棩鏈�
- var EndHCreateDate = $("#EndHCreateDate").val();//缁撴潫鏃ユ湡
+ var HBeginDate = $("#HBeginDate").val();//寮�濮嬫棩鏈�
+ var HEndDate = $("#HEndDate").val();//缁撴潫鏃ユ湡
var ColName = $("#ColName").val();//澶嶉�夋
var Comparator = $("#Comparator").val()
var ColContent = $("#ColContent").val();
@@ -379,7 +467,7 @@
com2 = "not like'%" + ColContent2 + "%'";
break;
default:
- com2 = "" + Comparator + "'" + ColContent + "'";
+ com2 = "" + Comparator2 + "'" + ColContent2 + "'";
break;
}
sWhere += " and " + ColName2 + " " + com2;
@@ -390,14 +478,14 @@
if (PartModul) {
sWhere += " and 浜у搧妯″叿 like '%" + PartModul + "%'";
}
- if (BenginHCreateDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + BenginHCreateDate + "'";
+ if (HBeginDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + HBeginDate + "'";
}
- if (EndHCreateDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + EndHCreateDate + "'";
+ if (HEndDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + HEndDate + "'";
}
- get_Display(sWhere);
+ get_DisplayPage(sWhere);
sWhere = "";//璋冪敤鎺ュ彛鍚庢竻绌簊Where缂撳瓨
}
//閲嶇疆鎸夐挳
@@ -408,8 +496,9 @@
//閲嶇疆杩囨护鏉′欢
function set_ClearQuery() {
- $("#BenginHCreateDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
- $("#EndHCreateDate").val(Format(new Date(), "yyyy-MM-dd"));
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
$("#HBillNo").val("");
$("#PartModul").val(""); $("#ColContent").val("");
$("#ColName").val("0");
@@ -422,7 +511,7 @@
$("#Comparator1").val("0");
form.render('select');
sWhere = "";
- get_Display(sWhere);
+ get_FastQuery();
}
//#region 鍒楁槑鏄剧ず涓嬫媺妗�
function ColFilter() {
@@ -498,6 +587,29 @@
, { field: 'hbilltype', title: 'hbilltype', width: 200, hide: true, sort: true }
]]
};
+
+ optionPage = {
+ elem: 'page', //娉ㄦ剰锛岃繖閲岀殑 page 鏄� ID锛屼笉鐢ㄥ姞 # 鍙�
+ count: 10000, //鏁版嵁鎬绘暟锛屼粠鏈嶅姟绔緱鍒�
+ limit: 50,
+ limits: [50, 500, 5000, 50000],
+ layout: ['count', 'prev', 'page', 'next', 'limit', 'skip'],
+ jump: function (obj, first) {
+ //console.log(obj)
+ //obj鍖呭惈浜嗗綋鍓嶅垎椤电殑鎵�鏈夊弬鏁帮紝姣斿锛�
+ //console.log(obj.curr); //寰楀埌褰撳墠椤碉紝浠ヤ究鍚戞湇鍔$璇锋眰瀵瑰簲椤电殑鏁版嵁銆�
+ //console.log(obj.limit); //寰楀埌姣忛〉鏄剧ず鐨勬潯鏁�
+
+ //棣栨涓嶆墽琛�
+ if (!first) {
+ //do something
+ page = obj.curr;
+ size = obj.limit;
+ get_FastQuery();
+ }
+ }
+ }
+ laypage.render(optionPage);
}
//杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
@@ -527,6 +639,86 @@
}
});
}
+
+ //鍒嗛〉鏌ヨ
+ function get_DisplayPage() {
+ var ajaxLoad = layer.load();
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
+ //杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
+ $.ajax({
+ url: GetWEBURL() + '/Sc_MouldDotCheckPlanBill/page',
+ type: "GET",
+ data: { "sWhere": sWhere, "user": sessionStorage["HUserName"], "Organization": Organization, "page": page, "size": size },
+ success: function (data1) {
+ option.limit = size;//鏀瑰彉琛ㄦ牸椤靛ぇ灏�
+ optionPage.count = data1.count;
+ if (data1.code == "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 });
+ //鑾峰彇涓嶉渶瑕佹樉绀虹殑鍒楋紙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 ($.inArray(data[i].name, titleData) > -1) {
+ col.push({ field: data[i].id, title: data[i].name, align: 'center', hide: true }); //闅愯棌id鍒�
+ }
+ else {
+ switch (data[i].Type) {
+ //int
+ 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: 200 });
+ break;
+ case 'long':
+ case 'Int32':
+ case 'Int64':
+ case 'double':
+ case 'Decimal':
+ col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: true, width: 120, totalRow: true });
+ break;
+ default:
+ col.push({ field: data[i].id, title: data[i].name, align: 'center', sort: true, width: 200 });
+ }
+ }
+ }
+ option.cols = [col];
+ option.data = data1.data;
+ //鍒楄缃�
+ DisPlay_HideColumn(HModName, sessionStorage["HUserName"], option, []);
+
+ ins = table.render(option);
+
+ laypage.render(optionPage);
+
+ if ($("#Comparator").val() == 0 && $("#ColContent").val() == "") {
+ ColFilter();
+ }
+ //鍒锋柊鎸夐挳鏄剧ず
+ Display_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
+
+ layer.close(ajaxLoad);
+ } else {
+ option.data = [];
+ ins = table.render(option);
+ laypage.render(optionPage);
+ layer.close(ajaxLoad);
+ layer.alert(data1.code + data1.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.close(ajaxLoad);
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+
//鏂板
function set_AddNew() {
//椤甸潰灞�-鑷畾涔�
@@ -648,6 +840,60 @@
}
}
+ //#region 鍙嶅叧闂�/鍏抽棴鏁版嵁
+ function set_CloseBill(num) {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var InterID = data[0].hmainid.toString();
+ //閫昏緫瀹℃牳鏂规硶
+ $.ajax({
+ type: "GET",
+ url: GetWEBURL() + "/Sc_MouldDotCheckPlanBill/CloseSc_MouldDotCheckPlanBill", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ data: { "HInterID": InterID, "IsAudit": num, "CurUserName": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ $("#btnSearch").trigger('click');
+ });
+
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹叧闂紒');
+ }
+ }
+ //#endregion
+
+ //#region 鍒濆鏃ユ湡闂撮殧 涓嬫媺鍒楄〃
+ function setSelect_HInitTimeCycle() {
+ var valueList = [0, 1, 2, 3, 4, 5, 6, 29];
+ var titleList = ["浠婂ぉ", "杩戜袱澶�", "杩戜笁澶�", "杩戝洓澶�", "杩戜簲澶�", "杩戝叚澶�", "杩戜竷澶�", "杩�30澶�"];
+
+ var HInitTimeCycle_ArrayList = '<option value="-1" selected="selected" >浠绘剰闂撮殧</option>';
+ for (var i = 0; i < valueList.length; i++) {
+ HInitTimeCycle_ArrayList += '<option style="color:blue;" value="' + valueList[i] + '">' + titleList[i] + '</option>';
+ }
+
+ $("#HInitTimeCycle").empty();
+ $("#HInitTimeCycle").append(HInitTimeCycle_ArrayList);
+ form.render('select');
+
+ $("#HInitTimeCycle").val("29");
+ }
+ //#endregion
+
//棰勮
function get_ViewReport() {
var checkStatus = table.checkStatus('mainTable')
@@ -678,7 +924,300 @@
function set_Refresh() {
$("#btnSearch").click();
}
+
+ //#region 鑾峰彇鍙傛暟
+ function getUrlVars() {
+ var vars = [], hash;
+ var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
+ for (var i = 0; i < hashes.length; i++) {
+ hash = hashes[i].split('=');
+ vars.push(hash[0]);
+ vars[hash[0]] = hash[1];
+ }
+ return vars;
+ }
+ //#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and 鍏抽棴浜� = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
+
+ //#region 銆愯繃婊ゆ柟妗堛��
+
+ //鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
+ function get_DefaultModule() {
+ $.ajax({
+ url: GetWEBURL() + '/Xt_FastICScheme/Chooselist',
+ type: "GET",
+ 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) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').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");
+ }
+ }
+ })
+ }
+
+ //#endregion
+
});
+
+ //#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
+
</script>
</body>
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldMaintainBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldMaintainBillList.html"
index 3fc0baa..9271b1d 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldMaintainBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldMaintainBillList.html"
@@ -9,8 +9,9 @@
<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/HideButton.js"></script>
<script src="../../../layuiadmin/soulTable.slim.js"></script>
+ <script src="../../../layuiadmin/SetColumn.js"></script>
+ <script src="../../../layuiadmin/HideButton_New.js"></script>
<style type="text/css">
input.layui-input.layui-unselect {
@@ -32,44 +33,55 @@
</div>
</div>
<div class="layui-inline">
+ <label class="layui-form-label">鏃ユ湡闂撮殧</label>
+ <div class="layui-input-block">
+ <select name="HInitTimeCycle" id="HInitTimeCycle" class="ForFilteringSchemes" lay-filter="HInitTimeCycle" style="width:190px;">
+ </select>
+ </div>
+ </div>
+ <div class="layui-inline">
<label class="layui-form-label">寮�濮嬫椂闂�</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" name="BenginHCreateDate" id="BenginHCreateDate">
+ <input type="date" class="layui-input ForFilteringSchemes" name="HBeginDate" id="HBeginDate">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">缁撴潫鏃堕棿</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" name="EndHCreateDate" id="EndHCreateDate">
+ <input type="date" class="layui-input ForFilteringSchemes" name="HEndDate" id="HEndDate">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">鍗曟嵁鍙�</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="HBillNo" id="HBillNo">
+ <input type="text" class="layui-input ForFilteringSchemes" name="HBillNo" id="HBillNo">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">鍒跺崟浜�</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="HCreateBy" id="HCreateBy">
+ <input type="text" class="layui-input ForFilteringSchemes" name="HCreateBy" id="HCreateBy">
</div>
</div>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">
<i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
</button>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnReSearch" id="btnReSearch" style="padding:0 5px">閲嶇疆</button>
+ <!--鏄剧ず褰撳墠杩囨护鏂规-->
+ <div class="layui-inline" style="margin-left:5px;">
+ <div style="text-align:center;font-size:15px;font-weight:bold;color:#fc9393" id="HFilterScheme_Now"></div>
+ </div>
<div class="layui-colla-content">
<div class="layui-row">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName" id="ColName" lay-filter="ColName" style="width:190px;">
+ <select name="ColName" id="ColName" class="ForFilteringSchemes" lay-filter="ColName" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator" id="Comparator" lay-filter="Comparator" style="width:190px;">
+ <select name="Comparator" id="Comparator" class="ForFilteringSchemes" lay-filter="Comparator" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -84,19 +96,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent" id="ColContent">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent" id="ColContent">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName1" id="ColName1" lay-filter="ColName1" style="width:190px;">
+ <select name="ColName1" id="ColName1" class="ForFilteringSchemes" lay-filter="ColName1" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator1" id="Comparator1" lay-filter="Comparator1" style="width:190px;">
+ <select name="Comparator1" id="Comparator1" class="ForFilteringSchemes" lay-filter="Comparator1" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -111,19 +123,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent1" id="ColContent1">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent1" id="ColContent1">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName2" id="ColName2" lay-filter="ColName2" style="width:190px;">
+ <select name="ColName2" id="ColName2" class="ForFilteringSchemes" lay-filter="ColName2" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator2" id="Comparator2" lay-filter="Comparator2" style="width:190px;">
+ <select name="Comparator2" id="Comparator2" class="ForFilteringSchemes" lay-filter="Comparator2" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -138,7 +150,7 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent2" id="ColContent2">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent2" id="ColContent2">
</div>
</div>
</div>
@@ -160,11 +172,13 @@
</div>
<div id="page" style="position: relative; bottom: 0;"></div>
<script type="text/html" id="toolbarDemo">
- <div class="layui-btn-container">
+ <div class="layui-btn-container" id="toolbarDemo_ButtonSet">
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Add" id="btn-Add"><i class="layui-icon layui-icon-add-1"></i>鏂板</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Edit" id="btn-Edit"><i class="layui-icon layui-icon-edit"></i>缂栬緫</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_CheckBill" id="set_CheckBill"><i class="layui-icon layui-icon-form"></i>瀹℃牳</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" id="set_AbandonCheck" lay-event="set_AbandonCheck"><i class="layui-icon layui-icon-form"></i>鍙嶅鏍�</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Close" id="Close"><i class="layui-icon layui-icon-radio"></i>鍏抽棴</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeClose" id="DeClose"><i class="layui-icon layui-icon-radio"></i>鍙嶅叧闂�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-view" id="btn-view"><i class="layui-icon layui-icon-tips"></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="btn-Delete" id="btn-Delete"><i class="layui-icon layui-icon-delete"></i>鍒犻櫎</button>
@@ -172,7 +186,8 @@
<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="set_HideColumn" id="set_HideColumn"><i class="layui-icon layui-icon-form"></i>鍒楄缃�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_HideButton" id="HideButton"><i class="layui-icon layui-icon-form"></i>鎸夐挳璁剧疆</button>
-
+ <button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_SaveScheme" id="set_SaveScheme"><i class="layui-icon layui-icon-template"></i>淇濆瓨鏂规</button>
+ <button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_ReadScheme" id="set_ReadScheme"><i class="layui-icon layui-icon-set"></i>璇诲彇鏂规</button>
</div>
</script>
<script type="text/html" id="xuhao">
@@ -224,11 +239,33 @@
var HBillType = "3819";
var page = 1;//鍒嗛〉鏁版嵁
var size = 50;
+ var HModName = "Sb_EquipDotCheckRuleList";
+
+ var HBillType = "3819";
+ var set_HideButton_ID = "toolbarDemo_ButtonSet";//闇�瑕佽缃殑鎸夐挳鐨勭埗绾ц妭鐐圭殑id
+ var ins;
var titleData = ["hmainid","鍗曟嵁ID", "鍗曟嵁绫诲瀷", "HMouldID","HEmpID","HBillType"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
//#endregion
//#region 杩涘叆椤甸潰鍗冲姞杞�
+
+ //#region 銆愯繃婊ゆ柟妗堛��
+
+ //杩囨护鏉′欢鐨刢lass绫�
+ var HClassTag = "ForFilteringSchemes";
+ //妯″潡鍚嶇О锛堜腑鏂囩増锛� 姣忎釜妯″潡椤甸潰閮介渶瑕佷慨鏀�
+ window.HModuleName = "鍣ㄥ叿淇濆吇璁板綍鍗�";
+ //鏄惁宸茬粡閫夋嫨浜嗚繃婊ゆ柟妗堬紙鍏ㄥ眬鍙橀噺锛�
+ window.HDefaultFilter = "";
+ //閫夋嫨鐨勮繃婊ゆ柟妗堝唴鐮侊紙鍏ㄥ眬鍙橀噺锛�
+ window.HInterID_Choose = 0;
+ //#endregion
+ //#region 銆愬姩鎬佽幏鍙栨ā鍧楀悕绉般��
+ var HModuleType = "3819";
+ //閫氳繃鍗曟嵁绫诲瀷锛屼粠鏁版嵁搴撳姩鎬佽幏鍙栧崟鎹ā鍧楀懡鍚�,寮曠敤js鏂囦欢 PageTitle.js
+ var HPageTitle = get_PageTitle(HModuleType) == "" ? document.title : get_PageTitle(HModuleType);
+ //#endregion
//#region 銆愬姩鎬佽幏鍙栨ā鍧楀悕绉般��
var HModuleType = "3819";
@@ -237,9 +274,7 @@
//#endregion
//鍒濆鍖栫晫闈�
- set_ClearBill();
- //鍒濆鍖栬〃鏍�
- DisPlay_HideColumn();
+ set_ClearBill();
//#endregion
//#region 瑙﹀彂浜嬩欢锛氬寘鎷琭orm.on(){}鏍煎紡鐨勬墍鏈夌偣鍑讳簨浠躲�侀�夋嫨浜嬩欢绛�
@@ -267,18 +302,31 @@
case 'get_Exit': Pub_Close(2);
break;
//鍒楄缃�
- case 'set_HideColumn':get_HideColumn();
+ case 'set_HideColumn': get_HideColumnNoPage(HModName, sessionStorage["HUserName"], option, get_FastQuery);
break;
//鎸夐挳璁剧疆
case 'set_HideButton':
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- get_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ get_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
break;
//瀹℃牳
case 'set_CheckBill': set_CheckBill(1);
break;
//鍙嶅鏍�
case 'set_AbandonCheck': set_CheckBill(2);
+ break;
+ //鍏抽棴鎸夐挳 锛�0:鍏抽棴銆�1:鍙嶅叧闂級
+ case 'btn-Close':
+ set_CloseBill(0);
+ break;
+ //鍙嶅叧闂寜閽�
+ case 'btn-DeClose':
+ set_CloseBill(1);
+ break;
+ //淇濆瓨鏂规
+ case 'set_SaveScheme': set_SaveScheme();
+ break;
+ //璇诲彇鏂规
+ case 'set_ReadScheme': set_ReadScheme();
break;
};
});
@@ -326,13 +374,44 @@
set_ClearQuery();
});
- //#endregion
+ //鏃ユ湡闂撮殧涓嬫媺鍒楄〃鐩戝惉
+ form.on('select(HInitTimeCycle)', function (data) {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+ });
+
+ //#endregion
//#region 褰撳墠椤甸潰鍔犺浇鎵�鏈夋柟娉�
// 鍒濆鍖栫晫闈�
function set_ClearBill() {
- $("#BenginHCreateDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
- $("#EndHCreateDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
+ //鍒濆鍖栨棩鏈熼棿闅斻�佸紑濮嬫棩鏈熴�佺粨鏉熸棩鏈�
+ setSelect_HInitTimeCycle();
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
//鍒濆鍖栬〃鏍�(涓昏〃)
set_InitGrid();
//鍒濆鍖栬〃鏍�(瀛愯〃)
@@ -342,7 +421,8 @@
//鏌ヨ
//get_Display(sWhere);
get_DisplayPage(sWhere);
-
+ //榛樿鏂规
+ get_DefaultModule()
}
//鍒濆鍖栬〃鏍�(涓�)
@@ -404,10 +484,6 @@
}
}
laypage.render(optionPage);
-
- //鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
}
//#region 鐐瑰嚮琛岄�変腑楂樹寒
@@ -597,6 +673,7 @@
data: { "sWhere": sWhere, "user": sessionStorage["HUserName"], "page": page, "size": size },
success: function (data1) {
option.limit = size;//鏀瑰彉琛ㄦ牸椤靛ぇ灏�
+ optionPage.count = data1.count;
if (data1.code == 1) {
optionPage.count = data1.count;//鏀瑰彉鍒楄〃鏁版嵁鎬绘暟
var data = [];
@@ -640,14 +717,16 @@
option.data = data1.data;
option.totalRow = true;
laypage.render(optionPage);
- //鍒锋柊琛ㄦ牸鏁版嵁
- DisPlay_HideColumn();
+ //鍒楄缃�
+ DisPlay_HideColumn(HModName, sessionStorage["HUserName"], option, titleData);
+
+ ////鍒锋柊琛ㄦ牸鏁版嵁
+ ins = table.render(option);
layer.close(ajaxLoad);
//鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ Display_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
if ($("#Comparator").val() == 0 && $("#ColContent").val() == "") {
ColFilter();
@@ -669,8 +748,8 @@
var HBillType = $("#HBillType").val();//鍗曟嵁绫诲瀷
var HBillNo = $("#HBillNo").val();//鍗曟嵁鍙�
var HCreateBy = $("#HCreateBy").val();//鍒跺崟浜�
- var BenginHCreateDate = $("#BenginHCreateDate").val();//寮�濮嬪埗鍗曟椂闂�
- var EndHCreateDate = $("#EndHCreateDate").val();//缁撴潫鍒跺崟鏃堕棿
+ var HBeginDate = $("#HBeginDate").val();//寮�濮嬪埗鍗曟椂闂�
+ var HEndDate = $("#HEndDate").val();//缁撴潫鍒跺崟鏃堕棿
var ColName = $("#ColName").val();//澶嶉�夋
var Comparator = $("#Comparator").val()
var ColContent = $("#ColContent").val();
@@ -740,7 +819,7 @@
com2 = "not like'%" + ColContent2 + "%'";
break;
default:
- com2 = "" + Comparator + "'" + ColContent + "'";
+ com2 = "" + Comparator2 + "'" + ColContent2 + "'";
break;
}
sWhere += " and " + ColName2 + " " + com2;
@@ -748,11 +827,11 @@
if (HBillNo) {
sWhere += " and HBillNo like '%" + HBillNo + "%'";
}
- if (BenginHCreateDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + BenginHCreateDate + "'";
+ if (HBeginDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + HBeginDate + "'";
}
- if (EndHCreateDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + EndHCreateDate + "'";
+ if (HEndDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + HEndDate + "'";
}
get_DisplayPage(sWhere);
//get_Display(sWhere);
@@ -761,11 +840,12 @@
//閲嶇疆杩囨护鏉′欢鏂规硶
function set_ClearQuery() {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
$("#HBillType").val("");//鍗曟嵁绫诲瀷
$("#HBillNo").val("");//鍗曟嵁鍙�
$("#HCreateBy").val("");//鍒跺崟浜�
- $("#BenginHCreateDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
- $("#EndHCreateDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
//$("#btnSearch").click();
$("#ColContent").val("");
$("#ColName").val("0");
@@ -933,129 +1013,64 @@
}
}
+ //#region 鍙嶅叧闂�/鍏抽棴鏁版嵁
+ function set_CloseBill(num) {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var InterID = data[0].hmainid.toString();
+ //閫昏緫瀹℃牳鏂规硶
+ $.ajax({
+ type: "GET",
+ url: GetWEBURL() + "/Sc_MouldMaintainBill/CloseSc_MouldMaintainBill", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ data: { "HInterID": InterID, "IsAudit": num, "CurUserName": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ $("#btnSearch").trigger('click');
+ });
+
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹叧闂紒');
+ }
+ }
+ //#endregion
+
//鍒锋柊
function get_Refresh() {
set_ClearQuery();
}
- //闅愯棌鍒楄缃�
- function get_HideColumn() {
- var colName = "";
- for (var i = 1; i < option.cols[0].length - 1; i++) {
- colName += option.cols[0][i]["title"] + ",";
+ //#region 鍒濆鏃ユ湡闂撮殧 涓嬫媺鍒楄〃
+ function setSelect_HInitTimeCycle() {
+ var valueList = [0, 1, 2, 3, 4, 5, 6, 29];
+ var titleList = ["浠婂ぉ", "杩戜袱澶�", "杩戜笁澶�", "杩戝洓澶�", "杩戜簲澶�", "杩戝叚澶�", "杩戜竷澶�", "杩�30澶�"];
+
+ var HInitTimeCycle_ArrayList = '<option value="-1" selected="selected" >浠绘剰闂撮殧</option>';
+ for (var i = 0; i < valueList.length; i++) {
+ HInitTimeCycle_ArrayList += '<option style="color:blue;" value="' + valueList[i] + '">' + titleList[i] + '</option>';
}
- 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.html?HModName=' + HModName + '&colName=' + colName, "yes"]
- , btn: ["纭畾", "鍙栨秷"]
- , btn1: function (index, laero) {
- //鍒锋柊琛ㄦ牸鏁版嵁
- DisPlay_HideColumn();
- //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹�
- layer.close(index);//鍏抽棴寮圭獥
- }
- })
+ $("#HInitTimeCycle").empty();
+ $("#HInitTimeCycle").append(HInitTimeCycle_ArrayList);
+ form.render('select');
+
+ $("#HInitTimeCycle").val("29");
}
-
- //鏄剧ず鍒楁暟鎹�
- function DisPlay_HideColumn() {
- $.ajax({
- url: GetWEBURL() + '/Xt_grdAlignment_WMES/grdAlignmentWMESList',
- type: "GET",
- data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
- success: function (data1) {
- if (data1.data.length != 0) {
-
-
- var dataCol = [];//鏁版嵁搴撴煡璇㈠嚭鐨勫垪鏁版嵁
- /*var titleData = ["鍗曟嵁ID", "鍗曟嵁绫诲瀷","HMouldID"];//涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�*/
-
- 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;
- }
- option.cols[0][i + 1]["fixed"] = "left";
- }
- }
- table.render(option);
-
- //鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
- } else {
- table.render(option);
- //鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
- }
- }, error: function () {
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- })
- }
+ //#endregion
//#region 鍒楁槑鏄剧ず涓嬫媺妗�
function ColFilter() {
@@ -1075,10 +1090,273 @@
}
//#endregion
+ //#region 銆愯繃婊ゆ柟妗堛��
+
+ //鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
+ function get_DefaultModule() {
+ $.ajax({
+ url: GetWEBURL() + '/Xt_FastICScheme/Chooselist',
+ type: "GET",
+ 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) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').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");
+ }
+ }
+ })
+ }
+
+ //#endregion
+
//浠ヤ笂鏄痩ayui妯″潡
});
+ //#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
</script>
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldMaintainPlanBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldMaintainPlanBillList.html"
index 140ec1e..13b3572 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldMaintainPlanBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldMaintainPlanBillList.html"
@@ -930,6 +930,7 @@
//鍒嗛〉鏌ヨ
function get_DisplayPage() {
var ajaxLoad = layer.load();
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
//杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
$.ajax({
url: GetWEBURL() + '/Sc_MouldMaintainPlanBill/page',
@@ -1097,6 +1098,32 @@
}
//#endregion
+ //#region 鑾峰彇鍙傛暟
+ function getUrlVars() {
+ var vars = [], hash;
+ var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
+ for (var i = 0; i < hashes.length; i++) {
+ hash = hashes[i].split('=');
+ vars.push(hash[0]);
+ vars[hash[0]] = hash[1];
+ }
+ return vars;
+ }
+ //#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and 鍏抽棴浜� = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
+
//#region 銆愯繃婊ゆ柟妗堛��
//鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldRepairCheckBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldRepairCheckBillList.html"
index 19dc6ec..5a5e318 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldRepairCheckBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/Sc_MouldRepairCheckBillList.html"
@@ -9,9 +9,10 @@
<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/HideButton.js"></script>
<script src="../../../layuiadmin/soulTable.slim.js"></script>
<script src="../../../layuiadmin/PageTitle.js"></script>
+ <script src="../../../layuiadmin/SetColumn.js"></script>
+ <script src="../../../layuiadmin/HideButton_New.js"></script>
<style type="text/css">
input.layui-input.layui-unselect {
@@ -31,46 +32,57 @@
<div class="layui-inline">
<span>鏇村</span>
</div>
- </div>
+ </div>
<div class="layui-inline">
<label class="layui-form-label">鍗曟嵁鍙�</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="HBillNo" id="HBillNo">
+ <input type="text" class="layui-input ForFilteringSchemes" name="HBillNo" id="HBillNo">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">鍒跺崟浜�</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="HCreateBy" id="HCreateBy">
+ <input type="text" class="layui-input ForFilteringSchemes" name="HCreateBy" id="HCreateBy">
+ </div>
+ </div>
+ <div class="layui-inline">
+ <label class="layui-form-label">鏃ユ湡闂撮殧</label>
+ <div class="layui-input-block">
+ <select name="HInitTimeCycle" id="HInitTimeCycle" class="ForFilteringSchemes" lay-filter="HInitTimeCycle" style="width:190px;">
+ </select>
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">寮�濮嬫椂闂�</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" name="BenginHCreateDate" id="BenginHCreateDate">
+ <input type="date" class="layui-input ForFilteringSchemes" name="HBeginDate" id="HBeginDate">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">缁撴潫鏃堕棿</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" name="EndHCreateDate" id="EndHCreateDate">
+ <input type="date" class="layui-input ForFilteringSchemes" name="HEndDate" id="HEndDate">
</div>
</div>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">
<i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
</button>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnReSearch" id="btnReSearch" style="padding:0 5px">閲嶇疆</button>
+ <!--鏄剧ず褰撳墠杩囨护鏂规-->
+ <div class="layui-inline" style="margin-left:5px;">
+ <div style="text-align:center;font-size:15px;font-weight:bold;color:#fc9393" id="HFilterScheme_Now"></div>
+ </div>
<div class="layui-colla-content">
<div class="layui-row">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName" id="ColName" lay-filter="ColName" style="width:190px;">
+ <select name="ColName" id="ColName" class="ForFilteringSchemes" lay-filter="ColName" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator" id="Comparator" lay-filter="Comparator" style="width:190px;">
+ <select name="Comparator" id="Comparator" class="ForFilteringSchemes" lay-filter="Comparator" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -85,19 +97,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent" id="ColContent">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent" id="ColContent">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName1" id="ColName1" lay-filter="ColName1" style="width:190px;">
+ <select name="ColName1" id="ColName1" class="ForFilteringSchemes" lay-filter="ColName1" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator1" id="Comparator1" lay-filter="Comparator1" style="width:190px;">
+ <select name="Comparator1" id="Comparator1" class="ForFilteringSchemes" lay-filter="Comparator1" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -112,19 +124,19 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent1" id="ColContent1">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent1" id="ColContent1">
</div>
</div>
<div class="layui-row" style="margin-top:5px">
<div class="layui-inline">
<label class="layui-form-label">杩囨护</label>
<div class="layui-input-block">
- <select name="ColName2" id="ColName2" lay-filter="ColName2" style="width:190px;">
+ <select name="ColName2" id="ColName2" class="ForFilteringSchemes" lay-filter="ColName2" style="width:190px;">
</select>
</div>
</div>
<div class="layui-inline">
- <select name="Comparator2" id="Comparator2" lay-filter="Comparator2" style="width:190px;">
+ <select name="Comparator2" id="Comparator2" class="ForFilteringSchemes" lay-filter="Comparator2" style="width:190px;">
<option value="0" selected="selected"></option>
<option value="=">=</option>
<option value=">=">>=</option>
@@ -139,7 +151,7 @@
</select>
</div>
<div class="layui-inline">
- <input type="text" class="layui-input" value="" name="ColContent2" id="ColContent2">
+ <input type="text" class="layui-input ForFilteringSchemes" value="" name="ColContent2" id="ColContent2">
</div>
</div>
</div>
@@ -148,18 +160,25 @@
<table class="" id="mainTable" lay-filter="mainTable"></table>
<div id="page" style="position: relative; bottom: 0;"></div>
<script type="text/html" id="toolbarDemo">
- <div class="layui-btn-container">
+ <div class="layui-btn-container" id="toolbarDemo_ButtonSet">
<!--<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-getCheckData"><i class="layui-icon layui-icon-tips"></i>棰勮</button>-->
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Add" id="btn-Add"><i class="layui-icon layui-icon-add-1"></i>鏂板</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-Edit" id="btn-Edit"><i class="layui-icon layui-icon-edit"></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="btn-reload" id="btn-reload"><i class="layui-icon layui-icon-refresh"></i>鍒锋柊</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_CheckBill" id="CheckBill"><i class="layui-icon layui-icon-form"></i>瀹℃牳</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_AbandonCheck" id="AbandonCheck"><i class="layui-icon layui-icon-form"></i>鍙嶅鏍�</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Close" id="Close"><i class="layui-icon layui-icon-radio"></i>鍏抽棴</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeClose" id="DeClose"><i class="layui-icon layui-icon-radio"></i>鍙嶅叧闂�</button>
<!--<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-confirm" id="btn_confirm"><i class="layui-icon layui-icon-ok-circle"></i>纭</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-back" id="btn_back"><i class="layui-icon layui-icon-close-fill"></i>椹冲洖</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-details" id="btn-details"><i class="layui-icon layui-icon-form"></i>璇︽儏</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-generate" id="btn-generate"><i class="layui-icon layui-icon-file"></i>鐢熸垚閫佽揣鍗�</button>-->
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="btn-exit" id="btn-exit"><i class="layui-icon layui-icon-return"></i>閫�鍑�</button>
+ <button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_HideColumn" id="set_HideColumn"><i class="layui-icon layui-icon-form"></i>鍒楄缃�</button>
<button type="button" class="layui-btn layui-btn-sm" style="display:none;" lay-event="set_HideButton" id="HideButton"><i class="layui-icon layui-icon-form"></i>鎸夐挳璁剧疆</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_SaveScheme" id="set_SaveScheme"><i class="layui-icon layui-icon-template"></i>淇濆瓨鏂规</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_ReadScheme" id="set_ReadScheme"><i class="layui-icon layui-icon-set"></i>璇诲彇鏂规</button>
</div>
</script>
</form>
@@ -197,11 +216,35 @@
var titleData = [];
var page = 1;//鍒嗛〉鏁版嵁
var size = 50;
+ var set_HideButton_ID = "toolbarDemo_ButtonSet";//闇�瑕佽缃殑鎸夐挳鐨勭埗绾ц妭鐐圭殑id
//#endregion
//#region 杩涘叆椤甸潰鍗冲姞杞�
- $("#BenginHCreateDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
- $("#EndHCreateDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
+
+ //鍒濆鍖栨棩鏈熼棿闅斻�佸紑濮嬫棩鏈熴�佺粨鏉熸棩鏈�
+ setSelect_HInitTimeCycle();
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
+
+ //#region 銆愯繃婊ゆ柟妗堛��
+ //杩囨护鏉′欢鐨刢lass绫�
+ var HClassTag = "ForFilteringSchemes";
+ //妯″潡鍚嶇О锛堜腑鏂囩増锛� 姣忎釜妯″潡椤甸潰閮介渶瑕佷慨鏀�
+ window.HModuleName = "鍣ㄥ叿缁翠慨楠屾敹鍗�";
+ //鏄惁宸茬粡閫夋嫨浜嗚繃婊ゆ柟妗堬紙鍏ㄥ眬鍙橀噺锛�
+ window.HDefaultFilter = "";
+ //閫夋嫨鐨勮繃婊ゆ柟妗堝唴鐮侊紙鍏ㄥ眬鍙橀噺锛�
+ window.HInterID_Choose = 0;
+ //#endregion
//#region 銆愬姩鎬佽幏鍙栨ā鍧楀悕绉般��
var HModuleType = "3817";
@@ -214,6 +257,8 @@
//鍔犺浇鏁版嵁鍒扮綉鏍�
//get_Display(sWhere);
get_FastQuery();
+ //鏌ヨ褰撳墠鐧诲綍鐢ㄦ埛鏈夋病鏈夊湪褰撳墠妯″潡璁剧疆榛樿杩囨护鏂规
+ get_DefaultModule();
//#endregion
@@ -232,13 +277,19 @@
case 'btn-Delete':
set_DeleteBill();
break;
- //瀹℃牳鎸夐挳
- case 'btn-Audit':
- set_CheckBill();
+ //瀹℃牳
+ case 'set_CheckBill': set_CheckBill(1);
break;
- //鍙嶅鏍告寜閽�
- case 'btn-DeAudit':
- set_AbandonCheck();
+ //鍙嶅鏍�
+ case 'set_AbandonCheck': set_CheckBill(2);
+ break;
+ //鍏抽棴鎸夐挳 锛�0:鍏抽棴銆�1:鍙嶅叧闂級
+ case 'btn-Close':
+ set_CloseBill(0);
+ break;
+ //鍙嶅叧闂寜閽�
+ case 'btn-DeClose':
+ set_CloseBill(1);
break;
//棰勮鎸夐挳
case 'btn-Print':
@@ -252,10 +303,18 @@
case 'btn-exit':
parent.layui.admin.events.closeThisTabs();
break;
+ //鍒楄缃�
+ case 'set_HideColumn': get_HideColumnNoPage(HModName, sessionStorage["HUserName"], option, get_FastQuery);
+ break;
//鎸夐挳璁剧疆
case 'set_HideButton':
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- get_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ get_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
+ break;
+ //淇濆瓨鏂规
+ case 'set_SaveScheme': set_SaveScheme();
+ break;
+ //璇诲彇鏂规
+ case 'set_ReadScheme': set_ReadScheme();
break;
};
});
@@ -273,11 +332,30 @@
});
//#endregion
+ //鏃ユ湡闂撮殧涓嬫媺鍒楄〃鐩戝惉
+ form.on('select(HInitTimeCycle)', function (data) {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
+ //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
+ if (HInitTimeCycle != -1) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+ });
+
//鍒濆鍖栬〃鏍�
function set_InitGrid() {
- //$("#BenginHCreateDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
- //$("#EndHCreateDate").val(Format(new Date(), "yyyy-MM-dd"));
+ //$("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
+ //$("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
option = {
elem: '#mainTable'
, toolbar: '#toolbarDemo'
@@ -370,6 +448,7 @@
data: { "sWhere": sWhere, "user": sessionStorage["HUserName"], "page": page, "size": size },
success: function (data1) {
option.limit = size;//鏀瑰彉琛ㄦ牸椤靛ぇ灏�
+ optionPage.count = data1.count;
if (data1.code == 1) {
optionPage.count = data1.count;//鏀瑰彉鍒楄〃鏁版嵁鎬绘暟
var data = [];
@@ -413,11 +492,15 @@
option.data = data1.data;
option.totalRow = true;
laypage.render(optionPage);
- table.render(option);
+ //table.render(option);
+ //鍒楄缃�
+ DisPlay_HideColumn(HModName, sessionStorage["HUserName"], option, titleData);
+
+ ////鍒锋柊琛ㄦ牸鏁版嵁
+ ins = table.render(option);
//鍒锋柊鎸夐挳鏄剧ず
- var btns = document.getElementsByTagName("button"); //鑾峰彇鏈〉鎵�鏈夋寜閽璞�
- Display_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]);
+ Display_HideButton(set_HideButton_ID, HBillType, HModName, sessionStorage["HUserName"]);
if ($("#Comparator").val() == 0 && $("#ColContent").val() == "") {
ColFilter();
@@ -557,6 +640,74 @@
}
}
+ //瀹℃牳/鍙嶅鏍�
+ function set_CheckBill(num) {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+
+ if (data.length == 1) {
+ layer.confirm("纭瑕佸鏍稿悧?", function (index) {
+ var wait = layer.load();
+ var HInterID = data[0].hmainid;
+ $.ajax({
+ url: GetWEBURL() + '/Sc_MouldRepairCheckBill/CheckSc_MouldRepairCheckBill',
+ type: "GET",
+ data: { "HInterID": HInterID, "Type": num, "user": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ get_FastQuery();
+ layer.msg(result.Message, { icon: 1 });
+ layer.close(wait);
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ layer.close(wait);
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ layer.close(wait);
+ }
+ });
+ })
+ } else {
+ layer.msg("璇烽�夋嫨涓�鏉℃暟鎹�!");
+ }
+ }
+
+ //#region 鍙嶅叧闂�/鍏抽棴鏁版嵁
+ function set_CloseBill(num) {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var InterID = data[0].hmainid.toString();
+ //閫昏緫瀹℃牳鏂规硶
+ $.ajax({
+ type: "GET",
+ url: GetWEBURL() + "/Sc_MouldRepairCheckBill/CloseSc_MouldRepairCheckBill", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ data: { "HInterID": InterID, "IsAudit": num, "CurUserName": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ $("#btnSearch").trigger('click');
+ });
+
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹叧闂紒');
+ }
+ }
+ //#endregion
//#region 鐐瑰嚮琛岄�変腑楂樹寒
table.on('row(mainTable)', function (obj) {
@@ -583,8 +734,8 @@
function get_FastQuery() {
var HBillNo = $("#HBillNo").val();//鍗曟嵁鍙�
var HCreateBy = $("#HCreateBy").val();//鍒跺崟浜�
- var BenginHCreateDate = $("#BenginHCreateDate").val();//寮�濮嬫棩鏈�
- var EndHCreateDate = $("#EndHCreateDate").val();//缁撴潫鏃ユ湡
+ var HBeginDate = $("#HBeginDate").val();//寮�濮嬫棩鏈�
+ var HEndDate = $("#HEndDate").val();//缁撴潫鏃ユ湡
var ColName = $("#ColName").val();//澶嶉�夋
var Comparator = $("#Comparator").val()
var ColContent = $("#ColContent").val();
@@ -654,7 +805,7 @@
com2 = "not like'%" + ColContent2 + "%'";
break;
default:
- com2 = "" + Comparator + "'" + ColContent + "'";
+ com2 = "" + Comparator2 + "'" + ColContent2 + "'";
break;
}
sWhere += " and " + ColName2 + " " + com2;
@@ -665,11 +816,11 @@
if (HCreateBy) {
sWhere += " and 鍒跺崟浜� like '%" + HCreateBy + "%'";
}
- if (BenginHCreateDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + BenginHCreateDate + "'";
+ if (HBeginDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + HBeginDate + "'";
}
- if (EndHCreateDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + EndHCreateDate + "'";
+ if (HEndDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + HEndDate + "'";
}
//get_Display(sWhere);
@@ -679,10 +830,11 @@
//閲嶇疆
function set_ClearQuery() {
+ var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
$("#HBillNo").val("");//鍗曟嵁鍙�
$("#HCreateBy").val("");//鍒跺崟浜�
- $("#BenginHCreateDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
- $("#EndHCreateDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));//寮�濮嬫棩鏈�
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));//缁撴潫鏃ユ湡
$("#ColContent").val("");
$("#ColName").val("0");
$("#Comparator").val("0");
@@ -716,10 +868,292 @@
form.render('select');
}
//#endregion
+
+ //#region 鍒濆鏃ユ湡闂撮殧 涓嬫媺鍒楄〃
+ function setSelect_HInitTimeCycle() {
+ var valueList = [0, 1, 2, 3, 4, 5, 6, 29];
+ var titleList = ["浠婂ぉ", "杩戜袱澶�", "杩戜笁澶�", "杩戝洓澶�", "杩戜簲澶�", "杩戝叚澶�", "杩戜竷澶�", "杩�30澶�"];
+
+ var HInitTimeCycle_ArrayList = '<option value="-1" selected="selected" >浠绘剰闂撮殧</option>';
+ for (var i = 0; i < valueList.length; i++) {
+ HInitTimeCycle_ArrayList += '<option style="color:blue;" value="' + valueList[i] + '">' + titleList[i] + '</option>';
+ }
+
+ $("#HInitTimeCycle").empty();
+ $("#HInitTimeCycle").append(HInitTimeCycle_ArrayList);
+ form.render('select');
+
+ $("#HInitTimeCycle").val("29");
+ }
+ //#endregion
+
+ //#region 銆愯繃婊ゆ柟妗堛��
+
+ //鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
+ function get_DefaultModule() {
+ $.ajax({
+ url: GetWEBURL() + '/Xt_FastICScheme/Chooselist',
+ type: "GET",
+ 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].HInterID;
+ //杩囨护鏂规鍐呯爜
+ HInterID = data[0].HInterID
+ //杩囨护鏂规鍚嶇О
+ 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) {
+ $('#HBeginDate').prop('disabled', true);
+ $('#HEndDate').prop('disabled', true);
+
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * HInitTimeCycle), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery();
+ } else {
+ $('#HBeginDate').prop('disabled', false);
+ $('#HEndDate').prop('disabled', false);
+ }
+
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery(2)
+ form.render("select");
+ } else {
+ //褰撳墠鐢ㄦ埛娌℃湁璁剧疆榛樿鐨勮繃婊ゆ柟妗�
+ //闅愯棌鏄剧ず杩囨护鏂规鐨勬爣绛句俊鎭�
+ document.getElementById("HFilterScheme_Now").style.display = "none";
+ //鎵ц鏌ヨ鏂规硶
+ get_FastQuery(1)
+ 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");
+ }
+ }
+ })
+ }
+
+ //#endregion
+
//浠ヤ笂鏄痩ayui妯″潡
});
+ //#region 銆愯繃婊ゆ柟妗堣繑鍥炴暟鎹��
+ function HFilterScheme(obj) //杩斿洖杩囨护鏂规
+ {
+ var HInterID = obj[0].HInterID;
+ HInterID_Choose = obj[0].HInterID;
+ $.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].HInterID
+ //鏍规嵁閫夋嫨鐨勮繃婊ゆ柟妗堝洖濉暟鎹埌鍒楄〃杩囨护鏉′欢
+ 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
</script>
diff --git "a/WebTM/views/\350\256\276\345\244\207\347\256\241\347\220\206/\350\256\276\345\244\207\346\241\243\346\241\210/Gy_EquipFileMainList.html" "b/WebTM/views/\350\256\276\345\244\207\347\256\241\347\220\206/\350\256\276\345\244\207\346\241\243\346\241\210/Gy_EquipFileMainList.html"
index 6dfec9c..6ca8b63 100644
--- "a/WebTM/views/\350\256\276\345\244\207\347\256\241\347\220\206/\350\256\276\345\244\207\346\241\243\346\241\210/Gy_EquipFileMainList.html"
+++ "b/WebTM/views/\350\256\276\345\244\207\347\256\241\347\220\206/\350\256\276\345\244\207\346\241\243\346\241\210/Gy_EquipFileMainList.html"
@@ -443,7 +443,8 @@
//鏌ヨ
function get_Display(sWhere) {
- var index = layer.load(0, { shade: false });
+ var index = layer.load(0, { shade: false });
+ sWhere += addSWhereByOpenType();//娣诲姞鍗曟嵁妯″潡閫夋嫨鍩虹璧勬枡鏃剁殑杩囨护鏉′欢锛屽凡瀹℃牳鏈叧闂�
//杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
$.ajax({
url: GetWEBURL() + '/Gy_EquipFileMain/GetList',
@@ -1032,6 +1033,33 @@
$("#HUSEORGID").val(sessionStorage["Organization"]);
$("#btnSearch").click();
}
+
+ //#region 鑾峰彇鍙傛暟
+ function getUrlVars() {
+ var vars = [], hash;
+ var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
+ for (var i = 0; i < hashes.length; i++) {
+ hash = hashes[i].split('=');
+ vars.push(hash[0]);
+ vars[hash[0]] = hash[1];
+ }
+ return vars;
+ }
+ //#endregion
+
+ //#region 鍒ゆ柇鏄洿鎺ユ墦寮�椤甸潰杩樻槸鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑锛屽苟鏄剧ず鐩稿簲鏁版嵁
+ function addSWhereByOpenType() {
+ //鑾峰彇鍙傛暟
+ var params = getUrlVars();
+ var openType = params[params[0]]; //浠庡弬鏁颁腑鑾峰彇 鎵撳紑鏂瑰紡 1鐩存帴鎵撳紑 2鍏跺畠椤甸潰閫氳繃閫夋嫨鎸夐挳鎵撳紑
+ var addSWhere = "";
+ if (typeof (openType) != "undefined") {
+ addSWhere = " and 鍏抽棴浜� = '' and 瀹℃牳浜� != ''";
+ }
+ return addSWhere;
+ }
+ //#endregion
+
//#region 銆愯繃婊ゆ柟妗堛��
//鑾峰彇褰撳墠鐢ㄦ埛鐨勯粯璁よ繃婊ゆ柟妗�
--
Gitblit v1.9.1