From 1c6a4c87cc53dfe72d4af0cff53e627d406589eb Mon Sep 17 00:00:00 2001
From: yangle <admin@YINMOU>
Date: 星期一, 13 五月 2024 10:40:52 +0800
Subject: [PATCH] 1

---
 WebTM/views/模治具管理/模治具管理/Sc_Add_MouldDotCheckPlanBillList.html |  106 ++++++++++++++++++++++++++++++++++++++++++++++-------
 1 files changed, 92 insertions(+), 14 deletions(-)

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 bb2d9c0..a8488e9 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"
@@ -102,7 +102,7 @@
                                                     <label class="layui-form-label" style="width:95px;">鍣ㄥ叿鐐规瑙勭▼<label style="color:red"> * </label></label>
                                                     <div class="layui-input-inline">
                                                         <input type="text" name="HMouldDotCheckRuleName" id="HMouldDotCheckRuleName" class="layui-input" value="" style="float:left;width:150px;">
-                                                        <input type="hidden" name="HMouldDotCheckRuleID" id="HMouldDotCheckRuleID" class="layui-input" value="" style="float:left;width:150px;">
+                                                        <input type="hidden" name="HMouldDotCheckRuleID" id="HMouldDotCheckRuleID" class="layui-input" value="0" style="float:left;width:150px;">
                                                         <button type="button" lay-submit="" class="layui-btn" lay-filter="btnHMouldDotCheckRule" style="width:40px;">
                                                             <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i>
                                                         </button>
@@ -296,7 +296,7 @@
             table.on('toolbar(mainTable)', function (obj) {
                 var checkStatus = table.checkStatus('mainTable')
                     , data = checkStatus.data;
-                var NewRow = { "HDotCheckItemID": 0, "HDotCheckCode": "", "HDotCheckItem": "", "HDotCheckPart": "", "HClaim": "", "HManagerID": 0, "HManagerCode": "", "HManagerName": "", "HRemark": "" };
+                var NewRow = { "HDotCheckItemID": 0, "HDotCheckCode": "", "HDotCheckItem": "", "HDotCheckPart": "", "HClaim": "", "HManagerID": 0, "HManagerCode": "", "HManagerName": "", "HRemark": "", "HDotCheckItemClassID": 0, "HDotCheckItemClassName": "", "HDotCheckItemMethodID": 0, "HDotCheckItemMethodName": "" };
                 switch (obj.event) {
                     //澧炲姞涓�琛�
                     case 'btn-AddLine': set_AddLine(NewRow);
@@ -398,6 +398,10 @@
                     , { templet: '#xuhao', title: '搴忓彿', sort: true, fixed: 'left', event: "qwe" }
                     , { field: 'HDotCheckItemID', title: '鐐规椤圭洰ID', edit: 'text', hide: true }
                     , { field: 'HDotCheckItem', title: '鐐规椤圭洰', edit: 'text', event: "HDotCheckCode" }
+                    , { field: 'HDotCheckItemClassID', title: '鐐规椤圭洰鍒嗙被ID', edit: 'text', hide: true }
+                    , { field: 'HDotCheckItemClassName', title: '鐐规椤圭洰鍒嗙被', edit: 'text', event: 'HDotCheckItemClassName' }
+                    , { field: 'HDotCheckItemMethodID', title: '鐐规鏂规硶ID', edit: 'text', hide: true }
+                    , { field: 'HDotCheckItemMethodName', title: '鐐规鏂规硶', edit: 'text', event: 'HDotCheckItemMethodName' }
                     , { field: 'HDotCheckPart', title: '鐐规閮ㄤ綅', edit: 'text', event: "" }
                     , { field: 'HClaim', title: '鍏蜂綋瑕佹眰', edit: 'text' }
                     , { field: 'HManagerID', title: '璐熻矗浜轰唬鐮�', edit: 'text', hide: true }
@@ -431,21 +435,21 @@
                     success: function (result) {
                         if (result != null) {
                             if (result.count == 1) {
-                                var BYData = result.list[0];//鐐规
+                                var DJData = result.list[0];//鐐规
                                 var PJData = result.list[1];//閰嶄欢
                                 var rowdate1 = layui.table.cache["mainTable"];
                                 var rowdate2 = layui.table.cache["mainTable1"];
-                                option.data = [{ "HDotCheckItemID": 0, "HDotCheckItem": "", "HDotCheckPart": "", "HClaim": "", "HManagerID": 0, "HManagerCode": "", "HManagerName": "", "HRemark": "" }];
+                                option.data = [{ "HDotCheckItemID": 0, "HDotCheckItem": "", "HDotCheckPart": "", "HClaim": "", "HManagerID": 0, "HManagerCode": "", "HManagerName": "", "HRemark": "", "HDotCheckItemClassID": 0, "HDotCheckItemClassName": "", "HDotCheckItemMethodID": 0, "HDotCheckItemMethodName": "" }];
                                 table.render(option);
 
-                                if (BYData.length != 0)  //琛ㄤ綋鏁版嵁涓嶄负绌烘椂
+                                if (DJData.length != 0)  //琛ㄤ綋鏁版嵁涓嶄负绌烘椂
                                 {
                                     buttonArr = [];//娓呯┖鏁扮粍
-                                    for (var i = 0; i < BYData.length; i++) {
+                                    for (var i = 0; i < DJData.length; i++) {
                                         var checkrow = {
-                                            "HDotCheckItemID": BYData[i].HDotCheckItemID, "HDotCheckItem": BYData[i].HDotCheckItem, "HDotCheckPart": BYData[i].HDotCheckPart,
-                                            "HClaim": BYData[i].HClaim, "HManagerID": BYData[i].HManagerID, "HManagerCode": BYData[i].HManagerNumber,
-                                            "HManagerName": BYData[i].HManagerName, "HRemark": BYData[i].HRemark
+                                            "HDotCheckItemID": DJData[i].鐐规椤圭洰ID, "HDotCheckItem": DJData[i].鐐规椤圭洰, "HDotCheckPart": DJData[i].鐐规閮ㄤ綅,
+                                            "HClaim": DJData[i].鍏蜂綋瑕佹眰, "HManagerID": DJData[i].璐熻矗浜篒D, "HManagerCode": DJData[i].璐熻矗浜轰唬鐮�,
+                                            "HManagerName": DJData[i].璐熻矗浜哄悕绉�, "HRemark": DJData[i].瀛愬娉�, "HDotCheckItemClassID": DJData[i].HDotCheckItemClassID, "HDotCheckItemClassName": DJData[i].鐐规椤圭洰鍒嗙被鍚嶇О, "HDotCheckItemMethodID": DJData[i].HDotCheckItemMethodID, "HDotCheckItemMethodName": DJData[i].鐐规鏂规硶鍚嶇О
                                         };
                                         buttonArr.push(checkrow);  //灏嗕箣鍓嶇殑鏁版嵁瀛樺偍
                                     }
@@ -466,7 +470,7 @@
             function set_AddFNew() {
                 //鑾峰彇鏈�澶у崟鎹彿
                 get_MAXNum();
-                option.data = [{ "HDotCheckItemID": 0, "HDotCheckItem": "", "HDotCheckPart": "", "HClaim": "", "HManagerID": 0, "HManagerCode": "", "HManagerName": "", "HRemark": "" }];
+                option.data = [{ "HDotCheckItemID": 0, "HDotCheckItem": "", "HDotCheckPart": "", "HClaim": "", "HManagerID": 0, "HManagerCode": "", "HManagerName": "", "HRemark": "", "HDotCheckItemClassID": 0, "HDotCheckItemClassName": "", "HDotCheckItemMethodID": 0, "HDotCheckItemMethodName": "" }];
                 table.render(option);
             }
             //鑾峰彇鏈�澶у崟鎹彿鍙婇粯璁ゅ�艰祴鍊�
@@ -494,7 +498,7 @@
             function set_EditFromGrid() {
                 set_EditForm(linterid);  //缂栬緫鑾峰彇琛ㄥご
                 set_EditGrid(linterid);  //缂栬緫鑾峰彇琛ㄤ綋
-                option.data = [{ "HDotCheckItemID": 0, "HDotCheckItem": "", "HDotCheckPart": "", "HClaim": "", "HManagerID": 0, "HManagerCode": "", "HManagerName": "", "HRemark": "" }];
+                option.data = [{ "HDotCheckItemID": 0, "HDotCheckItem": "", "HDotCheckPart": "", "HClaim": "", "HManagerID": 0, "HManagerCode": "", "HManagerName": "", "HRemark": "", "HDotCheckItemClassID": 0, "HDotCheckItemClassName": "", "HDotCheckItemMethodID": 0, "HDotCheckItemMethodName": "" }];
                 table.render(option);
             }
             //缂栬緫鍔犺浇琛ㄥご
@@ -544,9 +548,14 @@
                     type: "GET",
                     data: { "sqlWhere": "and HInterID=" + linterid },
                     success: function (result) {
-                        //console.log('gouba' + result);
                         if (result.count == 1) {
-                            option.data = result.list[0];
+                            var data = result.data;
+                            var subarr = [];
+                            for (var i = 0; i < data.length; i++) {
+                                subarr.push({ "HDotCheckItemID": data[i].鐐规椤圭洰ID, "HDotCheckCode": "", "HDotCheckItem": data[i].鐐规椤圭洰, "HDotCheckPart": data[i].鐐规閮ㄤ綅, "HClaim": data[i].鍏蜂綋瑕佹眰, "HManagerID": data[i].璐熻矗浜篒D, "HManagerCode": data[i].璐熻矗浠g爜, "HManagerName": data[i].璐熻矗浜哄悕绉�, "HRemark": data[i].琛ㄤ綋澶囨敞, "HDotCheckItemClassID": data[i].HDotCheckItemClassID, "HDotCheckItemClassName": data[i].鐐规椤圭洰鍒嗙被鍚嶇О, "HDotCheckItemMethodID": data[i].HDotCheckItemMethodID, "HDotCheckItemMethodName": data[i].鐐规鏂规硶鍚嶇О });
+                            }
+
+                            option.data = subarr;
                             table.render(option);
 
                         } else {
@@ -654,7 +663,9 @@
                                     obj.update({
                                         HDotCheckItemID: checkStatus.data[0].HItemID,
                                         HDotCheckCode: checkStatus.data[0].鐐规椤圭洰浠g爜,
-                                        HDotCheckItem: checkStatus.data[0].鐐规椤圭洰鍚嶇О
+                                        HDotCheckItem: checkStatus.data[0].鐐规椤圭洰鍚嶇О,
+                                        HDotCheckItemClassID: checkStatus.data[0].HDotCheckItemClassID,
+                                        HDotCheckItemClassName: checkStatus.data[0].鐐规椤圭洰鍒嗙被鍚嶇О,
                                     });
                                     layer.close(layer.index); //瀹冭幏鍙栫殑濮嬬粓鏄渶鏂板脊鍑虹殑鏌愪釜灞傦紝鍊兼槸鐢眑ayer鍐呴儴鍔ㄦ�侀�掑璁$畻鐨�
                                 }
@@ -702,6 +713,73 @@
                                 }
                             });
                         }
+                        if (obj.event === 'HDotCheckItemClassName')  //鐐规椤圭洰鍒嗙被
+                        {
+                            //椤甸潰灞�-鑷畾涔�
+                            layer.open({
+                                type: 2,
+                                skin: 'layui-layer-rim', //鍔犱笂杈规
+                                title: '鐐规椤圭洰鍒嗙被鍒楄〃',
+                                closeBtn: 1,
+                                shift: 2,
+                                area: ['90%', '90%'],
+                                maxmin: true
+                                , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckItemClassList.html', 'yes']
+                                , btn: ['纭畾', '鍙栨秷']
+                                , btn1: function (index, layero) {
+                                    //鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
+                                    var iframeWindow = window['layui-layer-iframe' + index]  //鑾峰彇寮规椤甸潰
+                                    var checkStatus = iframeWindow.layui.table.checkStatus('mainTable');//鑾峰彇table鐨別lem:"#test"
+                                    if (checkStatus.data.length === 0) {
+                                        return layer.msg('璇烽�夋嫨鏁版嵁');
+                                    }
+                                    //鍚屾鏇存柊琛ㄦ牸鍜岀紦瀛樺搴旂殑鍊�
+                                    obj.update({
+                                        HDotCheckItemClassID: checkStatus.data[0].HItemID,
+                                        HDotCheckItemClassName: checkStatus.data[0].鐐规椤圭洰鍒嗙被鍚嶇О
+                                    });
+                                    layer.close(layer.index); //瀹冭幏鍙栫殑濮嬬粓鏄渶鏂板脊鍑虹殑鏌愪釜灞傦紝鍊兼槸鐢眑ayer鍐呴儴鍔ㄦ�侀�掑璁$畻鐨�
+                                }
+                                , btn2: function (index, layero) {
+                                    //鎸夐挳銆愭寜閽簩銆戠殑鍥炶皟
+                                    //return false 寮�鍚浠g爜鍙姝㈢偣鍑昏鎸夐挳鍏抽棴
+                                }
+                            });
+                        }
+                        if (obj.event === 'HDotCheckItemMethodName')  //鐐规鏂规硶
+                        {
+                            //椤甸潰灞�-鑷畾涔�
+                            layer.open({
+                                type: 2,
+                                skin: 'layui-layer-rim', //鍔犱笂杈规
+                                title: '鐐规鏂规硶鍒楄〃',
+                                closeBtn: 1,
+                                shift: 2,
+                                area: ['90%', '90%'],
+                                maxmin: true
+                                , content: ['../../鍩虹璧勬枡/鍩虹璧勬枡/Gy_DotCheckItemMethodList.html', 'yes']
+                                , btn: ['纭畾', '鍙栨秷']
+                                , btn1: function (index, layero) {
+                                    //鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
+                                    var iframeWindow = window['layui-layer-iframe' + index]  //鑾峰彇寮规椤甸潰
+                                    var checkStatus = iframeWindow.layui.table.checkStatus('mainTable');//鑾峰彇table鐨別lem:"#test"
+                                    if (checkStatus.data.length === 0) {
+                                        return layer.msg('璇烽�夋嫨鏁版嵁');
+                                    }
+                                    //鍚屾鏇存柊琛ㄦ牸鍜岀紦瀛樺搴旂殑鍊�
+                                    obj.update({
+                                        HDotCheckItemMethodID: checkStatus.data[0].HItemID,
+                                        HDotCheckItemMethodName: checkStatus.data[0].鐐规鏂规硶鍚嶇О
+                                    });
+                                    layer.close(layer.index); //瀹冭幏鍙栫殑濮嬬粓鏄渶鏂板脊鍑虹殑鏌愪釜灞傦紝鍊兼槸鐢眑ayer鍐呴儴鍔ㄦ�侀�掑璁$畻鐨�
+                                }
+                                , btn2: function (index, layero) {
+                                    //鎸夐挳銆愭寜閽簩銆戠殑鍥炶皟
+                                    //return false 寮�鍚浠g爜鍙姝㈢偣鍑昏鎸夐挳鍏抽棴
+                                }
+                            });
+                        }
+
                         obj.event = "";
                         return false;
 

--
Gitblit v1.9.1