Merge branch 'master-500-dev-xwx' into 'master-500-dev'
资源视图监控状态未监控时健康状态不展示 See merge request !482
Showing
2 changed files
with
11 additions
and
2 deletions
@@ -1290,6 +1290,17 @@ layui.define(['xmSelect', 'md5'], function (exports) { | @@ -1290,6 +1290,17 @@ layui.define(['xmSelect', 'md5'], function (exports) { | ||
1290 | param = "=" + encodeURIComponent(layHref.split('=')[1]); | 1290 | param = "=" + encodeURIComponent(layHref.split('=')[1]); |
1291 | } | 1291 | } |
1292 | alink.setAttribute("lay-href",layHref.split('=')[0] + param); | 1292 | alink.setAttribute("lay-href",layHref.split('=')[0] + param); |
1293 | + document.body.appendChild(alink); | ||
1294 | + alink.click(); | ||
1295 | + document.body.removeChild(alink); | ||
1296 | + }, | ||
1297 | + openMxgraph: function (layHref) { | ||
1298 | + var alink = document.createElement('a'); | ||
1299 | + var param = ''; | ||
1300 | + if (layHref.indexOf('=') !== -1) { | ||
1301 | + param = "=" + encodeURIComponent(layHref.split('=')[1]); | ||
1302 | + } | ||
1303 | + alink.setAttribute("lay-href",layHref.split('=')[0] + param); | ||
1293 | admin.req({ | 1304 | admin.req({ |
1294 | url: obj.domainName + '/api-web/mxgraph/getJtopoInfoById/'+layHref.split('=')[2], | 1305 | url: obj.domainName + '/api-web/mxgraph/getJtopoInfoById/'+layHref.split('=')[2], |
1295 | success(response) { | 1306 | success(response) { |
@@ -846,7 +846,6 @@ | @@ -846,7 +846,6 @@ | ||
846 | </script> | 846 | </script> |
847 | <!--健康状态--> | 847 | <!--健康状态--> |
848 | <script type="text/html" id="healthTpl"> | 848 | <script type="text/html" id="healthTpl"> |
849 | - {{# if(d.state != 'new'){ }} | ||
850 | {{# if(d.health === '1'){ }} | 849 | {{# if(d.health === '1'){ }} |
851 | <button type="button" class="layui-btn layui-btn-danger layui-bg-red layui-btn-radius layui-btn-xs p-0-15 cant-click">中 | 850 | <button type="button" class="layui-btn layui-btn-danger layui-bg-red layui-btn-radius layui-btn-xs p-0-15 cant-click">中 |
852 | </button> | 851 | </button> |
@@ -858,7 +857,6 @@ | @@ -858,7 +857,6 @@ | ||
858 | {{# if(d.health === '3'){ }} | 857 | {{# if(d.health === '3'){ }} |
859 | <button type="button" class="layui-btn layui-btn-radius layui-bg-green layui-btn-xs p-0-15 cant-click">优</button> | 858 | <button type="button" class="layui-btn layui-btn-radius layui-bg-green layui-btn-xs p-0-15 cant-click">优</button> |
860 | {{# } }} | 859 | {{# } }} |
861 | - {{# } }} | ||
862 | </script> | 860 | </script> |
863 | <!--主机状态--> | 861 | <!--主机状态--> |
864 | <script type="text/html" id="hostStateTpl"> | 862 | <script type="text/html" id="hostStateTpl"> |
-
Please register or login to post a comment