37fcb2672b0963ba96e42387acdf6751c530d002.svn-base 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. <%@ page contentType="text/html; charset=UTF-8" language="java"%>
  2. <head>
  3. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
  4. <title>用户管理</title>
  5. <link type="text/css" rel="stylesheet" href="../../../scripts/easyui/themes/default/easyui.css"/>
  6. <link type="text/css" rel="stylesheet" href="../../../scripts/easyui/themes/icon.css"/>
  7. <script type="text/javascript" src="../../../scripts/jquery/jquery-1.11.1.js"></script>
  8. <script type="text/javascript" src="../../../scripts/easyui/jquery.easyui.min.js"></script>
  9. <script type="text/javascript" src="../../../scripts/easyui/locale/easyui-lang-zh_CN.js"></script>
  10. <script>
  11. var LocString=String(window.document.location.href);
  12. function GetQueryString(str){
  13. var rs=new RegExp("(^|)"+str+"=([^\&]*)(\&|$)","gi").exec(LocString),tmp;
  14. if(tmp=rs)return tmp[2];
  15. return "没有这个参数";
  16. }
  17. //alert("角色ID:"+GetQueryString("id"));
  18. // alert("角色类型:"+GetQueryString("roleType"));
  19. //alert("所在页数:"+GetQueryString("page"));
  20. function checkAllBox(obj,id){
  21. var answer= document.getElementsByName(id);
  22. if(obj.checked==true){
  23. for(var i=0;i<answer.length;i++){
  24. answer[i].checked = true;
  25. /* if(answer[i].checked){
  26. alert(answer[i].value+","+answer[i].nextSibling.nodeValue);
  27. } */
  28. }
  29. }else{
  30. for(var i=0;i<answer.length;i++){
  31. answer[i].checked = false;
  32. }
  33. }
  34. };
  35. /* function checkData(){
  36. var inputs = document.getElementsByTagName('input');//获取所有的input标签对象。
  37. for(var i=0;i<inputs.length;i++){
  38. var obj = inputs[i];
  39. if(obj.type=='checkbox'){
  40. if(obj.checked==true){
  41. sign=1;
  42. alert(obj.value);
  43. }
  44. }
  45. }
  46. } */
  47. function saveRoleButton() {
  48. $('#sysRoleButton_save_form').form('submit', {
  49. url : '/gzfw/ws/rolebutton/RoleService/saveRoleButton',
  50. onSubmit : function() {
  51. return $(this).form('validate');
  52. },
  53. success : function(result) {
  54. var result = eval('(' + result + ')');
  55. if (!result.success) {
  56. $.messager.show({
  57. title : 'Error',
  58. msg : result.success
  59. });
  60. } else {
  61. $('#cxdm').form('clear');
  62. //$datagrid.datagrid('reload'); // reload the user data
  63. }
  64. }
  65. });
  66. };
  67. </script>
  68. </head>
  69. <%
  70. String roleId = request.getParameter("id");
  71. String roleType = request.getParameter("roleType");
  72. %>
  73. <body>
  74. <table width="100%" height="500">
  75. <form id="sysRoleButton_save_form" method="post">
  76. <input type="hidden" id="roleId" name="roleId" value="<%=roleId%>"/>
  77. <input type="hidden" id="roleType" name="roleType" value="<%=roleType%>"/>
  78. <tr><td valign="top" class="sysmenu-button" align="right">
  79. <a href="javascript:void(0)" class="easyui-linkbutton" data-options="iconCls:'icon-save'" onclick="saveRoleButton()">保存</a>
  80. </td></tr>
  81. <tr><td valign="top">
  82. <table id="cxdm" title="按钮权限定义" class="easyui-treegrid" url="/gzfw/ws/rolebutton/RoleService/getRoleButtonList/<%=roleId %>"
  83. rownumbers="true" showFooter="true" idField="id" treeField="module_id" toolbar="#tb" fit="true"
  84. fitColumns="true">
  85. <thead>
  86. <tr>
  87. <th field="module_id">所属模块</th>
  88. <th field="id">功能点编号</th>
  89. <th field="name">功能点名称</th>
  90. <!-- <th field="caozuo"></th> -->
  91. <th field="button">已分配按钮</th>
  92. </tr>
  93. </thead>
  94. </table>
  95. </td></tr>
  96. </form>
  97. </table>
  98. </body>
  99. </html>