心理咨询网
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.

role.html 5.3KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. {include file='common/head.html'}
  2. <div class="layui-body">
  3. {if([$list])}
  4. <div class="layui-tab layui-tab-brief" lay-filter="tab">
  5. <ul class="layui-tab-title">
  6. <li class="layui-this" lay-id="t1">角色列表</li>
  7. <li lay-id="t2">角色新增</li>
  8. </ul>
  9. <div class="layui-tab-content">
  10. <div class="layui-tab-item layui-show">
  11. <table class="layui-table">
  12. <thead>
  13. <tr>
  14. <th>序号</th>
  15. <th>角色名称</th>
  16. <th>角色编码</th>
  17. <th>角色描述</th>
  18. <th>添加时间</th>
  19. <th>修改时间</th>
  20. <th>操作</th>
  21. </tr>
  22. </thead>
  23. <tbody>
  24. {foreach $roles(key,value,num)}
  25. <tr>
  26. <td>[num]</td>
  27. <td>[value->name]</td>
  28. <td>[value->rcode]</td>
  29. <td>[value->description]</td>
  30. <td>[value->create_time]</td>
  31. <td>[value->update_time]</td>
  32. <td>
  33. {if($value->id!=1)}
  34. {fun=get_btn_del($value->rcode,'rcode')}
  35. {/if}
  36. {fun=get_btn_mod($value->rcode,'rcode')}
  37. </td>
  38. </tr>
  39. {/foreach}
  40. </tbody>
  41. </table>
  42. <div class="page">{$pagebar}</div>
  43. </div>
  44. <div class="layui-tab-item">
  45. <form action="{url./admin/Role/add}" method="post" class="layui-form">
  46. <input type="hidden" name="formcheck" value="{$formcheck}" >
  47. <div class="layui-form-item">
  48. <label class="layui-form-label">角色名称</label>
  49. <div class="layui-input-block">
  50. <input type="text" name="name" required lay-verify="required" placeholder="请输入角色名称" class="layui-input">
  51. </div>
  52. </div>
  53. <div class="layui-form-item">
  54. <label class="layui-form-label">角色描述</label>
  55. <div class="layui-input-block">
  56. <input type="text" name="description" placeholder="请输入角色描述" class="layui-input">
  57. </div>
  58. </div>
  59. <div class="layui-form-item">
  60. <label class="layui-form-label">管辖区域</label>
  61. <div class="layui-input-block">
  62. {$area_checkbox}
  63. </div>
  64. </div>
  65. <div class="layui-form-item">
  66. <label class="layui-form-label">角色权限</label>
  67. <div class="layui-input-block" id="selectitem">
  68. {$menu_list}
  69. </div>
  70. </div>
  71. <div class="layui-form-item">
  72. <div class="layui-input-block">
  73. <button class="layui-btn" lay-submit>立即提交</button>
  74. <button type="reset" class="layui-btn layui-btn-primary">重置</button>
  75. </div>
  76. </div>
  77. </form>
  78. </div>
  79. </div>
  80. </div>
  81. {/if}
  82. {if([$mod])}
  83. <div class="layui-tab layui-tab-brief" lay-filter="tab">
  84. <ul class="layui-tab-title">
  85. <li class="layui-this">角色修改</li>
  86. </ul>
  87. <div class="layui-tab-content">
  88. <div class="layui-tab-item layui-show">
  89. <form action="{url./admin/Role/mod/rcode/'.[$get.rcode].'}{$backurl}" method="post" class="layui-form">
  90. <input type="hidden" name="formcheck" value="{$formcheck}" >
  91. <div class="layui-form-item">
  92. <label class="layui-form-label">角色名称</label>
  93. <div class="layui-input-block">
  94. <input type="text" name="name" required lay-verify="required" value="{$role->name}" placeholder="请输入角色名称" class="layui-input">
  95. </div>
  96. </div>
  97. <div class="layui-form-item">
  98. <label class="layui-form-label">角色描述</label>
  99. <div class="layui-input-block">
  100. <input type="text" name="description" value="{$role->description}" placeholder="请输入角色描述" class="layui-input">
  101. </div>
  102. </div>
  103. <div class="layui-form-item">
  104. <label class="layui-form-label">管辖区域</label>
  105. <div class="layui-input-block">
  106. {$area_checkbox}
  107. </div>
  108. </div>
  109. <div class="layui-form-item">
  110. <label class="layui-form-label">角色权限</label>
  111. <div class="layui-input-block" id="selectitem">
  112. {$menu_list}
  113. </div>
  114. </div>
  115. <div class="layui-form-item">
  116. <div class="layui-input-block">
  117. <button class="layui-btn" lay-submit>立即提交</button>
  118. <button type="reset" class="layui-btn layui-btn-primary">重置</button>
  119. {fun=get_btn_back()}
  120. </div>
  121. </div>
  122. </form>
  123. </div>
  124. </div>
  125. </div>
  126. {/if}
  127. </div>
  128. {include file='common/foot.html'}