main.html 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323
  1. {{define "main"}}
  2. <!DOCTYPE html>
  3. <html lang="en">
  4. <head>
  5. <meta charset="utf-8">
  6. <meta name="viewport" content="width=device-width, initial-scale=1">
  7. <title>PrometheusAlert | 控制中心</title>
  8. <!-- Google Font: Source Sans Pro -->
  9. <link rel="stylesheet" href="https://fonts.font.im/css?family=Source+Sans+Pro:300,400,400i,700&display=fallback">
  10. <!-- Font Awesome -->
  11. <link rel="stylesheet" href="/static/plugins/fontawesome-free/css/all.min.css">
  12. <!-- DataTables -->
  13. <link rel="stylesheet" href="/static/plugins/datatables-bs4/css/dataTables.bootstrap4.min.css">
  14. <link rel="stylesheet" href="/static/plugins/datatables-responsive/css/responsive.bootstrap4.min.css">
  15. <link rel="stylesheet" href="/static/plugins/datatables-buttons/css/buttons.bootstrap4.min.css">
  16. <!-- flag-icon-css -->
  17. <link rel="stylesheet" href="/static/plugins/flag-icon-css/css/flag-icon.min.css">
  18. <!-- Theme style -->
  19. <link rel="stylesheet"href="/static/dist/css/adminlte.min.css">
  20. </head>
  21. <body class="hold-transition sidebar-mini">
  22. <!-- Site wrapper -->
  23. <div class="wrapper">
  24. <!-- Main Sidebar Container -->
  25. <aside class="main-sidebar sidebar-dark-primary elevation-4">
  26. <!-- Brand Logo -->
  27. <a href="/" class="brand-link">
  28. <img src="/static/dist/img/logo.png" alt="AdminLTE Logo" class="brand-image img-circle elevation-3" style="opacity: .8">
  29. <span class="brand-text font-weight-light">PrometheusAlert</span>
  30. </a>
  31. <!-- Sidebar -->
  32. <div class="sidebar">
  33. <!-- Sidebar Menu -->
  34. <nav class="mt-2">
  35. <ul class="nav nav-pills nav-sidebar flex-column" data-widget="treeview" role="menu" data-accordion="false">
  36. <!-- Add icons to the links using the .nav-icon class
  37. with font-awesome or any other icon font library -->
  38. <li class="nav-item">
  39. <a href="/" {{if .IsIndex}}class="nav-link active"{{else}}class="nav-link"{{end}}>
  40. <i class="nav-icon fas fa-tachometer-alt"></i>
  41. <p>
  42. Dashboard
  43. </p>
  44. </a>
  45. </li>
  46. <li {{if .IsTemplateMenu}}class="nav-item menu-open"{{else}}class="nav-item"{{end}}>
  47. <a href="#" {{if .IsTemplateMenu}}class="nav-link active"{{else}}class="nav-link"{{end}}>
  48. <i class="nav-icon fas fa-chart-pie"></i>
  49. <p>
  50. 模板管理
  51. <i class="right fas fa-angle-left"></i>
  52. </p>
  53. </a>
  54. <ul class="nav nav-treeview">
  55. <li class="nav-item">
  56. <a href="/template" {{if .IsTemplate}}class="nav-link active"{{else}}class="nav-link"{{end}}>
  57. <i class="fas fa-heart nav-icon"></i>
  58. <p>自定义模版</p>
  59. </a>
  60. </li>
  61. <li class="nav-item">
  62. <a href="/markdowntest" {{if .IsMarkDownTest}}class="nav-link active"{{else}}class="nav-link"{{end}}>
  63. <i class="far fa-image nav-icon"></i>
  64. <p>Markdown测试</p>
  65. </a>
  66. </li>
  67. </ul>
  68. </li>
  69. <li {{if .IsAlertManageMenu}}class="nav-item menu-open"{{else}}class="nav-item"{{end}}>
  70. <a href="#" {{if .IsAlertManageMenu}}class="nav-link active"{{else}}class="nav-link"{{end}}>
  71. <i class="nav-icon fa fa-bell"></i>
  72. <p>
  73. 告警管理
  74. <i class="fas fa-angle-left right"></i>
  75. </p>
  76. </a>
  77. <ul class="nav nav-treeview">
  78. <!--<li class="nav-item">
  79. <a href="silences" class="nav-link">
  80. <i class="far fa-circle nav-icon"></i>
  81. <p>告警拦截</p>
  82. </a>
  83. </li>-->
  84. <li class="nav-item">
  85. <a href="/alertrouter" {{if .IsAlertRouter}}class="nav-link active"{{else}}class="nav-link"{{end}}>
  86. <i class="fas fa-inbox nav-icon"></i>
  87. <p>告警路由</p>
  88. </a>
  89. </li>
  90. <li class="nav-item">
  91. <a href="/record" {{if .IsRecord}}class="nav-link active"{{else}}class="nav-link"{{end}}>
  92. <i class="fas fa-book nav-icon"></i>
  93. <p>告警记录查询</p>
  94. </a>
  95. </li>
  96. <li class="nav-item">
  97. <a href="/test" {{if .IsTest}}class="nav-link active"{{else}}class="nav-link"{{end}}>
  98. <i class="fas fa-bullhorn nav-icon"></i>
  99. <p>告警测试</p>
  100. </a>
  101. </li>
  102. </ul>
  103. </li>
  104. <!--<li class="nav-item">
  105. <a href="#" class="nav-link">
  106. <i class="nav-icon fas fa-edit"></i>
  107. <p>
  108. 系统默认参数设置
  109. <i class="fas fa-angle-left right"></i>
  110. </p>
  111. </a>
  112. <ul class="nav nav-treeview">
  113. <li class="nav-header">Webook</li>
  114. <li class="nav-item">
  115. <a href="/setup/weixin" class="nav-link">
  116. <i class="far fa-circle nav-icon"></i>
  117. <p>企业微信机器人</p>
  118. </a>
  119. </li>
  120. <li class="nav-item">
  121. <a href="/" class="nav-link">
  122. <i class="far fa-circle nav-icon"></i>
  123. <p>钉钉机器人</p>
  124. </a>
  125. </li>
  126. <li class="nav-item">
  127. <a href="/" class="nav-link">
  128. <i class="far fa-circle nav-icon"></i>
  129. <p>飞书机器人</p>
  130. </a>
  131. </li>
  132. <li class="nav-header">企业应用</li>
  133. <li class="nav-item">
  134. <a href="/" class="nav-link">
  135. <i class="far fa-circle nav-icon"></i>
  136. <p>企业微信应用</p>
  137. </a>
  138. </li>
  139. <li class="nav-item">
  140. <a href="/" class="nav-link">
  141. <i class="far fa-circle nav-icon"></i>
  142. <p>Telegram</p>
  143. </a>
  144. </li>
  145. <li class="nav-item">
  146. <a href="/" class="nav-link">
  147. <i class="far fa-circle nav-icon"></i>
  148. <p>百度Hi(如流)</p>
  149. </a>
  150. </li>
  151. <li class="nav-item">
  152. <a href="/" class="nav-link">
  153. <i class="far fa-circle nav-icon"></i>
  154. <p>Bark(iPhone推送)</p>
  155. </a>
  156. </li>
  157. <li class="nav-header">Email</li>
  158. <li class="nav-item">
  159. <a href="/" class="nav-link">
  160. <i class="far fa-circle nav-icon"></i>
  161. <p>Email</p>
  162. </a>
  163. </li>
  164. <li class="nav-header">短信</li>
  165. <li class="nav-item">
  166. <a href="/" class="nav-link">
  167. <i class="far fa-circle nav-icon"></i>
  168. <p>腾讯云短信</p>
  169. </a>
  170. </li>
  171. <li class="nav-item">
  172. <a href="/" class="nav-link">
  173. <i class="far fa-circle nav-icon"></i>
  174. <p>阿里云短信</p>
  175. </a>
  176. </li>
  177. <li class="nav-item">
  178. <a href="/" class="nav-link">
  179. <i class="far fa-circle nav-icon"></i>
  180. <p>华为云短信</p>
  181. </a>
  182. </li>
  183. <li class="nav-item">
  184. <a href="/" class="nav-link">
  185. <i class="far fa-circle nav-icon"></i>
  186. <p>百度云短信</p>
  187. </a>
  188. </li>
  189. <li class="nav-item">
  190. <a href="/" class="nav-link">
  191. <i class="far fa-circle nav-icon"></i>
  192. <p>七陌短信</p>
  193. </a>
  194. </li>
  195. <li class="nav-header">电话</li>
  196. <li class="nav-item">
  197. <a href="/" class="nav-link">
  198. <i class="far fa-circle nav-icon"></i>
  199. <p>腾讯云电话</p>
  200. </a>
  201. </li>
  202. <li class="nav-item">
  203. <a href="/" class="nav-link">
  204. <i class="far fa-circle nav-icon"></i>
  205. <p>阿里云语音电话</p>
  206. </a>
  207. </li>
  208. <li class="nav-item">
  209. <a href="/" class="nav-link">
  210. <i class="far fa-circle nav-icon"></i>
  211. <p>荣联云语音电话</p>
  212. </a>
  213. </li>
  214. <li class="nav-item">
  215. <a href="/" class="nav-link">
  216. <i class="far fa-circle nav-icon"></i>
  217. <p>七陌语音电话</p>
  218. </a>
  219. </li>
  220. </ul>
  221. </li>-->
  222. <li class="nav-item">
  223. <a href="https://github.com/feiyu563/PrometheusAlert/issues" class="nav-link">
  224. <i class="nav-icon far fa-envelope"></i>
  225. <p>
  226. 帮助
  227. <span class="right badge badge-danger">New</span>
  228. </p>
  229. </a>
  230. </li>
  231. </ul>
  232. </nav>
  233. <!-- /.sidebar-menu -->
  234. </div>
  235. <!-- /.sidebar -->
  236. </aside>
  237. {{end}}
  238. {{define "endhtml"}}
  239. <footer class="main-footer">
  240. <div class="float-right d-none d-sm-block">
  241. <b>Version</b> 4.8.0
  242. </div>
  243. <strong>PrometheusAlert <a href="https://github.com/feiyu563/PrometheusAlert">Github</a> && <a href="https://gitee.com/feiyu563/PrometheusAlert">Gitee</a> </strong>
  244. </footer>
  245. <!-- Control Sidebar -->
  246. <aside class="control-sidebar control-sidebar-dark">
  247. <!-- Control sidebar content goes here -->
  248. </aside>
  249. <!-- /.control-sidebar -->
  250. </div>
  251. <!-- ./wrapper -->
  252. <!-- jQuery -->
  253. <script src="/static/plugins/jquery/jquery.min.js"></script>
  254. <!-- Bootstrap 4 -->
  255. <script src="/static/plugins/bootstrap/js/bootstrap.bundle.min.js"></script>
  256. <!-- AdminLTE App -->
  257. <script src="/static/dist/js/adminlte.min.js"></script>
  258. <script src="/static/dist/js/marked.min.js"></script>
  259. <!-- ChartJS -->
  260. <script src="/static/plugins/chart.js/Chart.min.js"></script>
  261. <!-- DataTables & Plugins -->
  262. <script src="/static/plugins/datatables/jquery.dataTables.min.js"></script>
  263. <script src="/static/plugins/datatables-bs4/js/dataTables.bootstrap4.min.js"></script>
  264. <script src="/static/plugins/datatables-responsive/js/dataTables.responsive.min.js"></script>
  265. <script src="/static/plugins/datatables-responsive/js/responsive.bootstrap4.min.js"></script>
  266. <script src="/static/plugins/datatables-buttons/js/dataTables.buttons.min.js"></script>
  267. <script src="/static/plugins/datatables-buttons/js/buttons.bootstrap4.min.js"></script>
  268. <script src="/static/plugins/jszip/jszip.min.js"></script>
  269. <script src="/static/plugins/pdfmake/pdfmake.min.js"></script>
  270. <script src="/static/plugins/pdfmake/vfs_fonts.js"></script>
  271. <script src="/static/plugins/datatables-buttons/js/buttons.html5.min.js"></script>
  272. <script src="/static/plugins/datatables-buttons/js/buttons.print.min.js"></script>
  273. <script src="/static/plugins/datatables-buttons/js/buttons.colVis.min.js"></script>
  274. {{end}}
  275. {{define "jshtml"}}
  276. </body>
  277. </html>
  278. {{end}}