You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

notice.tmpl 3.0KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. {{template "base/head" .}}
  2. <div role="main" aria-label="{{.Title}}" class="page-content admin notice">
  3. {{template "admin/navbar" .}}
  4. <div class="ui container">
  5. {{template "base/alert" .}}
  6. <h4 class="ui top attached header">
  7. {{.locale.Tr "admin.notices.system_notice_list"}} ({{.locale.Tr "admin.total" .Total}})
  8. </h4>
  9. <div class="ui attached table segment">
  10. <table id="notice-table" class="ui very basic select selectable table unstackable">
  11. <thead>
  12. <tr>
  13. <th></th>
  14. <th>ID</th>
  15. <th>{{.locale.Tr "admin.notices.type"}}</th>
  16. <th>{{.locale.Tr "admin.notices.desc"}}</th>
  17. <th width="100px">{{.locale.Tr "admin.users.created"}}</th>
  18. <th>{{.locale.Tr "admin.notices.op"}}</th>
  19. </tr>
  20. </thead>
  21. <tbody>
  22. {{range .Notices}}
  23. <tr>
  24. <td class="collapsing">
  25. <div class="ui fitted checkbox" data-id="{{.ID}}">
  26. <input type="checkbox"> <label></label>
  27. </div>
  28. </td>
  29. <td>{{.ID}}</td>
  30. <td>{{$.locale.Tr .TrStr}}</td>
  31. <td class="view-detail"><span class="notice-description text truncate">{{.Description}}</span></td>
  32. <td><span class="notice-created-time tooltip" data-content="{{.CreatedUnix.AsTime}}"><time data-format="short-date" datetime="{{.CreatedUnix.FormatLong}}">{{.CreatedUnix.FormatShort}}</time></span></td>
  33. <td><a href="#">{{svg "octicon-note" 16 "view-detail"}}</a></td>
  34. </tr>
  35. {{end}}
  36. </tbody>
  37. {{if .Notices}}
  38. <tfoot class="full-width">
  39. <tr>
  40. <th></th>
  41. <th colspan="5">
  42. <div class="ui right">
  43. <form method="post" action="{{AppSubUrl}}/admin/notices/empty">
  44. {{.CsrfTokenHtml}}
  45. <button type="submit" class="ui red small button">{{.locale.Tr "admin.notices.delete_all"}}</button>
  46. </form>
  47. </div>
  48. <div class="ui floating upward dropdown small button">
  49. <span class="text">{{.locale.Tr "admin.notices.operations"}}</span>
  50. <div class="menu">
  51. <div class="item select action" data-action="select-all">
  52. {{.locale.Tr "admin.notices.select_all"}}
  53. </div>
  54. <div class="item select action" data-action="deselect-all">
  55. {{.locale.Tr "admin.notices.deselect_all"}}
  56. </div>
  57. <div class="item select action" data-action="inverse">
  58. {{.locale.Tr "admin.notices.inverse_selection"}}
  59. </div>
  60. </div>
  61. </div>
  62. <div class="ui small teal button" id="delete-selection" data-link="{{.Link}}/delete" data-redirect="{{.Link}}?page={{.Page.Paginater.Current}}">
  63. {{.locale.Tr "admin.notices.delete_selected"}}
  64. </div>
  65. </th>
  66. </tr>
  67. </tfoot>
  68. {{end}}
  69. </table>
  70. </div>
  71. {{template "base/paginate" .}}
  72. </div>
  73. </div>
  74. <div class="ui modal admin" id="detail-modal">
  75. {{svg "octicon-x" 16 "close inside"}}
  76. <div class="header">{{$.locale.Tr "admin.notices.view_detail_header"}}</div>
  77. <div class="content">
  78. <div class="sub header"></div>
  79. <pre></pre>
  80. </div>
  81. </div>
  82. {{template "base/footer" .}}