| | |
| | | <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> |
| | | <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" 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> |
| | | </div> |
| | |
| | | //æ¥è¯¢æ¡ä»¶ |
| | | var sWhere = ""; |
| | | var option = []; |
| | | //var option = { |
| | | // elem: '#mainTable' |
| | | // , toolbar: '#toolbarDemo' |
| | | // , height: 550 |
| | | // , page: true |
| | | // , cellMinWidth: 90 |
| | | // , limits: [50, 500, 5000, 20000] |
| | | // , limit: 50 |
| | | // , cols: [[ |
| | | // { type: 'checkbox', fixed: 'left' } |
| | | // ,{ field: 'hmainid', title: '忮ID', hide: true } |
| | | // , { field: 'æ¥æ', title: 'æ¥æ', width: 160, templet: "<div>{{d.æ¥æ ==null ?'':layui.util.toDateString(d.æ¥æ, 'yyyy-MM-dd')}}</div>"} |
| | | // , { field: 'åæ®å·', title: 'åæ®å·', width: 160 } |
| | | // , { field: 'åæ®ç±»å', title: 'åæ®ç±»å', width: 160 } |
| | | // , { field: 'HEmID', title: 'HEmID', width: 200, hide: true } |
| | | // , { field: 'è°æ´äººä»£ç ', title: 'è°æ´äººä»£ç ', width: 200 } |
| | | // , { field: 'è°æ´äºº', title: 'è°æ´äºº', width: 200 } |
| | | // , { field: 'HMangerID', title: 'HEmID', width: 200, hide: true } |
| | | // , { field: 'è´è´£äººä»£ç ', title: 'è´è´£äººä»£ç ', width: 200 } |
| | | // , { field: 'è´è´£äºº', title: 'è´è´£äºº', width: 200 } |
| | | // , { field: 'HDeptID', title: 'HDeptID', width: 200, hide: true } |
| | | // , { field: 'é¨é¨ä»£ç ', title: 'é¨é¨ä»£ç ', width: 115 } |
| | | // , { field: 'é¨é¨', title: 'é¨é¨', width: 200 } |
| | | // , { field: 'è°æ´åå ', title: 'è°æ´åå ', width: 115 } |
| | | // , { field: 'æè¦', title: 'æè¦', width: 200 } |
| | | // , { field: 'å
é¨åæ®å·', title: 'å
é¨åæ®å·', width: 115 } |
| | | // , { field: '夿³¨', title: '夿³¨', width: 200 } |
| | | // , { field: 'hsubid', title: 'hsubid', width: 200, hide: true } |
| | | // , { field: 'å
³èæ°é', title: 'å
³èæ°é', width: 200 } |
| | | // , { field: 'è¡å
³é人', title: 'è¡å
³é人', width: 200 } |
| | | // , { field: 'å
³éç±»å', title: 'å
³éç±»å', width: 200 } |
| | | // , { field: '表ä½å¤æ³¨', title: '表ä½å¤æ³¨', width: 200 } |
| | | // , { field: 'HMaterID', title: 'HMaterID', width: 200, hide: true } |
| | | // , { field: '模å
·ä»£ç ', title: 'å¨å
·ä»£ç ', width: 200 } |
| | | // , { field: '模å
·', title: 'å¨å
·', width: 200 } |
| | | // , { field: 'HPropertyID', title: 'HPropertyID', width: 200, hide: true } |
| | | // , { field: 'è¾
å©å±æ§ä»£ç ', title: 'è¾
å©å±æ§ä»£ç ', width: 200 } |
| | | // , { field: 'è¾
å©å±æ§', title: 'è¾
å©å±æ§', width: 200 } |
| | | // , { field: 'HSecUnitID', title: 'HSecUnitID', width: 200, hide: true } |
| | | // , { field: 'è¾
å©è®¡éåä½ä»£ç ', title: 'è¾
å©è®¡éåä½ä»£ç ', width: 200 } |
| | | // , { field: 'è¾
å©è®¡éåä½', title: 'è¾
å©è®¡éåä½', width: 200 } |
| | | // , { field: 'æ¢ç®ç', title: 'æ¢ç®ç', width: 200 } |
| | | // , { field: 'Hunitid', title: 'Hunitid', width: 200, hide: true } |
| | | // , { field: '计éåä½ä»£ç ', title: '计éåä½ä»£ç ', width: 200 } |
| | | // , { field: '计éåä½', title: '计éåä½', width: 200 } |
| | | // , { field: '设计寿å½', title: '设计寿å½', width: 200 } |
| | | // , { field: 'åå©ä½å¯¿å½', title: 'åå©ä½å¯¿å½', width: 200 } |
| | | // , { field: 'æ°å©ä½å¯¿å½', title: 'æ°å©ä½å¯¿å½', width: 200 } |
| | | // , { field: 'å¶å人', title: 'å¶å人', width: 200 } |
| | | // , { field: 'å¶åæ¥æ', title: 'å¶åæ¥æ', width: 200, templet: "<div>{{d.å¶åæ¥æ ==null ?'':layui.util.toDateString(d.å¶åæ¥æ, 'yyyy-MM-dd HH:mm:ss')}}</div>" } |
| | | // , { field: 'å®¡æ ¸äºº', title: 'å®¡æ ¸äºº', width: 200 } |
| | | // , { field: 'å®¡æ ¸æ¥æ', title: 'å®¡æ ¸æ¥æ', width: 200, templet: "<div>{{d.å®¡æ ¸æ¥æ ==null ? '':layui.util.toDateString(d.å®¡æ ¸æ¥æ, 'yyyy-MM-dd HH:mm:ss')}}</div>" } |
| | | // , { field: 'ä¿®æ¹äºº', title: 'ä¿®æ¹äºº', width: 200 } |
| | | // , { field: 'ä¿®æ¹æ¥æ', title: 'ä¿®æ¹æ¥æ', width: 200, templet: "<div>{{d.ä¿®æ¹æ¥æ ==null ?'':layui.util.toDateString(d.ä¿®æ¹æ¥æ, 'yyyy-MM-dd HH:mm:ss')}}</div>" } |
| | | // , { field: 'å
³é人', title: 'å
³é人', width: 200 } |
| | | // , { field: 'å
³éæ¥æ', title: 'å
³éæ¥æ', width: 200, templet: "<div>{{d.å
³éæ¥æ ==null ?'':layui.util.toDateString(d.å
³éæ¥æ, 'yyyy-MM-dd HH:mm:ss')}}</div>" } |
| | | // , { field: 'ä½åºäºº', title: 'ä½åºäºº', width: 200 } |
| | | // , { field: 'ä½åºæ¥æ', title: 'ä½åºæ¥æ', width: 200, templet: "<div>{{d.ä½åºæ¥æ ==null ?'':layui.util.toDateString(d.ä½åºæ¥æ, 'yyyy-MM-dd HH:mm:ss')}}</div>" } |
| | | // , { field: 'æºå主å
ç ', title: 'æºå主å
ç ', width: 200, hide: true } |
| | | // , { field: 'æºååå
ç ', title: 'æºååå
ç ', width: 200, hide: true } |
| | | // , { field: 'æºååå·', title: 'æºååå·', width: 200 } |
| | | // , { field: 'æºåç±»å', title: 'æºåç±»å', width: 200 } |
| | | // ]] |
| | | //}; |
| | | |
| | | |
| | | var HModName = "Sc_MouldLifeChangeBillList"; |
| | | var HBillType = "3824"; |
| | | var col = []; |
| | |
| | | case 'set_HideButton': |
| | | var btns = document.getElementsByTagName("button"); //è·åæ¬é¡µæææé®å¯¹è±¡ |
| | | get_HideButton(btns, HBillType, HModName, sessionStorage["HUserName"]); |
| | | break; |
| | | //å®¡æ ¸ |
| | | case 'btn-Audit': set_AuditBill(); |
| | | break; |
| | | //åå®¡æ ¸ |
| | | case 'btn-DeAudit': set_DeAuditBill(); |
| | | break; |
| | | }; |
| | | }); |
| | |
| | | layer.alert("åå»äºä»¶", { icon: 1 }); |
| | | }); |
| | | |
| | | //å®¡æ ¸ |
| | | function set_AuditBill() { |
| | | 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_MouldLifeChangeBill/AuditSc_MouldLifeChangeBillList", //æ¹æ³æå¨é¡µé¢åæ¹æ³å |
| | | data: { "HInterID": InterID, "IsAudit": 0, "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); |
| | | //ä¿®æ¹ä¸ºååå·æ°çé¢ |
| | | window.location.reload(); |
| | | }); |
| | | |
| | | } else { |
| | | layer.alert(result.code + result.Message, { icon: 5 }); |
| | | } |
| | | }, error: function () { |
| | | layer.alert("æ¥å£è¯·æ±å¤±è´¥!", { icon: 5 }); |
| | | } |
| | | }); |
| | | |
| | | } |
| | | else { |
| | | layer.msg('è¯·éæ©ä¸è¡æ°æ®å®¡æ ¸ï¼'); |
| | | } |
| | | } |
| | | |
| | | //åå®¡æ ¸ |
| | | function set_DeAuditBill() { |
| | | 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_MouldLifeChangeBill/AuditSc_MouldLifeChangeBillList", //æ¹æ³æå¨é¡µé¢åæ¹æ³å |
| | | data: { "HInterID": InterID, "IsAudit": 1, "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); |
| | | //ä¿®æ¹ä¸ºååå·æ°çé¢ |
| | | window.location.reload(); |
| | | }); |
| | | |
| | | } else { |
| | | layer.alert(result.code + result.Message, { icon: 5 }); |
| | | } |
| | | }, error: function () { |
| | | layer.alert("æ¥å£è¯·æ±å¤±è´¥!", { icon: 5 }); |
| | | } |
| | | }); |
| | | |
| | | } |
| | | else { |
| | | layer.msg('è¯·éæ©ä¸è¡æ°æ®åå®¡æ ¸ï¼'); |
| | | } |
| | | } |
| | | |
| | | //éèå设置 |
| | | function get_HideColumn() { |
| | | var colName = ""; |