/*子页面*/ function openIframe(id, title, content, width, height) { let layerIndex = layer.open({ id: id, type: 2, title: ['
' + title + '
', 'font-size:16px;background-color:#f0f0f0;display: flex;align-items: center;'], content: content, shade: 0.3, shadeClose: false, area: [width, height], move: false, success: function () { let iframeWin = window["layui-layer-iframe" + layerIndex]; } }); } /*新增页面*/ function openIframe2(id, title, content, width, height, params) { let layerIndex = layer.open({ id: id, type: 2, title: ['
' + title + '
', 'font-size:16px;background-color:#f0f0f0;display: flex;align-items: center;'], content: content, shade: 0.3, shadeClose: false, area: [width, height], move: false, success: function () { let iframeWin = window["layui-layer-iframe" + layerIndex]; console.log(params) iframeWin.setParams(JSON.stringify(params)); }, cancel:function () { // 视频监控-历史回放关闭前回调 if(params.videoMonitor){ let iframeWin = window["layui-layer-iframe" + layerIndex]; iframeWin.clickLogout(); } } }); } function openIframe3(id, title, content, width, height, params) { let layerIndex = layer.open({ id: id, type: 2, title: ['
' + title + '
', 'font-size:16px;background-color:#f0f0f0;display: flex;align-items: center;'], content: content, shade: 0.3, closeBtn: true, shadeClose: false, area: [width, height], move: false, success: function () { let iframeWin = window["layui-layer-iframe" + layerIndex]; iframeWin.setParams(JSON.stringify(params)); }, end:function (){ if(id === 'auditData'){ window.reloadData(); } } }); } function openIframe7(id, title, content, width, height, params) { let layerIndex = parent.layer.open({ id: id, type: 2, title: ['
' + title + '
', 'font-size:16px;background-color:#f0f0f0;display: flex;align-items: center;'], content: content, shade: 0.3, closeBtn: true, shadeClose: false, area: [width, height], move: false, success: function () { let iframeWin = parent.window["layui-layer-iframe" + layerIndex]; iframeWin.setParams(JSON.stringify(params)); }, }); } // 楼宇管理区域 新增/修改页面 function openIframe4(id, title, content, width, height, params,$div) { let layerIndex = layer.open({ id: id, type: 2, title: ['
' + title + '
', 'font-size:16px;background-color:#f0f0f0;display: flex;align-items: center;'], content: content, shade: 0.3, shadeClose: false, area: [width, height], move: false, success: function () { let iframeWin = window["layui-layer-iframe" + layerIndex]; console.log(params) iframeWin.setParams(JSON.stringify(params)); }, end:function () { if(jsonData){ if(params.id){ // 修改节点 areaTree.partialRefreshEdit($div, jsonData.title); }else{ // 新增节点 areaTree.partialRefreshAdd($div, jsonData); } jsonData = null; } } }); } function openIframe5(id, title, content, width, height, params) { let layerIndex = layer.open({ id: id, type: 1, title: ['
' + title + '
', 'font-size:16px;background-color:#f0f0f0;display: flex;align-items: center;'], content: content, shade: 0.3, closeBtn: 1, shadeClose: false, area: [width, height], move: false, success: function () { $('input[name="auth"][value="'+params.areaAuth+'"]').prop('checked',true) // let iframeWin = window["layui-layer-iframe" + layerIndex]; // iframeWin.setParams(JSON.stringify(params)); layui.form.render(); } }); } function openIframe6(id, title, content, width, height, params) { let layerIndex = parent.layer.open({ id: id, type: 2, title: ['
' + title + '
', 'font-size:16px;background-color:#f0f0f0;display: flex;align-items: center;'], content: content, shade: 0.3, shadeClose: false, area: [width, height], move: false, success: function () { let iframeWin = parent.window["layui-layer-iframe" + layerIndex]; iframeWin.setParams(JSON.stringify(params)); }, }); } /*新增页面*/ function openIframeMax(id, title, content, width, height, params) { let layerIndex = layer.open({ id: id, type: 2, title: ['
' + title + '
', 'font-size:16px;background-color:#f0f0f0;display: flex;align-items: center;'], content: content, shade: 0.3, shadeClose: false, area: [width, height], maxmin: true, move: false, success: function () { let iframeWin = window["layui-layer-iframe" + layerIndex]; // console.log(params) iframeWin.setParams(JSON.stringify(params)); }, cancel:function () { // 视频监控-历史回放关闭前回调 if(params.videoMonitor){ let iframeWin = window["layui-layer-iframe" + layerIndex]; iframeWin.clickLogout(); } } }); // console.log(layer) // layer.max(layerIndex) // 弹窗打开后立即调用 layer.full // layer.full(layerIndex); } //关闭后刷新页面 function openIframeMaxRefresh(id, title, content, width, height, params) { let layerIndex = layer.open({ id: id, type: 2, title: ['
' + title + '
', 'font-size:16px;background-color:#f0f0f0;display: flex;align-items: center;'], content: content, shade: 0.3, shadeClose: false, area: [width, height], maxmin: true, move: false, success: function () { let iframeWin = window["layui-layer-iframe" + layerIndex]; // console.log(params) iframeWin.setParams(JSON.stringify(params)); }, cancel:function () { // 视频监控-历史回放关闭前回调 if(params.videoMonitor){ let iframeWin = window["layui-layer-iframe" + layerIndex]; iframeWin.clickLogout(); } },end:function () { reloadData() } }); // console.log(layer) // layer.max(layerIndex) // 弹窗打开后立即调用 layer.full // layer.full(layerIndex); }