index.html 3.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. <!--#include file="/inc/header.html"-->
  2. <script type="text/javascript">
  3. window.renderHeader=function(e)
  4. {
  5. var template="{{#childenList}}<li class=\"bif-nav-item\" data-type=\"{{moduleType}}\" data-url=\"{{moduleUrl}}\">{{moduleName}}</li>{{/childenList}}";
  6. var views = Mustache.render(template, e);
  7. $("#bif-nav-ul").html(views);
  8. $(".tree-breadcrumb #nav-item-a").html($("#bif-nav-ul li:first-child").html());
  9. $("#bif-nav-ul li:first-child").addClass("active");
  10. tabSelect.smartAmmeterTree(e.childenList);
  11. };
  12. $(function(){
  13. var modules=JSON.parse(window.sessionStorage.getItem("modules"));
  14. if(window.treemap){
  15. renderHeader(window.treemap[15]);//器材设备管理ID 10
  16. }else if(modules){
  17. renderHeader(modules.treemap[15]);
  18. }
  19. base.ajaxFunc('get', '/grain/ammeter/promptBoxInfo', {}, function(e){
  20. if( e.data ) {
  21. var msg = "",
  22. flag = true;
  23. for( var i in e.data ) {
  24. msg += e.data[i] + '<br />';
  25. flag = false;
  26. }
  27. if( flag ) return;
  28. var $html = $('<div class="PromptDiv"><div class="PromptDiv-title"><span class="close-span">×</span>提示消息</div><div class="PromptDiv-content">' + msg + '</div></div>');
  29. $('body').append($html);
  30. $html.slideDown(600);
  31. $('.close-span').off().on('click',function(e){
  32. e.preventDefault();
  33. $html.slideUp(600);
  34. })
  35. }
  36. })
  37. })
  38. </script>
  39. <div class="con-wrap">
  40. <div class="tree-breadcrumb">
  41. <span class="nav-prov">首页</span>&gt;
  42. <span class="nav-prov"><a href="/pages/smartAmmeter/index.html">智能电表</a></span>&gt;
  43. <span class="nav-item"><a href="javascript:;" id="nav-item-a"></a></span>
  44. </div>
  45. <div class="bif-nav">
  46. <ul id="bif-nav-ul">
  47. </ul>
  48. </div>
  49. <div id="con-main">
  50. <div id="con-map" class="main3">
  51. <div class="bif-container">
  52. <div class="author-nav-tree">
  53. <ul id="tree-tt" style="height:500px;">
  54. </ul>
  55. </div>
  56. <div id="smartMain" class="bif-con panel-noscroll" style="height: auto;">
  57. </div>
  58. </div>
  59. </div>
  60. </div>
  61. </div>
  62. <!--#include file="/inc/footer.html"-->
  63. <style>
  64. .author-nav-tree {
  65. display: inline-block;
  66. width: 200px;
  67. min-height: 400px;
  68. border: 1px solid lightgrey;
  69. float: left;
  70. overflow-x: hidden;
  71. overflow-y: auto;
  72. margin-top: 10px;
  73. }
  74. #con-map {
  75. min-height: 400px;
  76. display: inline-block;
  77. margin-top: 10px;
  78. }
  79. .bif-con {
  80. width: 980px;
  81. height: 404px;
  82. margin-top: 10px;
  83. margin-left: 14px;
  84. float: left;
  85. }
  86. .bif-nav-item{
  87. width: 150px;
  88. text-align: center;
  89. }
  90. </style>
  91. <script type="text/javascript" src="/src/lib/highcharts.js"></script>
  92. <script type="text/javascript" src="/src/sub/smartAmmeter.js"></script>
  93. <script type="text/javascript" src="/src/sub/print.js"></script>
  94. </body>
  95. </html>