role-list.jsp 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149
  1. <%@page contentType="text/html;charset=UTF-8"%>
  2. <%@include file="/taglibs.jsp"%>
  3. <%pageContext.setAttribute("currentHeader", "auth");%>
  4. <%pageContext.setAttribute("currentMenu", "auth");%>
  5. <!doctype html>
  6. <html>
  7. <head>
  8. <%@include file="/common/meta.jsp"%>
  9. <title><spring:message code="auth.role.list.title" text="角色列表"/></title>
  10. <%@include file="/common/s.jsp"%>
  11. <script type="text/javascript">
  12. var config = {
  13. id: 'roleGrid',
  14. pageNo: ${page.pageNo},
  15. pageSize: ${page.pageSize},
  16. totalCount: ${page.totalCount},
  17. resultSize: ${page.resultSize},
  18. pageCount: ${page.pageCount},
  19. orderBy: '${page.orderBy == null ? "" : page.orderBy}',
  20. asc: ${page.asc},
  21. params: {
  22. 'filter_LIKES_name': '${param.filter_LIKES_name}'
  23. },
  24. selectedItemClass: 'selectedItem',
  25. gridFormId: 'roleGridForm',
  26. exportUrl: 'role-export.do'
  27. };
  28. var table;
  29. $(function() {
  30. table = new Table(config);
  31. table.configPagination('.m-pagination');
  32. table.configPageInfo('.m-page-info');
  33. table.configPageSize('.m-page-size');
  34. });
  35. </script>
  36. </head>
  37. <body>
  38. <%@include file="/header/auth.jsp"%>
  39. <div class="row-fluid">
  40. <%@include file="/menu/auth.jsp"%>
  41. <!-- start of main -->
  42. <section id="m-main" class="span10">
  43. <article class="m-widget">
  44. <header class="header">
  45. <h4 class="title">查询</h4>
  46. <div class="ctrl">
  47. <a class="btn"><i id="roleSearchIcon" class="icon-chevron-up"></i></a>
  48. </div>
  49. </header>
  50. <div id="roleSearch" class="content content-inner">
  51. <form name="roleForm" method="post" action="role-list.do" class="form-inline">
  52. <label for="role_name"><spring:message code='auth.role.list.search.name' text='名称'/>:</label>
  53. <input type="text" id="role_name" name="filter_LIKES_name" value="${param.filter_LIKES_name}">
  54. <button class="btn btn-small" onclick="document.permForm.submit()">查询</button>
  55. </form>
  56. </div>
  57. </article>
  58. <article class="m-blank">
  59. <div class="pull-left">
  60. <region:region-permission permission="role:create">
  61. <button class="btn btn-small a-insert" onclick="location.href='role-input.do'"><spring:message code="core.list.create" text="新建"/></button>
  62. </region:region-permission>
  63. <region:region-permission permission="role:delete">
  64. <button class="btn btn-small a-remove" onclick="table.removeAll()"><spring:message code="core.list.delete" text="删除"/></button>
  65. </region:region-permission>
  66. <button class="btn btn-small a-export" onclick="table.exportExcel()"><spring:message code="core.list.export" text="导出"/></button>
  67. </div>
  68. <div class="pull-right">
  69. 每页显示
  70. <select class="m-page-size">
  71. <option value="10">10</option>
  72. <option value="20">20</option>
  73. <option value="50">50</option>
  74. </select>
  75. </div>
  76. <div class="m-clear"></div>
  77. </article>
  78. <article class="m-widget">
  79. <header class="header">
  80. <h4 class="title"><spring:message code="auth.role.list.title" text="角色列表"/></h4>
  81. </header>
  82. <div class="content">
  83. <form id="roleGridForm" name="roleGridForm" method='post' action="role-remove.do" class="m-form-blank">
  84. <table id="roleGrid" class="m-table table-hover">
  85. <thead>
  86. <tr>
  87. <th width="10" class="m-table-check"><input type="checkbox" name="checkAll" onchange="toggleSelectedItems(this.checked)"></th>
  88. <th class="sorting" name="id"><spring:message code="auth.role.list.id" text="编号"/></th>
  89. <th class="sorting" name="name"><spring:message code="auth.role.list.name" text="名称"/></th>
  90. <th class="sorting" name="name">模板</th>
  91. <th width="150">&nbsp;</th>
  92. </tr>
  93. </thead>
  94. <tbody>
  95. <c:forEach items="${page.result}" var="item">
  96. <tr>
  97. <td><input type="checkbox" class="selectedItem a-check" name="selectedItem" value="${item.id}"></td>
  98. <td>${item.id}</td>
  99. <td>${item.name}</td>
  100. <td>${item.roleDef.scopeId}</td>
  101. <td>
  102. &nbsp;
  103. </td>
  104. </tr>
  105. </c:forEach>
  106. </tbody>
  107. </table>
  108. </form>
  109. </article>
  110. <article>
  111. <div class="m-page-info pull-left">
  112. 共100条记录 显示1到10条记录
  113. </div>
  114. <div class="btn-group m-pagination pull-right">
  115. <button class="btn btn-small">&lt;</button>
  116. <button class="btn btn-small">1</button>
  117. <button class="btn btn-small">&gt;</button>
  118. </div>
  119. <div class="m-clear"></div>
  120. </article>
  121. <div class="m-spacer"></div>
  122. </section>
  123. <!-- end of main -->
  124. </div>
  125. </body>
  126. </html>