RoleManage.jsp
上传用户:mingda
上传日期:2017-06-20
资源大小:27691k
文件大小:6k
源码类别:

OA系统

开发平台:

Java

  1. <%@ page contentType="text/html; charset=gb2312"%>
  2. <%@ page import="com.gforce.gfoa.*,com.gforce.currency.*,java.util.*" %>
  3. <jsp:include page="/CheckLogin.jsp" flush="true"/> <% Session m_session = new Session(session); %>
  4. <%
  5. Vector vt = RoleManager.getAllRecord();
  6. %>
  7. <html>
  8. <head>
  9. <meta http-equiv="Content-Type" content="text/html; charset=gb2312"><meta http-equiv="pragma" content="no-cache">
  10. <title>角色管理-- GForce OA 2.0</title>
  11. <link href="../css/txt.jsp" rel="stylesheet" type="text/css">
  12. <script language="JavaScript" src="/js/changestyle.js"></script>
  13. <script language="JavaScript" type="text/javascript">
  14. function checkaddrole()
  15. {
  16.     if(document.addrole.RoleName.value=='')
  17.     {
  18.         alert("请输入角色名称!");
  19.         document.addrole.RoleName.focus();
  20.         return false;
  21.     }
  22. }
  23. </script>
  24. </head>
  25. <body bgcolor="<%=m_session.GetString("BackColor")%>" leftmargin="0" topmargin="0">
  26.    <table width="100%" height="100%" border="0" align="center" cellspacing="0">
  27.     <tr>
  28.     <td align="center" valign="top">
  29.       <table width="100%" border="0" cellpadding="0" cellspacing="0">
  30.         <tr>
  31.           <td height="50" valign="top" background="../images/dy-back.gif">
  32.             <table width="100%" border="0" cellpadding="0" cellspacing="0">
  33.               <tr valign="middle">
  34.                 <td width="61" align="center" height="20"><img src="../images/dy-01.gif" width="38" height="36"></td>
  35.                 <td width="118" nowrap="nowrap" valign="middle"><strong><font color="#000000">角色管理</font></strong></td>
  36.                 <td align="right" nowrap="nowrap" valign="bottom">&nbsp;
  37.                    <!-- 群增<img src="../images/MulAdd.gif" onMouseOver="this.src='../images/MulAdd_a.gif';" onMouseOut="this.src='../images/MulAdd.gif';" border="0" height="22" width="59">&nbsp;-->
  38.                   <!--单增<img src="../images/Single.gif" onMouseOver="this.src='../images/Single_a.gif';" onMouseOut="this.src='../images/Single.gif';" border="0" height="22" width="59">&nbsp;-->
  39.                   <!-- 修改<img src="../images/Update.gif" onMouseOver="this.src='../images/Update_a.gif';" onMouseOut="this.src='../images/Update.gif';" border="0" height="22" width="59">&nbsp;-->
  40.                   <!-- 删除<img src="../images/Del.gif" onMouseOver="this.src='../images/Del_a.gif';" onMouseOut="this.src='../images/Del.gif';" border="0" height="22" width="59">&nbsp;-->
  41.                   <!-- 查看<img src="../images/Query.gif" onMouseOver="this.src='../images/Query_a.gif';" onMouseOut="this.src='../images/Query.gif';" border="0" height="22" width="59">&nbsp;-->
  42.                   <!-- 组合查询<img src="../images/GroupQuery.gif" onMouseOver="this.src='../images/GroupQuery_a.gif';" onMouseOut="this.src='../images/GroupQuery.gif';" border="0" height="22" width="79">&nbsp;-->
  43.                 </td>
  44.               </tr>
  45.             </table>
  46.           </td>
  47.         </tr>
  48.       </table>
  49. <table width="100%" height="100%" border="0" align="center" cellspacing="0">
  50.     <tr>
  51.         <td align="center" valign="top"><p>&nbsp;</p>
  52.             <table width="90%" border="1" cellpadding="3" cellspacing="0" bordercolordark="#ffffff" bordercolorlight="#0a0a0a" style="">
  53.                 <tr align="center" valign="middle" bgcolor="<%=m_session.GetString("TitleColor")%>">
  54.                     <th width="6%" height="24" nowrap><img src="/images/white.gif" width="12"></th>
  55.                     <th width="8%" nowrap><font color="#000000">序号</font></th>
  56.                     <th width="55%" nowrap><font color="#000000">角色名称</font></th>
  57.                     <th width="11%" nowrap><font color="#000000">添加</font></th>
  58.                     <th width="11%" nowrap><font color="#000000">修改</font></th>
  59.                     <th width="12%" nowrap><font color="#000000">删除</font></th>
  60.                 </tr>
  61.                 <%
  62. for(int i=0;i<vt.size();i++)
  63. {
  64.     String strID = ((Vector)vt.get(i)).get(0).toString();
  65.     if(i % 2 == 0)
  66.         out.println("<tr id="Row"+ i+ "" class="DataRowsSingle" onmouseover="mouseon(this,'image" + i + "');" onmouseout="mouseout(this,'image" + i + "','DataRowsSingle');">");
  67.     else
  68.         out.println("<tr id="Row"+ i+ "" class="DataRowsDouble" onmouseover="mouseon(this,'image" + i + "');" onmouseout="mouseout(this,'image" + i + "','DataRowsDouble');">");
  69.     out.println("<td align="right" valign="middle"><img id="image" + i + "" src="../images/lastpost1.gif" style="display:none;"> </td>");
  70.     out.println("<td align="right" valign="middle">" + (i+1) + "</td>");
  71.     out.println("<td align="left" valign="middle" nowrap onclick="openeditwindow('ChangeRoleRight.jsp?RoleID=" + strID + "')" title="在此单击查看、修改该角色权限">" + ((Vector)vt.get(i)).get(1).toString() + "</td>");
  72.     out.println("<td align="center" valign="middle" nowrap>&nbsp;</td>");
  73.     out.println("<td align="center" valign="middle" nowrap><a href="EditRole.jsp?ID=" + strID + "">修改</a></td>");
  74.     out.println("<td align="center" valign="middle" nowrap><a href="DelRole.jsp?ID=" + strID + "" onclick="return confirm('您确实要删除该角色吗?\n删除该角色之前必须删除该角色的所用户和该角色的所有相关权限,\n否则会出错,您是否继续?');">删除</a></td>");
  75.     out.println("</tr>");
  76. }
  77. %>
  78.                 <form name="addrole" action="AddRoleAction.jsp" method="post" onSubmit="javascript:return checkaddrole();">
  79.                     <tr bgcolor="<%=m_session.GetString("TitleColor")%>">
  80.                         <th align="right" valign="middle" bgcolor="<%=m_session.GetString("TitleColor")%>">&nbsp;</th>
  81.                         <th align="right" valign="middle" bgcolor="<%=m_session.GetString("TitleColor")%>">&nbsp;</th>
  82.                         <th align="left" valign="middle" nowrap bgcolor="<%=m_session.GetString("TitleColor")%>">
  83.                             <input name="RoleName" type="text" maxlength="20"></th>
  84.                         <th align="center" valign="middle" nowrap bgcolor="<%=m_session.GetString("TitleColor")%>">
  85.                             <input type="submit" value="添加"></th>
  86.                         <th align="center" valign="middle" nowrap bgcolor="<%=m_session.GetString("TitleColor")%>">&nbsp;</th>
  87.                         <th align="center" valign="middle" nowrap bgcolor="<%=m_session.GetString("TitleColor")%>">&nbsp;</th>
  88.                     </tr>
  89.                 </form>
  90.             </table>
  91.         </td>
  92.     </tr>
  93. </table>
  94. </body>
  95. </html>