archive_study_list.jsp
上传用户:jhtang88
上传日期:2014-01-27
资源大小:28528k
文件大小:5k
源码类别:

Jsp/Servlet

开发平台:

Java

  1. <%@ page contentType="text/html; charset=utf-8"%>
  2. <%@ page import = "java.util.*"%>
  3. <%@ page import = "cn.js.fan.db.*"%>
  4. <%@ page import = "cn.js.fan.web.*"%>
  5. <%@ page import = "cn.js.fan.util.*"%>
  6. <%@ page import = "com.redmoon.oa.archive.*"%>
  7. <%@ page import = "com.redmoon.oa.person.*"%>
  8. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
  9. <html>
  10. <head>
  11. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  12. <title>人事档案管理</title>
  13. <link href="../common.css" rel="stylesheet" type="text/css">
  14. <%@ include file="../inc/nocache.jsp"%>
  15. <style type="text/css">
  16. <!--
  17. .STYLE2 {color: #0033FF}
  18. .STYLE3 {color: #FF0000}
  19. -->
  20. </style>
  21. </head>
  22. <body background="" leftmargin="0" topmargin="5" marginwidth="0" marginheight="0">
  23. <jsp:useBean id="privilege" scope="page" class="com.redmoon.oa.pvg.Privilege"/>
  24. <jsp:useBean id="archivePrivilege" scope="page" class="com.redmoon.oa.archive.ArchivePrivilege"/>
  25. <% 
  26. String userName = ParamUtil.get(request,"userName");
  27. if (!privilege.isUserPrivValid(request, "archive.study")||!archivePrivilege.canAdminUser(request,userName)) {
  28. out.print(StrUtil.Alert_Back(SkinUtil.LoadString(request, "pvg_invalid")));
  29. return;
  30. }
  31. %>
  32. <%@ include file="archive_inc_menu_top.jsp"%>
  33. <br>
  34. <table border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" class="main">
  35.   <tr> 
  36.     <td width="840" height="23" valign="middle" class="right-title"><span>&nbsp;教育信息管理</span></td>
  37.   </tr>
  38.   <tr> 
  39.     <td valign="top" background="images/tab-b-back.gif">
  40. <%
  41. String sql = "",isJob = "",userRealName = "";
  42. if(userName.equals("")){
  43. sql = ArchiveSQLBuilder.getUserStudy();
  44. }else{
  45. sql = ArchiveSQLBuilder.getUserStudy(userName);
  46. }
  47. String querystr = "";
  48. int pagesize = 10;
  49. Paginator paginator = new Paginator(request);
  50. int curpage = paginator.getCurPage();
  51. UserStudyDb usd = new UserStudyDb();
  52. ListResult lr = usd.listResult(sql, curpage, pagesize);
  53. int total = lr.getTotal();
  54. Vector v = lr.getResult();
  55.     Iterator ir = null;
  56. if (v!=null)
  57. ir = v.iterator();
  58. paginator.init(total, pagesize);
  59. // 设置当前页数和总页数
  60. int totalpages = paginator.getTotalPages();
  61. if (totalpages==0)
  62. {
  63. curpage = 1;
  64. totalpages = 1;
  65. }
  66. %>
  67.       <table width="95%" border="0" align="center" cellpadding="0" cellspacing="0">
  68.         <tr> 
  69.           <td width="47">&nbsp;</td>
  70.           <td align="right" backgroun="images/title1-back.gif">找到符合条件的记录 <b><%=paginator.getTotal() %></b> 条 每页显示 <b><%=paginator.getPageSize() %></b> 条 页次 <b><%=curpage %>/<%=totalpages %></td>
  71.         </tr>
  72.       </table>
  73.   <form name="form1" action="archive_study_add.jsp" method="post">
  74.     <table width="97%" border="0" align="center" cellpadding="2" cellspacing="0" >
  75.           <tr align="center" bgcolor="#C4DAFF">
  76.             <td width="19%" height="24" >用户名</td>
  77.             <td width="15%" bgcolor="#C4DAFF" >学历</td>
  78.             <td width="16%" bgcolor="#C4DAFF" >毕业院校</td>
  79.             <td width="14%" >开始时间</td>
  80.             <td width="12%" >结束时间</td>
  81.             <td width="24%" >结束时间</td>
  82.           </tr>
  83.         </table>
  84.     <%
  85.    int i = 0;
  86. UserInfoDb uid = new UserInfoDb();
  87. while (ir!=null && ir.hasNext()) {
  88. usd = (UserStudyDb)ir.next();
  89. uid = uid.getUserInfoDb(usd.getUserName());
  90. userRealName = uid.getUserRealName();
  91. %>
  92.       <table width="97%" border="0" align="center" cellpadding="0" cellspacing="0" bordercolor="#B6CFC5" bgcolor="#FFFFFF">
  93.         <tr align="center" >
  94.           <td width="19%" height="22"><%=userRealName%></td> 
  95.           <td width="15%"><%=usd.getGrade()%></td>
  96.   <td width="16%"><%=usd.getCollege()%></td>
  97.   <td width="14%"><%=DateUtil.format(usd.getBeginDate(),"yyyy-MM-dd")%></td>
  98.   <td width="12%"><%=DateUtil.format(usd.getEndDate(),"yyyy-MM-dd")%></td>
  99.           <td width="12%"><a href="archive_study_modify.jsp?id=<%=usd.getId()%>&userName=<%=StrUtil.UrlEncode(userName)%>">编辑</a></td>
  100.   <td width="12%"><a href="archive_study_do.jsp?id=<%=usd.getId()%>&userName=<%=StrUtil.UrlEncode(userName)%>&op=del">删除</a></td>
  101.         </tr>
  102.       </table>
  103.       <%}%>
  104.   <input type="hidden" name="userName" value="<%=userName%>"> 
  105.   </form> 
  106.       <table width="98%" border="0" cellspacing="1" cellpadding="3" align="center" class="9black">
  107.         <tr> 
  108.           <td width="1%" height="23">&nbsp;</td>
  109.           <td height="23" valign="baseline"> 
  110.             <div align="right">
  111.              <%
  112.    out.print(paginator.getCurPageBlock("?"+querystr));
  113.  %>
  114.             &nbsp;</div></td>
  115.         </tr>
  116.       </table>    </td>
  117.   </tr>
  118.   <tr> 
  119.     <td height="30" colspan="2" align="center">
  120.       <input name="button" type="submit" class="button1"  value="添加学习信息" onClick="form1.submit()">
  121.     </td>
  122.   </tr>
  123. </table>
  124. </body>
  125. </html>