From a853c96fb287ea5e9edaa39e0c63f6d9de04f9d1 Mon Sep 17 00:00:00 2001
From: wtt <1985833171@qq.com>
Date: 星期一, 15 十二月 2025 08:14:07 +0800
Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-LayUI

---
 WebTM/views/设备管理/Sb_Add_EqpMaintenanceBillList.html |   55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 55 insertions(+), 0 deletions(-)

diff --git "a/WebTM/views/\350\256\276\345\244\207\347\256\241\347\220\206/Sb_Add_EqpMaintenanceBillList.html" "b/WebTM/views/\350\256\276\345\244\207\347\256\241\347\220\206/Sb_Add_EqpMaintenanceBillList.html"
index 2cc0e4a..417308b 100644
--- "a/WebTM/views/\350\256\276\345\244\207\347\256\241\347\220\206/Sb_Add_EqpMaintenanceBillList.html"
+++ "b/WebTM/views/\350\256\276\345\244\207\347\256\241\347\220\206/Sb_Add_EqpMaintenanceBillList.html"
@@ -366,6 +366,7 @@
             var OperationType = params[params[0]];//鎿嶄綔绫诲瀷
             var linterid = params[params[1]];//婧愬崟id
             var HSouceBillType = params[params[2]];//婧愬崟绫诲瀷
+            var HMainSourceBillNo = params[params[3]];
         }
 
         layui.config({
@@ -414,6 +415,9 @@
             }
             else if (OperationType == 3) {//缂栬緫
                 set_EditFromGrid();
+            }
+            else if (OperationType == 4) {//涓嬫帹
+                setInit_PushBill();
             }
             else {
                 layer.alert("鏈煡鎿嶄綔绫诲瀷锛�", { icon: 5 });
@@ -1234,6 +1238,57 @@
                 }
             }
 
+            //#region 涓嬫帹椤甸潰鍒濆鍖�
+            function setInit_PushBill() {
+                //鐢熸垚鍗曟嵁鍙峰拰鍐呯爜
+                get_MAXNum();
+                $("#HEmpID").val(sessionStorage["HEmpID"]); //鏍规嵁鐧诲綍鐢ㄦ埛甯﹀嚭缁翠慨浜篒D
+                $("#HEmpName").val(sessionStorage["HEmpName"]); //鏍规嵁鐧诲綍鐢ㄦ埛甯﹀嚭缁翠慨浜�
+                $("#HDeptID").val(sessionStorage["HDeptID"]); //鏍规嵁鐧诲綍鐢ㄦ埛甯﹀嚭閮ㄩ棬ID
+                $("#HDeptName").val(sessionStorage["HDept"]); //鏍规嵁鐧诲綍鐢ㄦ埛甯﹀嚭閮ㄩ棬
+                $("#HManagerID").val(sessionStorage["HEmpID"]); //鏍规嵁鐧诲綍鐢ㄦ埛甯﹀嚭璐熻矗浜篒D
+                $("#HManagerName").val(sessionStorage["HEmpName"]); //鏍规嵁鐧诲綍鐢ㄦ埛甯﹀嚭璐熻矗浜�
+                $("#HMainSourceBillType").val() == "璁惧缁翠慨鐧昏鍗�";
+                $('#XDHList').addClass("layui-btn-disabled").attr("disabled", true);
+                $("#HMainSourceBillNo").val(HMainSourceBillNo);
+                document.getElementById('HMainSourceBillNo').style.backgroundColor = '#efefef4d';
+                  //鎸夐�夊崟鍙峰姞杞借〃浣撴暟鎹�
+                $.ajax({
+                    url: GetWEBURL() + 'Sb_EqpRepairWorkBill/Sb_EqpRepairWorkBillSubByHMainSourceBillNo',
+                    type: "GET",
+                    data: { "HMainSourceBillNo": HMainSourceBillNo },
+                    success: function (result) {
+                        if (result.count == 1) {
+                            var EndData = result.data;
+
+                            $("#HMainSourceInterID").val(EndData[0].hmainid);
+                            $("#HMainSourceEntryID").val(EndData[0].hsubid);
+                            // 鍥炲~璁惧淇℃伅
+                            $("#HEquipName").val(EndData[0].璁惧鍚嶇О);
+                            $("#HEquipID").val(EndData[0].HEquipID);
+
+                          
+                            if (EndData && EndData.length > 0) {
+                                // 缁翠慨淇℃伅琛ㄦ牸
+                                option.data = EndData; // 浣跨敤鑾峰彇鐨勬暟鎹�
+                                table.render(option);
+
+                                
+                                option1.data = [{ "HMaterID": 0, "HMaterNumber": "", "HMaterName": "", "HUnitID": 0, "HUnitNumber": "", "HUnitName": "", "HManagerID": sessionStorage["HEmpID"], "HManagerNumber": sessionStorage["HEmpNumber"], "HManagerName": sessionStorage["HEmpName"], "HQty": "0", "HRemark": "" }];
+                                
+                                table.render(option1);
+                            }
+
+                        } else {
+                            layer.alert(result.code + result.Message, { icon: 5 });
+                        }
+                    }, error: function () {
+                        layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+                    }
+                });
+            }
+            //#endregion
+
             // 琛ㄦ牸琛屽唴浜嬩欢蹇嵎閿瓫閫�1 閰嶄欢
             function set_GridCellCheck1(obj) {
                 $(document).off('keydown', ".layui-table-edit").on('keydown', '.layui-table-edit', function (e) {

--
Gitblit v1.9.1