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

Jsp/Servlet

开发平台:

Java

  1. <%@ page contentType="text/html; charset=utf-8" language="java" import="java.sql.*" errorPage="" %>
  2. <%@ page import="com.redmoon.oa.dept.*" %>
  3. <%@ page import="cn.js.fan.util.*" %>
  4. <%@ page import="cn.js.fan.web.*" %>
  5. <%@ page import="java.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" "http://www.w3.org/TR/html4/loose.dtd">
  9. <html>
  10. <head>
  11. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  12. <title></title>
  13. <LINK href="../admin/default.css" type=text/css rel=stylesheet>
  14. <script>
  15. function preview(userName,deptCode)
  16. {
  17. window.parent.location.href='archive_user_modify.jsp?userName='+userName+'&deptCode='+deptCode;
  18. }
  19. </script>
  20. </head>
  21. <body>
  22. <%
  23.     String deptCode = ParamUtil.get(request, "deptCode");
  24. if (deptCode.equals(DeptDb.ROOTCODE)) {
  25. out.print(SkinUtil.makeErrMsg(request, "请选择某个部门!"));
  26. return;
  27. }
  28. if (deptCode.equals("")) {
  29. return;
  30. }
  31. DeptDb dd = new DeptDb();
  32. dd = dd.getDeptDb(deptCode);
  33. if (dd==null || !dd.isLoaded()) {
  34. out.print(StrUtil.Alert("部门" + deptCode + "不存在!"));
  35. return;
  36. }
  37. String op = ParamUtil.get(request, "op");
  38. if (op.equals("move")) {
  39.     UserInfoMgr uim = new UserInfoMgr();
  40. try {
  41. uim.move(request);
  42. }
  43. catch (ErrMsgException e) {
  44. out.print(StrUtil.Alert(e.getMessage()));
  45. }
  46. }
  47. %>
  48. <table width="500" border="0" align="center" cellpadding="0" cellspacing="1" class="frame_gray" style="height:100%">
  49.  <form name="form1" method="post" action="archive_user_add.jsp?deptCode=<%=deptCode%>">
  50.   <tr>
  51.     <td width="496" align="right" valign="top">
  52.  <table width="100%" border="0" cellspacing="0" cellpadding="0">
  53.       <tr>
  54.         <td height="24" align="center" bgcolor="#88B5FF"><%=dd.getName()%>用户档案维护</td>
  55.       </tr>
  56.      </table>
  57.      <table width="99%"  border="0" align="center" cellpadding="0" cellspacing="0">
  58.       <tr>
  59.         <td width="28%" height="24" align="center" bgcolor="#C4DAFF">职员</td>
  60.         <td height="24" colspan="4" align="center" bgcolor="#C4DAFF">操作</td>
  61.       </tr>
  62. <%
  63.     UserInfoDb uid = new UserInfoDb();
  64. Vector vt = uid.list(deptCode);
  65. Iterator ir = vt.iterator();
  66. while (ir.hasNext()) {
  67.     uid = (UserInfoDb)ir.next();
  68. %>
  69.       <tr>
  70.         <td height="22" align="center"><%=uid.getUserRealName()%></td>
  71.         <td width="22%" height="22" align="center"><a href="#" onClick="preview('<%=StrUtil.UrlEncode(uid.getUserName())%>','<%=StrUtil.UrlEncode(deptCode)%>')">维护档案信息</a></td>
  72.         <td width="22%" align="center"><a href="archive_user_do.jsp?userName=<%=StrUtil.UrlEncode(uid.getUserName())%>&deptCode=<%=StrUtil.UrlEncode(deptCode)%>&op=del">删除档案信息</a></td>
  73.         <td width="14%" align="center"><a href="?op=move&direction=up&userName=<%=StrUtil.UrlEncode(uid.getUserName())%>&deptCode=<%=StrUtil.UrlEncode(deptCode)%>">上移</a></td>
  74.         <td width="14%" align="center"><a href="?op=move&direction=down&userName=<%=StrUtil.UrlEncode(uid.getUserName())%>&deptCode=<%=StrUtil.UrlEncode(deptCode)%>">下移</a></td>
  75.       </tr>
  76. <%
  77.     }
  78. %>
  79.     </table>
  80.     <input name="btn" type="submit" class="button" id="btn" value="增加新用户基本信息">
  81.    </td><br>
  82.   </tr>
  83.  </form> 
  84. </table>
  85. </body>
  86. </html>