salary.html 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. <!DOCTYPE html>
  2. <html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
  3. <head>
  4. <th:block th:include="include :: header('工资列表')" />
  5. </head>
  6. <body class="gray-bg">
  7. <div class="container-div">
  8. <div class="row">
  9. <div class="col-sm-12 search-collapse">
  10. <form id="formId">
  11. <div class="select-list">
  12. <ul>
  13. <li>
  14. <label>用户:</label>
  15. <input type="text" name="userId"/>
  16. </li>
  17. <li class="select-time">
  18. <label>工资日期:</label>
  19. <input type="text" class="time-input" id="startTime" placeholder="开始时间" name="params[beginSalaryDate]"/>
  20. <span>-</span>
  21. <input type="text" class="time-input" id="endTime" placeholder="结束时间" name="params[endSalaryDate]"/>
  22. </li>
  23. <li>
  24. <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
  25. <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
  26. </li>
  27. </ul>
  28. </div>
  29. </form>
  30. </div>
  31. <div class="btn-group-sm" id="toolbar" role="group">
  32. <a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="business:salary:add">
  33. <i class="fa fa-plus"></i> 添加
  34. </a>
  35. <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="business:salary:edit">
  36. <i class="fa fa-edit"></i> 修改
  37. </a>
  38. <a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="business:salary:remove">
  39. <i class="fa fa-remove"></i> 删除
  40. </a>
  41. <a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="business:salary:export">
  42. <i class="fa fa-download"></i> 导出
  43. </a>
  44. </div>
  45. <div class="col-sm-12 select-table table-striped">
  46. <table id="bootstrap-table"></table>
  47. </div>
  48. </div>
  49. </div>
  50. <th:block th:include="include :: footer" />
  51. <script th:inline="javascript">
  52. var editFlag = [[${@permission.hasPermi('business:salary:edit')}]];
  53. var removeFlag = [[${@permission.hasPermi('business:salary:remove')}]];
  54. var prefix = ctx + "business/salary";
  55. $(function() {
  56. var options = {
  57. url: prefix + "/list",
  58. createUrl: prefix + "/add",
  59. updateUrl: prefix + "/edit/{id}",
  60. removeUrl: prefix + "/remove",
  61. exportUrl: prefix + "/export",
  62. modalName: "工资",
  63. columns: [{
  64. checkbox: true
  65. },
  66. {
  67. field: 'salaryId',
  68. title: '主键',
  69. visible: false
  70. },
  71. {
  72. field: 'userId',
  73. title: '用户'
  74. },
  75. {
  76. field: 'userName',
  77. title: '用户名称'
  78. },
  79. {
  80. field: 'salaryDate',
  81. title: '日期'
  82. },
  83. {
  84. field: 'sumAmount',
  85. title: '总金额'
  86. },
  87. {
  88. title: '操作',
  89. align: 'center',
  90. formatter: function(value, row, index) {
  91. var actions = [];
  92. actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.salaryId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
  93. actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.salaryId + '\')"><i class="fa fa-remove"></i>删除</a>');
  94. return actions.join('');
  95. }
  96. }]
  97. };
  98. $.table.init(options);
  99. });
  100. </script>
  101. </body>
  102. </html>