⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 displayrole.jsp

📁 教师办公管理系统
💻 JSP
字号:
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html"%>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean"%>
<%@ page contentType="text/html;charset=GBK"%>
<%@ page import="java.util.*"%>
<%@ page import="to.model.Role.*"%>
<%@ page import="to.model.Login.*"%>
<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=GBK">
    <title>角色数据显示</title>
    <style type="text/css">
      table{font-size:13px}
      <!--
			a:link { text-decoration: none;color: black} 
			a:active { text-decoration:blink;} 
			
			a:hover {text-decoration: underline;position: relative; top: 3px; left: 3px; color: red}  
 			a:visited { text-decoration:none;color: black}   
			-->
    </style>
  </head>
  <body>
    <form>
      <table cellspacing="1" cellpadding="1" border="0" width="800" align="center">
         <%
          loginItem li=(loginItem)session.getAttribute("user");
          if(li==null)
          {
            response.sendRedirect("OfficeLogin.jsp");
          }
          if(!(li.getRoleName().equals("系统管理员")))
          {
            response.sendRedirect("Error2.jsp");
          }
        %>
        
        <tr>
          <td colspan="5" height="1"><hr/></td>
        </tr>
        <tr>
          <th colspan="4" align="center">已有角色列表</th>
          <td colspan="1" align="center" width="156"><font color="Red"><img src="image/arr.gif"/><a href="newRole.jsp"/>添加新角色</font></td>
        </tr>
        <tr bgcolor="#006699">
          <th width="121" align="center"><font color="White">角色编号</font></th>
          <th width="351" align="center"><font color="White">角色名称</font></th>
          <th width="351" align="center"><font color="White">权限集合</font></th>
          <th width="157" align="center"><font color="White">修改</font></th>
          <th width="156" align="center"><font color="White">删除</font></th>
        </tr>
        <%
          RoleBean rb=new RoleBean();
          Collection c=rb.selectAllRole();
          Iterator it=(Iterator)c.iterator();
          while(it.hasNext())
          {
            RoleItem ri=(RoleItem)it.next();
            %>
              <tr bgcolor="#ddddee">
                <td width="121" align="center"><%=ri.getRoleID()%></td>
                <td width="351" align="center"><%=ri.getRoleName()%></td>
                <td width="351" align="center"><%=ri.getRightName()%></td>
                <td width="157" align="center"><font color="Blue"><img src="image/arr.gif"/><a href="EditRoleAction.do?id=<%=ri.getRoleID()%>">修改</a></font></td>
                <td width="156" align="center"><font color="Blue"><img src="image/arr.gif"/><a href="DeleteRoleAction.do?id=<%=ri.getRoleID()%>">删除</a></font></td>
              </tr>
            <%
          }    
        %> 
        
        <tr>
          <td colspan="5" height="1"><hr/></td>
        </tr>
      </table>
    </form>
  </body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -