From 6af1928d442ad9d422438ba4827876d1a3e82c43 Mon Sep 17 00:00:00 2001 From: yusijie <ysj@hz-kingdee.com> Date: 星期五, 19 四月 2024 13:31:35 +0800 Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-LayUI --- WebTM/views/销售管理/发货通知单/Add_Edit_Xs_SeOutStockBillList.html | 132 +++++++++++++- WebTM/views/销售管理/退货通知单/Xs_SeOutStockBackBill.html | 121 +++++++++++++ WebTM/views/领料发货/销售出库/Kf_SellOutBill.html | 240 +++++++++++++++++++++++--- 3 files changed, 444 insertions(+), 49 deletions(-) diff --git "a/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\345\217\221\350\264\247\351\200\232\347\237\245\345\215\225/Add_Edit_Xs_SeOutStockBillList.html" "b/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\345\217\221\350\264\247\351\200\232\347\237\245\345\215\225/Add_Edit_Xs_SeOutStockBillList.html" index c13ef05..06c0b86 100644 --- "a/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\345\217\221\350\264\247\351\200\232\347\237\245\345\215\225/Add_Edit_Xs_SeOutStockBillList.html" +++ "b/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\345\217\221\350\264\247\351\200\232\347\237\245\345\215\225/Add_Edit_Xs_SeOutStockBillList.html" @@ -237,11 +237,28 @@ </div> </div> <div class="layui-row"> - <div class="layui-inline"> + <div class="layui-col-xs4 layui-inline"> <label class="layui-form-label">澶囨敞</label> <div class="layui-input-block"> <input class="layui-input" name="HRemark" id="HRemark" autocomplete="off"> </div> + </div> + <div class="layui-col-xs4 layui-inline"> + <label class="layui-form-label">椤圭洰浠g爜</label> + <div class="layui-input-inline"> + <input type="text" class="layui-input" lay-verify="HProjectNumber" name="HProjectNumber" id="HProjectNumber" value="" style="background-color: #efefef4d;float: left; width: 150px;" readonly> + <input type="hidden" name="HProjectID" id="HProjectID" lay-verify="HProjectID" value="0"> + <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearchHProNumber" id="btnSearchHProNumber" style="width:40px;"> + <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> + </button> + </div> + </div> + <div class="layui-col-xs4 layui-inline"> + <label class="layui-form-label">椤圭洰鍚嶇О</label> + <div class="layui-input-inline"> + <input class="layui-input" name="HProjectName" id="HProjectName" autocomplete="off" readonly> + </div> + </div> </div> </div> @@ -368,6 +385,7 @@ var shijian = year + "-" + month + "-" + day; var allVal; + //#endregion @@ -375,7 +393,7 @@ //鍒ゆ柇鏄惁鐧诲綍 鏈櫥褰曞垯璺冲埌鐧诲綍椤� get_LoginIs(); - + window.OptionData = {}; //#region 銆愬姩鎬佽幏鍙栨ā鍧楀悕绉般�� var HModuleType = "1402"; //閫氳繃鍗曟嵁绫诲瀷锛屼粠鏁版嵁搴撳姩鎬佽幏鍙栧崟鎹ā鍧楀懡鍚�,寮曠敤js鏂囦欢 PageTitle.js @@ -508,7 +526,10 @@ form.on('submit(HManagerList)', function () { get_checkManager(); }); - + //椤圭洰浠g爜 + form.on('submit(btnSearchHProNumber)', function () { + get_checkSearchHProNumber(); + }); //淇濆瓨鎸夐挳 form.on('submit(Saver)', function (data) { @@ -680,13 +701,16 @@ ,"HWHID": "0" , "鍙戣揣浠撳簱": "" , "HQty": "0", "HPrice": "0", "HMoney": "0", "HRemark": "" - + , "HSourceBillNo": checkStatus.data[i].鍗曟嵁鍙� , "HSourceBillType": checkStatus.data[i].HBillType , "HSourceInterID": checkStatus.data[i].hmainid , "HSourceEntryID": checkStatus.data[i].hsubid }) } + $("#HProjectID").val(checkStatus.data[0].HProjectID); + $("#HProjectNumber").val(checkStatus.data[0].椤圭洰缂栫爜); + $("#HProjectName").val(checkStatus.data[0].椤圭洰鍚嶇О); table.render(option); layer.close(index);//鍏抽棴寮圭獥 } @@ -788,6 +812,10 @@ //, "HConveyTypeID": data.杩愯緭鏂瑰紡 //, "HConveyMoney": data.杩愯垂 //, "HDFflag": data.鏄惁鍨粯 + , "HProjectID": data.HProjectID + , "HProjectNumber": data.椤圭洰缂栫爜 + , "HProjectName": data.椤圭洰鍚嶇О + , "Box2": "" , "HRemark": data.琛ㄥご澶囨敞 , "HMaker": data.鍒跺崟浜� @@ -994,7 +1022,7 @@ , shift: 2 //寮瑰嚭鍔ㄧ敾 , area: ["90%", "90%"] //绐椾綋澶у皬 , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀� - , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Warehouse.html', 'yes'] + , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Warehouse.html?type=HWHSub', 'yes'] , btn: ["纭畾", "鍙栨秷"] , btn1: function (index, laero) { //鎸夐挳涓� 鐨勫洖璋� @@ -1006,10 +1034,17 @@ } //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹� obj.update({ + + "HWHID": checkStatus.data[0].HItemID, "鍙戣揣浠撳簱": checkStatus.data[0].浠撳簱鍚嶇О - , "HWHID": checkStatus.data[0].HItemID }) layer.close(index);//鍏抽棴寮圭獥 + } + , end: function () { + obj.update({ + "HWHID": OptionData.HItemID + , "鍙戣揣浠撳簱": OptionData.浠撳簱鍚嶇О + }) } }) } @@ -1089,7 +1124,7 @@ , area: ['90%', '90%']//澶у皬 , title: '浠撳簱鍒楄〃'//鏍囬 , shift: 2//寮瑰嚭鍔ㄧ敾 - , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Warehouse.html', 'yes'] + , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Warehouse.html?Type=HWH', 'yes'] , btn: ['纭畾', '鍙栨秷'] , btn1: function (index, layero) {//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟 var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮规椤甸潰 @@ -1099,6 +1134,16 @@ } $("#HWHName").val(checkStatus.data[0].浠撳簱鍚嶇О); $("#HWHID").val(checkStatus.data[0].HItemID); + + if (option.data.length > 0) { + for (var i = 0; i < option.data.length; i++) { + if (option.data[i]["HWHID"] == 0) { + option.data[i]["HWHID"] = checkStatus.data[0].HItemID; + option.data[i]["鍙戣揣浠撳簱"] = checkStatus.data[0].浠撳簱鍚嶇О; + } + } + } + table.render(option); layer.close(index); //瀹冭幏鍙栫殑濮嬬粓鏄渶鏂板脊鍑虹殑鏌愪釜灞傦紝鍊兼槸鐢眑ayer鍐呴儴鍔ㄦ�侀�掑璁$畻鐨� } , btn2: function (index, layero) { } @@ -1173,6 +1218,43 @@ }) } + //椤圭洰浠g爜 + function get_checkSearchHProNumber() { + var HOrgID = $("#HOrgID").val(); + //鎵撳紑宸ョ▼椤圭洰灏忕獥浣� + layer.open({ + type: 2 + , skin: "layui-layer-rim" //鍔犱笂杈规 + , title: "宸ョ▼椤圭洰鍒楄〃" //鏍囬 + , closeBtn: 1 //绐椾綋鍙充笂瑙掑叧闂� 鐨� 鏍峰紡 + , shift: 2 //寮瑰嚭鍔ㄧ敾 + , area: ["90%", "90%"] //绐椾綋澶у皬 + , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀� + , content: ["../../椤圭洰绠$悊/宸ョ▼椤圭洰/PM_ProjectBillList.html?openType=2&HOrgID=" + HOrgID, "yes"] + , btn: ["纭畾", "鍙栨秷"] + , btn1: function (index, laero) { + //鎸夐挳涓� 鐨勫洖璋� + var iframeWindow = window["layui-layer-iframe" + index];//鑾峰彇寮规椤甸潰 + var checkStatus = iframeWindow.layui.table.checkStatus("mainTable");//鑾峰彇閫変腑鐨勬暟鎹� + + if (checkStatus.data.length != 1) { + return layer.msg("璇烽�夋嫨涓�鏉℃暟鎹�"); + } + + //鍒ゆ柇椤圭洰鏄惁鍏抽棴 + if (checkStatus.data[0].鍏抽棴浜� == null || checkStatus.data[0].鍏抽棴浜� == "") { + $("#HProjectID").val(checkStatus.data[0].HInterID); + $("#HProjectNumber").val(checkStatus.data[0].椤圭洰浠g爜);//宸ョ▼椤圭洰浠g爜 + $("#HProjectName").val(checkStatus.data[0].椤圭洰鍚嶇О);//宸ョ▼椤圭洰浠g爜 + } else { + layer.msg("璇ラ」鐩凡鍏抽棴锛屼笉鍙�夋嫨锛�"); + } + layer.close(index);//鍏抽棴寮圭獥 + } + , btn2: function (index, layero) { } + , end: function () { } + }) + } //#region 鑾峰彇婧愬崟绫诲瀷 function HSourceBillType() { var HName = '鍙戣揣閫氱煡鍗�'; @@ -1236,11 +1318,37 @@ // $("#HDeptID").val(obj[0].HItemID); //} - //function GetHWHValue(obj) //杩斿洖浠撳簱 - //{ - // $("#HWHName").val(obj[0].HName); - // $("#HWHID").val(obj[0].HItemID); - //} + //椤圭洰浠g爜 + function GetProjectBillValue(obj) { + if (obj[0].鍏抽棴浜� == null || obj[0].鍏抽棴浜� == "") { + $("#HProjectID").val(obj[0].HInterID); + $("#HProjectNumber").val(obj[0].椤圭洰浠g爜);//宸ョ▼椤圭洰浠g爜 + $("#HProjectName").val(obj[0].椤圭洰鍚嶇О);//宸ョ▼椤圭洰浠g爜 + + } else { + layer.msg("璇ラ」鐩凡鍏抽棴锛屼笉鍙�夋嫨锛�"); + } + } + + //鍙屽嚮杩斿洖浠撳簱 + function GetHWHSubValue(data) { + OptionData = data[0] + } + + function GetHWHValue(obj) //杩斿洖浠撳簱 + { + $("#HWHName").val(obj[0].浠撳簱鍚嶇О); + $("#HWHID").val(obj[0].HItemID); + if (option.data.length > 0) { + for (var i = 0; i < option.data.length; i++) { + if (option.data[i]["HWHID"] == 0 || option.data[i]["鍙戣揣浠撳簱"] == undefined) { + option.data[i]["HWHID"] = obj[0].HItemID; + option.data[i]["鍙戣揣浠撳簱"] = obj[0].浠撳簱鍚嶇О; + } + } + } + layui.table.render(option); + } </script> </body> </html> \ No newline at end of file diff --git "a/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\351\200\200\350\264\247\351\200\232\347\237\245\345\215\225/Xs_SeOutStockBackBill.html" "b/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\351\200\200\350\264\247\351\200\232\347\237\245\345\215\225/Xs_SeOutStockBackBill.html" index b5b29ae..e83a6de 100644 --- "a/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\351\200\200\350\264\247\351\200\232\347\237\245\345\215\225/Xs_SeOutStockBackBill.html" +++ "b/WebTM/views/\351\224\200\345\224\256\347\256\241\347\220\206/\351\200\200\350\264\247\351\200\232\347\237\245\345\215\225/Xs_SeOutStockBackBill.html" @@ -194,6 +194,23 @@ </button> </div> </div> + <div class="layui-col-xs4 layui-inline"> + <label class="layui-form-label">椤圭洰浠g爜</label> + <div class="layui-input-inline"> + <input type="text" class="layui-input" lay-verify="HProjectNumber" name="HProjectNumber" id="HProjectNumber" value="" style="background-color: #efefef4d;float: left; width: 150px;" readonly> + <input type="hidden" name="HProjectID" id="HProjectID" lay-verify="HProjectID" value="0"> + <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearchHProNumber" id="btnSearchHProNumber" style="width:40px;"> + <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> + </button> + </div> + </div> + <div class="layui-col-xs4 layui-inline"> + <label class="layui-form-label">椤圭洰鍚嶇О</label> + <div class="layui-input-inline"> + <input class="layui-input" name="HProjectName" id="HProjectName" autocomplete="off" readonly> + </div> + + </div> <div class="layui-col-xs4 layui-inline" style="display:none"> <label class="layui-form-label">鍐呴儴鍗曟嵁鍙�</label> <div class="layui-input-inline"> @@ -482,6 +499,10 @@ form.on('submit(HConveyCompList)', function () { get_checkConveyComp(); }); + //椤圭洰浠g爜 + form.on('submit(btnSearchHProNumber)', function () { + get_checkSearchHProNumber(); + }); //淇濆瓨鎸夐挳 @@ -600,6 +621,9 @@ , "HSourceEntryID": checkStatus.data[i].hsubid }) } + $("#HProjectID").val(checkStatus.data[0].HProjectID); + $("#HProjectNumber").val(checkStatus.data[0].椤圭洰缂栫爜); + $("#HProjectName").val(checkStatus.data[0].椤圭洰鍚嶇О); table.render(option); layer.close(index);//鍏抽棴寮圭獥 } @@ -696,6 +720,9 @@ , "HCusID": data.HCusID , "HCusName": data.瀹㈡埛 , "HAddress": data.浜よ揣鍦扮偣 + , "HProjectID": data.HProjectID + , "HProjectNumber": data.椤圭洰缂栫爜 + , "HProjectName": data.椤圭洰鍚嶇О , "HRemark": data.琛ㄥご澶囨敞 , "HExplanation": data.鎽樿 , "HSourceBillType": data.婧愬崟绫诲瀷 @@ -884,7 +911,7 @@ , shift: 2 //寮瑰嚭鍔ㄧ敾 , area: ["90%", "90%"] //绐椾綋澶у皬 , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀� - , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Warehouse.html', 'yes'] + , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Warehouse.html?type=HWHSub', 'yes'] , btn: ["纭畾", "鍙栨秷"] , btn1: function (index, laero) { //鎸夐挳涓� 鐨勫洖璋� @@ -896,10 +923,17 @@ } //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹� obj.update({ + + "HWHID": checkStatus.data[0].HItemID, "鏀惰揣浠撳簱": checkStatus.data[0].浠撳簱鍚嶇О - , "HWHID": checkStatus.data[0].HItemID }) layer.close(index);//鍏抽棴寮圭獥 + } + , end: function () { + obj.update({ + "HWHID": OptionData.HItemID + , "鏀惰揣浠撳簱": OptionData.浠撳簱鍚嶇О + }) } }) } @@ -1009,7 +1043,7 @@ , area: ['90%', '90%']//澶у皬 , title: '浠撳簱鍒楄〃'//鏍囬 , shift: 2//寮瑰嚭鍔ㄧ敾 - , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Warehouse.html', 'yes'] + , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Warehouse.html?Type=HWH', 'yes'] , btn: ['纭畾', '鍙栨秷'] , btn1: function (index, layero) {//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟 var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮规椤甸潰 @@ -1019,6 +1053,16 @@ } $("#HWHName").val(checkStatus.data[0].浠撳簱鍚嶇О); $("#HWHID").val(checkStatus.data[0].HItemID); + + if (option.data.length > 0) { + for (var i = 0; i < option.data.length; i++) { + if (option.data[i]["HWHID"] == 0) { + option.data[i]["HWHID"] = checkStatus.data[0].HItemID; + option.data[i]["鍙戣揣浠撳簱"] = checkStatus.data[0].浠撳簱鍚嶇О; + } + } + } + table.render(option); layer.close(index); //瀹冭幏鍙栫殑濮嬬粓鏄渶鏂板脊鍑虹殑鏌愪釜灞傦紝鍊兼槸鐢眑ayer鍐呴儴鍔ㄦ�侀�掑璁$畻鐨� } , btn2: function (index, layero) { } @@ -1161,6 +1205,44 @@ }) } + //椤圭洰浠g爜 + function get_checkSearchHProNumber() { + var HOrgID = $("#HOrgID").val(); + //鎵撳紑宸ョ▼椤圭洰灏忕獥浣� + layer.open({ + type: 2 + , skin: "layui-layer-rim" //鍔犱笂杈规 + , title: "宸ョ▼椤圭洰鍒楄〃" //鏍囬 + , closeBtn: 1 //绐椾綋鍙充笂瑙掑叧闂� 鐨� 鏍峰紡 + , shift: 2 //寮瑰嚭鍔ㄧ敾 + , area: ["90%", "90%"] //绐椾綋澶у皬 + , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀� + , content: ["../../椤圭洰绠$悊/宸ョ▼椤圭洰/PM_ProjectBillList.html?openType=2&HOrgID=" + HOrgID, "yes"] + , btn: ["纭畾", "鍙栨秷"] + , btn1: function (index, laero) { + //鎸夐挳涓� 鐨勫洖璋� + var iframeWindow = window["layui-layer-iframe" + index];//鑾峰彇寮规椤甸潰 + var checkStatus = iframeWindow.layui.table.checkStatus("mainTable");//鑾峰彇閫変腑鐨勬暟鎹� + + if (checkStatus.data.length != 1) { + return layer.msg("璇烽�夋嫨涓�鏉℃暟鎹�"); + } + + //鍒ゆ柇椤圭洰鏄惁鍏抽棴 + if (checkStatus.data[0].鍏抽棴浜� == null || checkStatus.data[0].鍏抽棴浜� == "") { + $("#HProjectID").val(checkStatus.data[0].HInterID); + $("#HProjectNumber").val(checkStatus.data[0].椤圭洰浠g爜);//宸ョ▼椤圭洰浠g爜 + $("#HProjectName").val(checkStatus.data[0].椤圭洰鍚嶇О);//宸ョ▼椤圭洰浠g爜 + } else { + layer.msg("璇ラ」鐩凡鍏抽棴锛屼笉鍙�夋嫨锛�"); + } + layer.close(index);//鍏抽棴寮圭獥 + } + , btn2: function (index, layero) { } + , end: function () { } + }) + } + //#region 淇濆瓨鍚庢祻瑙堟柟娉� function ReRoadBillMain() { location.replace('Add_Edit_Xs_SeOutStockBillList.html?OperationType=4&linterid=' + linterid + '&HSouceBillType='); @@ -1192,7 +1274,6 @@ }) } //#endregion - //#endregion @@ -1261,6 +1342,38 @@ $("#HConveyCompID").val(obj[0].HItemID); } + //椤圭洰浠g爜 + function GetProjectBillValue(obj) { + if (obj[0].鍏抽棴浜� == null || obj[0].鍏抽棴浜� == "") { + $("#HProjectID").val(obj[0].HInterID); + $("#HProjectNumber").val(obj[0].椤圭洰浠g爜);//宸ョ▼椤圭洰浠g爜 + $("#HProjectName").val(obj[0].椤圭洰鍚嶇О);//宸ョ▼椤圭洰浠g爜 + + } else { + layer.msg("璇ラ」鐩凡鍏抽棴锛屼笉鍙�夋嫨锛�"); + } + } + + //鍙屽嚮杩斿洖浠撳簱 + function GetHWHSubValue(data) { + OptionData = data[0] + } + + function GetHWHValue(obj) //杩斿洖浠撳簱 + { + $("#HWHName").val(obj[0].浠撳簱鍚嶇О); + $("#HWHID").val(obj[0].HItemID); + if (option.data.length > 0) { + for (var i = 0; i < option.data.length; i++) { + if (option.data[i]["HWHID"] == 0 || option.data[i]["鏀惰揣浠撳簱"] == undefined) { + option.data[i]["HWHID"] = obj[0].HItemID; + option.data[i]["鏀惰揣浠撳簱"] = obj[0].浠撳簱鍚嶇О; + } + } + } + layui.table.render(option); + } + </script> </body> </html> \ No newline at end of file diff --git "a/WebTM/views/\351\242\206\346\226\231\345\217\221\350\264\247/\351\224\200\345\224\256\345\207\272\345\272\223/Kf_SellOutBill.html" "b/WebTM/views/\351\242\206\346\226\231\345\217\221\350\264\247/\351\224\200\345\224\256\345\207\272\345\272\223/Kf_SellOutBill.html" index f6a87a7..ba775e7 100644 --- "a/WebTM/views/\351\242\206\346\226\231\345\217\221\350\264\247/\351\224\200\345\224\256\345\207\272\345\272\223/Kf_SellOutBill.html" +++ "b/WebTM/views/\351\242\206\346\226\231\345\217\221\350\264\247/\351\224\200\345\224\256\345\207\272\345\272\223/Kf_SellOutBill.html" @@ -89,7 +89,7 @@ <input type="hidden" name="HMainSourceInterID" id="HMainSourceInterID" class="layui-input" value="0" style="float:left;width:150px;"> <input type="hidden" name="HMainSourceEntryID" id="HMainSourceEntryID" class="layui-input" value="0" style="float:left;width:150px;"> <input type="hidden" name="HMainSourceBillType" id="HMainSourceBillType" class="layui-input" value="" style="float:left;width:150px;"> - <input type="text" name="HMainSourceBillNo" id="HMainSourceBillNo" class="layui-input" value="" style="float: left; width: 150px; background-color: #efefef4d;" readonly> + <input type="text" name="HMainSourceBillNo" id="HMainSourceBillNo" class="layui-input" value="" style="float: left; width: 150px; background-color: #efefef4d;" readonly> <button type="button" lay-submit="" class="layui-btn" lay-filter="HMainSource" style="width:40px;"> <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> </button> @@ -100,11 +100,11 @@ <div class="layui-inline"> <label class="layui-form-label">閿�鍞憳</label> <div class="layui-input-inline"> - <input type="text" name="HEmpName" id="HEmpName" class="layui-input" value="" style="background-color:#efefef4d;" readonly> + <input type="text" name="HEmpName" id="HEmpName" class="layui-input" value="" style="background-color:#efefef4d;" readonly> <input type="hidden" name="HEmpID" id="HEmpID" class="layui-input" value="0" style="float:left;width:150px;"> <!--<button type="button" lay-submit="" class="layui-btn" lay-filter="HEmpList" style="width:40px;"> - <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> - </button>--> + <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> + </button>--> </div> </div> <div class="layui-inline"> @@ -113,8 +113,8 @@ <input type="text" name="HDeptName" id="HDeptName" class="layui-input" value="" style="background-color:#efefef4d;" readonly> <input type="hidden" name="HDeptID" id="HDeptID" class="layui-input" value="0" style="float:left;width:150px;"> <!--<button type="button" lay-submit="" class="layui-btn" lay-filter="HDeptList" style="width:40px;"> - <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> - </button>--> + <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> + </button>--> </div> </div> <div class="layui-inline"> @@ -123,8 +123,8 @@ <input type="text" name="HManagerName" id="HManagerName" class="layui-input" value="" style="background-color:#efefef4d;" readonly> <input type="hidden" name="HManagerID" id="HManagerID" class="layui-input" value="0" style="float:left;width:150px;"> <!--<button type="button" lay-submit="" class="layui-btn" lay-filter="HManagerList" style="width:40px;"> - <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> - </button>--> + <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> + </button>--> </div> </div> <div class="layui-inline"> @@ -133,8 +133,8 @@ <input type="text" name="HSupName" id="HSupName" class="layui-input" value="" style="background-color:#efefef4d;" readonly> <input type="hidden" name="HSupID" id="HSupID" class="layui-input" value="0" style="float:left;width:150px;"> <!--<button type="button" lay-submit="" class="layui-btn" lay-filter="HSupList" style="width:40px;"> - <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> - </button>--> + <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> + </button>--> </div> </div> </div> @@ -145,8 +145,8 @@ <input type="text" name="HCurName" id="HCurName" class="layui-input" value="" style="background-color:#efefef4d;" readonly> <input type="hidden" name="HCurID" id="HCurID" class="layui-input" value="0" style="float:left;width:150px;"> <!--<button type="button" lay-submit="" class="layui-btn" lay-filter="HCurList" style="width:40px;"> - <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> - </button>--> + <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> + </button>--> </div> </div> <div class="layui-inline"> @@ -175,8 +175,8 @@ <input type="text" name="HSellSName" id="HSellSName" class="layui-input" value="" style="background-color:#efefef4d;" readonly> <input type="hidden" name="HSellSID" id="HSellSID" class="layui-input" value="0" style="float:left;width:150px;"> <!--<button type="button" lay-submit="" class="layui-btn" lay-filter="HSellSList" style="width:40px;"> - <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> - </button>--> + <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> + </button>--> </div> </div> <div class="layui-inline"> @@ -238,6 +238,43 @@ </div> </div> </div> + <div class="layui-row"> + <div class="layui-inline"> + <label class="layui-form-label">椤圭洰浠g爜</label> + <div class="layui-input-inline"> + <input type="text" class="layui-input" lay-verify="HProjectNumber" name="HProjectNumber" id="HProjectNumber" value="" style="background-color: #efefef4d;float: left; width: 150px;" readonly> + <input type="hidden" name="HProjectID" id="HProjectID" lay-verify="HProjectID" value="0"> + <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearchHProNumber" id="btnSearchHProNumber" style="width:40px;"> + <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> + </button> + </div> + </div> + <div class="layui-inline"> + <label class="layui-form-label">椤圭洰鍚嶇О</label> + <div class="layui-input-block"> + <input type="text" class="layui-input" lay-verify="HProjectName" name="HProjectName" id="HProjectName" readonly> + </div> + </div> + <div class="layui-inline"> + <label class="layui-form-label">鐝粍</label> + <div class="layui-input-inline"> + <input type="text" class="layui-input" lay-verify="HGroupName" name="HGroupName" id="HGroupName" value="" style="background-color: #efefef4d;float: left; width: 150px;" readonly> + <input type="hidden" name="HGroupID" id="HGroupID" lay-verify="HGroupID" value="0"> + <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearchHGroup" id="btnSearchHGroup" style="width:40px;"> + <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i> + </button> + </div> + </div> + <div class="layui-inline"> + <label class="layui-form-label">鍗曚环绫诲瀷</label> + <div class="layui-input-inline"> + <select name="HPriceType" id="HPriceType" lay-filter="HPriceType" style="width: 180px; "> + <option value="鎴愭湰浠�" selected="selected">鎴愭湰浠�</option> + <option value="缁撶畻浠�">缁撶畻浠�</option> + </select> + </div> + </div> + </div> <div class="layui-row" style="margin-top:10px;"> <div class="layui-inline"> <label class="layui-form-label" style="width: 85px;">缁勭粐<label style="color:red"> * </label></label> @@ -274,7 +311,7 @@ <div class="layui-inline"> <label class="layui-form-label"></label> <div class="layui-input-inline"> - <input class="layui-input" name="HConveyMoney" id="HConveyMoney" autocomplete="off" value="0" > + <input class="layui-input" name="HConveyMoney" id="HConveyMoney" autocomplete="off" value="0"> </div> </div> <div class="layui-inline"> @@ -444,7 +481,7 @@ var HOrgIDBar = 0; //瀛愯〃娓叉煋鍙傛暟 - var option = {}; + window.option = {}; //#endregion @@ -652,6 +689,18 @@ //#region 閫夋嫨婧愬崟鎸夐挳 form.on('submit(HMainSource)', function () { get_checkMainSource(); + }); + //#endregion + + //#region 椤圭洰浠g爜 + form.on('submit(btnSearchHProNumber)', function () { + get_checkSearchHProNumber(); + }); + //#endregion + + //#region 鐝粍 + form.on('submit(btnSearchHGroup)', function () { + get_checkSearchHGroup(); }); //#endregion @@ -1261,9 +1310,9 @@ type: 2//寮圭獥绫诲瀷 , skin: 'layui-layer-rim' //鍔犱笂杈规 , area: ['90%', '90%']//澶у皬 - , title: '鍑哄簱浠撳簱鍒楄〃'//鏍囬 + , title: '浠撳簱鍒楄〃'//鏍囬 , shift: 2//寮瑰嚭鍔ㄧ敾 - , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Warehouse.html', 'yes'] + , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Warehouse.html?Type=HWH', 'yes'] , btn: ['纭畾', '鍙栨秷'] , btn1: function (index, layero) {//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟 var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮规椤甸潰 @@ -1274,15 +1323,15 @@ $("#HWHName").val(checkStatus.data[0].浠撳簱鍚嶇О); $("#HWHID").val(checkStatus.data[0].HItemID); - //鏍规嵁琛ㄥご 鍑哄簱浠撳簱 甯﹀嚭瀛愯〃 鍙戣揣浠撳簱 - for (var i = 0; i < option.data.length; i++) { - if (option.data[i].HWHID + "" == "0") { - option.data[i].HWHID = checkStatus.data[0].HItemID; - option.data[i].鍙戣揣浠撳簱 = checkStatus.data[0].浠撳簱鍚嶇О; + if (option.data.length > 0) { + for (var i = 0; i < option.data.length; i++) { + if (option.data[i]["HWHID"] == 0) { + option.data[i]["HWHID"] = checkStatus.data[0].HItemID; + option.data[i]["鍙戣揣浠撳簱"] = checkStatus.data[0].浠撳簱鍚嶇О; + } } } table.render(option); - layer.close(index); //瀹冭幏鍙栫殑濮嬬粓鏄渶鏂板脊鍑虹殑鏌愪釜灞傦紝鍊兼槸鐢眑ayer鍐呴儴鍔ㄦ�侀�掑璁$畻鐨� } , btn2: function (index, layero) { } @@ -1351,6 +1400,76 @@ layer.close(index); //瀹冭幏鍙栫殑濮嬬粓鏄渶鏂板脊鍑虹殑鏌愪釜灞傦紝鍊兼槸鐢眑ayer鍐呴儴鍔ㄦ�侀�掑璁$畻鐨� } , btn2: function (index, layero) { } + }) + } + //#endregion + + //#region 椤圭洰浠g爜 + function get_checkSearchHProNumber() { + var HOrgID = $("#HOrgID").val(); + //鎵撳紑宸ョ▼椤圭洰灏忕獥浣� + layer.open({ + type: 2 + , skin: "layui-layer-rim" //鍔犱笂杈规 + , title: "宸ョ▼椤圭洰鍒楄〃" //鏍囬 + , closeBtn: 1 //绐椾綋鍙充笂瑙掑叧闂� 鐨� 鏍峰紡 + , shift: 2 //寮瑰嚭鍔ㄧ敾 + , area: ["90%", "90%"] //绐椾綋澶у皬 + , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀� + , content: ["../../椤圭洰绠$悊/宸ョ▼椤圭洰/PM_ProjectBillList.html?openType=2&HOrgID=" + HOrgID, "yes"] + , btn: ["纭畾", "鍙栨秷"] + , btn1: function (index, laero) { + //鎸夐挳涓� 鐨勫洖璋� + var iframeWindow = window["layui-layer-iframe" + index];//鑾峰彇寮规椤甸潰 + var checkStatus = iframeWindow.layui.table.checkStatus("mainTable");//鑾峰彇閫変腑鐨勬暟鎹� + + if (checkStatus.data.length != 1) { + return layer.msg("璇烽�夋嫨涓�鏉℃暟鎹�"); + } + + //鍒ゆ柇椤圭洰鏄惁鍏抽棴 + if (checkStatus.data[0].鍏抽棴浜� == null || checkStatus.data[0].鍏抽棴浜� == "") { + $("#HProjectID").val(checkStatus.data[0].HInterID); + $("#HProjectNumber").val(checkStatus.data[0].椤圭洰浠g爜);//宸ョ▼椤圭洰浠g爜 + $("#HProjectName").val(checkStatus.data[0].椤圭洰鍚嶇О);//宸ョ▼椤圭洰浠g爜 + } else { + layer.msg("璇ラ」鐩凡鍏抽棴锛屼笉鍙�夋嫨锛�"); + } + layer.close(index);//鍏抽棴寮圭獥 + } + , btn2: function (index, layero) { } + , end: function () { } + }) + } + //#endregion + + //#region 鐝粍 + function get_checkSearchHGroup() { + layer.open({ + type: 2 + , skin: "layui-layer-rim" //鍔犱笂杈规 + , title: "鐝粍鍒楄〃" //鏍囬 + , closeBtn: 1 //绐椾綋鍙充笂瑙掑叧闂� 鐨� 鏍峰紡 + , shift: 2 //寮瑰嚭鍔ㄧ敾 + , area: ["90%", "90%"] //绐椾綋澶у皬 + , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀� + , content: ["../../鍩虹璧勬枡/宸ヨ祫鍩虹璧勬枡/Gy_Group.html?type=HGroup", "yes"] + , btn: ["纭畾", "鍙栨秷"] + , btn1: function (index, laero) { + //鎸夐挳涓� 鐨勫洖璋� + var iframeWindow = window["layui-layer-iframe" + index];//鑾峰彇寮规椤甸潰 + var checkStatus = iframeWindow.layui.table.checkStatus("mainTable");//鑾峰彇閫変腑鐨勬暟鎹� + + if (checkStatus.data.length != 1) { + return layer.msg("璇烽�夋嫨涓�鏉℃暟鎹�"); + } + + $("#HGroupID").val(checkStatus.data[0].HItemID); + $("#HGroupName").val(checkStatus.data[0].鐝粍鍚嶇О);//宸ョ▼椤圭洰浠g爜 + layer.close(index);//鍏抽棴寮圭獥 + } + , btn2: function (index, layero) { } + , end: function () { } }) } //#endregion @@ -1581,6 +1700,12 @@ , "HKeeperName": data.淇濈鍛� , "HWHID": data.HWHID_Main , "HWHName": data.涓昏〃浠撳簱 + , "HProjectID": data.HProjectID + , "HProjectNumber": data.椤圭洰缂栫爜 + , "HProjectName": data.椤圭洰鍚嶇О + , "HGroupID": data.HGroupID + , "HGroupName": data.鐝粍 + , "HPriceType": data.鍗曚环绫诲瀷 , "HRemark": data.琛ㄥご澶囨敞 @@ -2080,7 +2205,7 @@ , shift: 2 //寮瑰嚭鍔ㄧ敾 , area: ["90%", "90%"] //绐椾綋澶у皬 , maxmin: true //璁剧疆鏈�澶ф渶灏忔寜閽槸鍚︽樉绀� - , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Warehouse.html', 'yes'] + , content: ['../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_Warehouse.html?type=HWHSub', 'yes'] , btn: ["纭畾", "鍙栨秷"] , btn1: function (index, laero) { //鎸夐挳涓� 鐨勫洖璋� @@ -2092,10 +2217,17 @@ } //鏇存柊琛ㄦ牸缂撳瓨鐨勬暟鎹� obj.update({ + + "HWHID": checkStatus.data[0].HItemID, "鍙戣揣浠撳簱": checkStatus.data[0].浠撳簱鍚嶇О - , "HWHID": checkStatus.data[0].HItemID }) layer.close(index);//鍏抽棴寮圭獥 + } + , end: function () { + obj.update({ + "HWHID": OptionData.HItemID + , "鍙戣揣浠撳簱": OptionData.浠撳簱鍚嶇О + }) } }) } @@ -2446,6 +2578,9 @@ , "HCurID": dataArray[0].HCurID , "HCurName": dataArray[0].甯佸埆 , "HExRate": dataArray[0].姹囩巼 + , "HProjectID": dataArray[0].HProjectID + , "HProjectNumber": dataArray[0].椤圭洰缂栫爜 + , "HProjectName": dataArray[0].椤圭洰鍚嶇О }); //瀛愯〃 璧嬪�� @@ -2698,11 +2833,11 @@ $("#HDeptID").val(obj[0].HItemID); } - function GetHWHValue(obj) //杩斿洖浠撳簱 - { - //$("#HWHName").val(obj[0].HName); - //$("#HWHID").val(obj[0].HItemID); - } + //function GetHWHValue(obj) //杩斿洖浠撳簱 + //{ + // //$("#HWHName").val(obj[0].HName); + // //$("#HWHID").val(obj[0].HItemID); + //} function GetSellStyleValue(obj) //杩斿洖閿�鍞柟寮� { @@ -2734,9 +2869,48 @@ $("#HConveyCompID").val(obj[0].HItemID); } - function GetHSCWHNAMEValue(obj) { //杩斿洖鍑哄簱浠撳簱 - $("#HWHName").val(obj[0].HName); + + //function GetHSCWHNAMEValue(obj) { //杩斿洖鍑哄簱浠撳簱 + // $("#HWHName").val(obj[0].HName); + // $("#HWHID").val(obj[0].HItemID); + //} + + function GetHGroupValue(obj) //杩斿洖鐝粍 + { + $("#HGroupID").val(obj[0].HItemID); + $("#HGroupName").val(obj[0].鐝粍鍚嶇О); + } + + //椤圭洰浠g爜 + function GetProjectBillValue(obj) { + if (obj[0].鍏抽棴浜� == null || obj[0].鍏抽棴浜� == "") { + $("#HProjectID").val(obj[0].HInterID); + $("#HProjectNumber").val(obj[0].椤圭洰浠g爜);//宸ョ▼椤圭洰浠g爜 + $("#HProjectName").val(obj[0].椤圭洰鍚嶇О);//宸ョ▼椤圭洰浠g爜 + + } else { + layer.msg("璇ラ」鐩凡鍏抽棴锛屼笉鍙�夋嫨锛�"); + } + } + + //鍙屽嚮杩斿洖浠撳簱 + function GetHWHSubValue(data) { + OptionData = data[0] + } + + function GetHWHValue(obj) //杩斿洖浠撳簱 + { + $("#HWHName").val(obj[0].浠撳簱鍚嶇О); $("#HWHID").val(obj[0].HItemID); + if (option.data.length > 0) { + for (var i = 0; i < option.data.length; i++) { + if (option.data[i]["HWHID"] == 0 || option.data[i]["鍙戣揣浠撳簱"] == undefined) { + option.data[i]["HWHID"] = obj[0].HItemID; + option.data[i]["鍙戣揣浠撳簱"] = obj[0].浠撳簱鍚嶇О; + } + } + } + layui.table.render(option); } //#region 鏍规嵁瀹㈡埛鑾峰彇甯佸埆銆佹眹鐜囥�佺粨绠楁柟寮忋�佸鎴蜂俊鐢ㄩ搴︺�佽仈绯讳汉銆佽仈绯荤數璇� -- Gitblit v1.9.1