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

Jsp/Servlet

开发平台:

Java

  1. <%@ page contentType="text/html; charset=utf-8" language="java" import="java.sql.*" errorPage="" %>
  2. <%@ page import="com.redmoon.oa.archive.*" %>
  3. <%@ page import="cn.js.fan.util.*" %>
  4. <%@ page import="cn.js.fan.web.*" %>
  5. <%@ page import="java.util.*" %>
  6. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  7. <html xmlns="http://www.w3.org/1999/xhtml">
  8. <head>
  9. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  10. <link rel="stylesheet" type="text/css" href="../common.css">
  11. <link rel="stylesheet" type="text/css" href="../css.css">
  12. <title>修改用户档案</title>
  13. <script>
  14. function findObj(theObj, theDoc)
  15. {
  16.   var p, i, foundObj;
  17.   
  18.   if(!theDoc) theDoc = document;
  19.   if( (p = theObj.indexOf("?")) > 0 && parent.frames.length)
  20.   {
  21.     theDoc = parent.frames[theObj.substring(p+1)].document;
  22.     theObj = theObj.substring(0,p);
  23.   }
  24.   if(!(foundObj = theDoc[theObj]) && theDoc.all) foundObj = theDoc.all[theObj];
  25.   for (i=0; !foundObj && i < theDoc.forms.length; i++) 
  26.     foundObj = theDoc.forms[i][theObj];
  27.   for(i=0; !foundObj && theDoc.layers && i < theDoc.layers.length; i++) 
  28.     foundObj = findObj(theObj,theDoc.layers[i].document);
  29.   if(!foundObj && document.getElementById) foundObj = document.getElementById(theObj);
  30.   
  31.   return foundObj;
  32. }
  33. var GetDate=""; 
  34. function SelectDate(ObjName,FormatDate){
  35. var PostAtt = new Array;
  36. PostAtt[0]= FormatDate;
  37. PostAtt[1]= findObj(ObjName);
  38. GetDate = showModalDialog("../util/calendar/calendar.htm", PostAtt ,"dialogWidth:286px;dialogHeight:221px;status:no;help:no;");
  39. }
  40. function SetDate()
  41. findObj(ObjName).value = GetDate; 
  42. }
  43. </script>
  44. </head>
  45. <body style="background-image:url()">
  46. <jsp:useBean id="privilege" scope="page" class="com.redmoon.oa.pvg.Privilege"/>
  47. <%
  48. String priv = "archive";
  49. if (!privilege.isUserPrivValid(request, priv)) {
  50. out.println(SkinUtil.makeErrMsg(request, SkinUtil.LoadString(request, "pvg_invalid")));
  51. return;
  52. }
  53. String name = ParamUtil.get(request, "name");
  54. if (name.equals("")) {
  55. out.print(StrUtil.Alert("用户名不能为空!"));
  56. return;
  57. }
  58. UserArchiveDb uad = new UserArchiveDb();
  59. uad = uad.getUserArchiveDb(name);
  60. String op = ParamUtil.get(request, "op");
  61. if (op.equals("create")) {
  62. if (uad==null || !uad.isLoaded()) {
  63. boolean re = uad.create();
  64. // out.print("re=" + re);
  65. }
  66. }
  67. uad = uad.getUserArchiveDb(name);
  68. if (op.equals("modify")) {
  69. UserArchiveMgr uam = new UserArchiveMgr();
  70. boolean re = false;
  71. try {
  72. re = uam.modify(application, request);
  73. if (re)
  74. uad = uad.getUserArchiveDb(name);
  75. }
  76. catch (ErrMsgException e) {
  77. out.print(StrUtil.Alert(e.getMessage()));
  78. }
  79. if (re)
  80. out.print(StrUtil.Alert("维护成功!"));
  81. }
  82. %>
  83. <table width="90%" border="0" align="center" cellPadding="2" cellSpacing="1" class="main">
  84.   <form name="form1" action="?op=modify&name=<%=StrUtil.UrlEncode(name)%>" method="post" encType="multipart/form-data">
  85.     <tbody>
  86.       <tr>
  87.         <td noWrap colSpan="3" class="right-title"><b>&nbsp;<%=name%>的基本信息</b></td>
  88.       </tr>
  89.       <tr>
  90.         <td noWrap width="96">编号:</td>
  91.         <td width="496"><input name="id" id="id" size="10" maxLength="100" value="<%=uad.getId()%>"></td>
  92.         <td width="160" rowSpan="6"><center>
  93. <%if (uad.getPhoto()==null || uad.getPhoto().equals("")) {%>
  94. 暂无照片
  95. <%}else{%>
  96. <img src="../<%=uad.getPhoto()%>">
  97. <%}%>
  98. </center> </td>
  99.       </tr>
  100.       <tr>
  101.         <td noWrap>姓名:</td>
  102.         <td><input name="realName" id="realName" value="<%=uad.getRealName()%>" size="10" maxlength="100" /></td>
  103.       </tr>
  104.       <tr>
  105.         <td noWrap>性别:</td>
  106.         <td><select name="gender">
  107.             <option value="0" selected>女</option>
  108.             <option value="1">男</option>
  109.           </select>
  110.   <script>
  111.   form1.gender.value = "<%=uad.getGender()%>";
  112.   </script>   </td>
  113.       </tr>
  114.       <tr>
  115.         <td noWrap>出生日期:</td>
  116.         <td noWrap><input name="birthday" id="birthday" size="10" maxlength="10" value="<%=uad.getBirthday()==null?"":DateUtil.format(uad.getBirthday(), "yyyy-MM-dd")%>" />
  117.           <img src="../images/form/calendar.gif" border="0" align="absmiddle" style="CURSOR: hand" onclick="SelectDate('birthday', 'yyyy-MM-dd')"> 
  118.           日期格式形如 1980-1-2</td>
  119.       </tr>
  120.       <tr>
  121.         <td noWrap>民族:</td>
  122.         <td><input name="nation" id="nation" value="<%=uad.getNation()%>" size="8" maxLength="100"></td>
  123.       </tr>
  124.       <tr>
  125.         <td noWrap>身份证号码:</td>
  126.         <td><input name="IDCard" value="<%=uad.getIDCard()%>" size="20" maxLength="25"></td>
  127.       </tr>
  128.       <tr>
  129.         <td noWrap>照片上传:</td>
  130.         <td colSpan="2"><input   title="选择附件文件" type="file" size="35" name="photo"></td>
  131.       </tr>
  132.       <tr>
  133.         <td noWrap>婚姻状况:</td>
  134.         <td colSpan="2"><select name="marriage">
  135.             <option value></option>
  136.             <option value="0" selected>未婚</option>
  137.             <option value="1">已婚</option>
  138.             <option value="2">离异</option>
  139.           </select>
  140.   <script>
  141.   form1.marriage.value = "<%=uad.getMarriage()%>";
  142.   </script>   </td>
  143.       </tr>
  144.       <tr>
  145.         <td noWrap>籍贯:</td>
  146.         <td colSpan="2"><input name="jiGuan" value="<%=uad.getJiGuan()%>" size="30"   maxLength="100"></td>
  147.       </tr>
  148.       <tr>
  149.         <td noWrap>户口所在地:</td>
  150.         <td colSpan="2"><input name="hukouAddress" value="<%=uad.getHukouAddress()%>" size="30"   maxLength="100"></td>
  151.       </tr>
  152.       <tr>
  153.         <td noWrap>学历:</td>
  154.         <td colSpan="2"><select name="xueLi">
  155.             <option value="1">小学</option>
  156.             <option value="2">初中</option>
  157.             <option value="3">高中</option>
  158.             <option value="4">中专</option>
  159.             <option value="5">大专</option>
  160.             <option value="6">大本</option>
  161.             <option value="7">硕士</option>
  162.             <option value="8">博士</option>
  163.             <option value="9">博士后</option>
  164.           </select>
  165.   <script>
  166.   form1.xueLi.value = "<%=uad.getXueLi()%>";
  167.   if (form1.xueLi.value=="")
  168.    form1.xueLi.value = "6";
  169.   </script>   </td>
  170.       </tr>
  171.       <tr>
  172.         <td noWrap>专业:</td>
  173.         <td colSpan="2"><input name="zhuanye" value="<%=uad.getZhuanYe()%>" size="30"   maxLength="100"></td>
  174.       </tr>
  175.       <tr>
  176.         <td noWrap>毕业院校:</td>
  177.         <td colSpan="2"><input name="school" value="<%=uad.getSchool()%>" size="30"   maxLength="100"></td>
  178.       </tr>
  179.       <tr>
  180.         <td noWrap>参加工作时间:</td>
  181.         <td noWrap colSpan="2"><input name="workDate" value="<%=uad.getWorkDate()%>" size="10"   maxLength="10"> 
  182.           <img src="../images/form/calendar.gif" border="0" align="absmiddle" style="CURSOR: hand" onclick="SelectDate('workDate', 'yyyy-MM-dd')"> 
  183.           日期格式形如 1999-1-2,请仔细检查</td>
  184.       </tr>
  185.       <tr>
  186.         <td noWrap>加入本单位时间:</td>
  187.         <td noWrap colSpan="2"><input name="workDateAtHere" value="<%=uad.getWorkDateAtHere()%>" size="10"   maxLength="10"> 
  188.           <img src="../images/form/calendar.gif" border="0" align="absmiddle" style="CURSOR: hand" onclick="SelectDate('workDateAtHere', 'yyyy-MM-dd')"> 
  189.           日期格式形如 1999-1-2,请仔细检查</td>
  190.       </tr>
  191.       <tr>
  192.         <td noWrap>部门:</td>
  193.         <td colSpan="2"><input name="dept" value="<%=uad.getDept()%>" size="15"   maxLength="100"></td>
  194.       </tr>
  195.       <tr>
  196.         <td noWrap>职务:</td>
  197.         <td colSpan="2"><input   maxLength="100" size="15" value="<%=uad.getZhiWu()%>" name="zhiWu"></td>
  198.       </tr>
  199.       <tr>
  200.         <td noWrap>职称:</td>
  201.         <td colSpan="2"><input name="zhiChen" value="<%=uad.getZhiChen()%>" size="15"   maxLength="100"></td>
  202.       </tr>
  203.       <tr>
  204.         <td noWrap>政治面貌:</td>
  205.         <td colSpan="2"><select name="politics">
  206.             <option value="1">群众</option>
  207.             <option value="2">团员</option>
  208.             <option value="4">预备党员</option>
  209.             <option value="3">党员</option>
  210.           </select>
  211.   <script>
  212.   form1.politics.value = "<%=uad.getPolitics()%>";
  213.   </script>   </td>
  214.       </tr>
  215.       <tr>
  216.         <td noWrap>家庭住址:</td>
  217.         <td colSpan="2"><input name="address" value="<%=uad.getHomeAddress()%>" size="40"   maxLength="100"></td>
  218.       </tr>
  219.       <tr>
  220.         <td noWrap>家庭电话:</td>
  221.         <td colSpan="2"><input name="homeTel" value="<%=uad.getHomeTel()%>" size="15"   maxLength="100"></td>
  222.       </tr>
  223.       <tr>
  224.         <td noWrap>电子邮件:</td>
  225.         <td colSpan="2"><input name="email" value="<%=uad.getEmail()%>" size="30"   maxLength="100"></td>
  226.       </tr>
  227.       <tr>
  228.         <td class="TableHeader" noWrap colSpan="3">&nbsp;岗位变动情况:</td>
  229.       </tr>
  230.       <tr>
  231.         <td colSpan="3"><textarea   name="postChange" rows="3" wrap="on" cols="70"><%=uad.getPostChange()%></textarea></td>
  232.       </tr>
  233.       <tr>
  234.         <td class="TableHeader" noWrap colSpan="3">&nbsp;教育背景</td>
  235.       </tr>
  236.       <tr>
  237.         <td colSpan="3"><textarea name="education" rows="3" wrap="on" cols="70"><%=uad.getEducation()%></textarea></td>
  238.       </tr>
  239.       <tr>
  240.         <td class="TableHeader" noWrap colSpan="3">&nbsp;工作简历</td>
  241.       </tr>
  242.       <tr>
  243.         <td colSpan="3"><textarea name="resume" rows="3" wrap="on" cols="70"><%=uad.getResume()%></textarea></td>
  244.       </tr>
  245.       <tr>
  246.         <td class="TableHeader" noWrap colSpan="3">&nbsp;社会关系</td>
  247.       </tr>
  248.       <tr>
  249.         <td colSpan="3"><textarea   name="socialRelation" rows="3" wrap="on" cols="70"><%=uad.getSocialRelation()%></textarea></td>
  250.       </tr>
  251.       <tr>
  252.         <td class="TableHeader" noWrap colSpan="3">&nbsp;奖惩记录</td>
  253.       </tr>
  254.       <tr>
  255.         <td colSpan="3"><textarea   name="jiangchenRecord" rows="3" wrap="on" cols="70"><%=uad.getJiangchenRecord()%></textarea></td>
  256.       </tr>
  257.       <tr>
  258.         <td class="TableHeader" noWrap colSpan="3">&nbsp;职务情况</td>
  259.       </tr>
  260.       <tr>
  261.         <td colSpan="3"><textarea   name="zhiwuQinkuang" rows="3" wrap="on" cols="70"><%=uad.getZhiwuQinkuang()%></textarea></td>
  262.       </tr>
  263.       <tr>
  264.         <td class="TableHeader" noWrap colSpan="3">&nbsp;培训记录</td>
  265.       </tr>
  266.       <tr>
  267.         <td colSpan="3"><textarea   name="trainRecord" cols="70" rows="3" wrap="on" id="trainRecord"><%=uad.getTrainRecord()%></textarea></td>
  268.       </tr>
  269.       <tr>
  270.         <td class="TableHeader" noWrap colSpan="3">&nbsp;担保记录</td>
  271.       </tr>
  272.       <tr>
  273.         <td colSpan="3"><textarea   name="danbaoRecord" cols="70" rows="3" wrap="on" id="danbaoRecord"><%=uad.getDanbaoRecord()%></textarea></td>
  274.       </tr>
  275.       <tr>
  276.         <td class="TableHeader" noWrap colSpan="3">&nbsp;劳动合同签订情况</td>
  277.       </tr>
  278.       <tr>
  279.         <td colSpan="3"><textarea   name="contract" cols="70" rows="3" wrap="on" id="contract"><%=uad.getContract()%></textarea></td>
  280.       </tr>
  281.       <tr>
  282.         <td class="TableHeader" noWrap colSpan="3">&nbsp;社保缴纳情况</td>
  283.       </tr>
  284.       <tr>
  285.         <td colSpan="3"><textarea   name="insure" cols="70" rows="3" wrap="on" id="insure"><%=uad.getInsure()%></textarea></td>
  286.       </tr>
  287.       <tr>
  288.         <td class="TableHeader" noWrap colSpan="3">&nbsp;体检记录</td>
  289.       </tr>
  290.       <tr>
  291.         <td colSpan="3"><textarea   name="tijianRecord" cols="70" rows="3" wrap="on" id="tijianRecord"><%=uad.getTijianRecord()%></textarea></td>
  292.       </tr>
  293.       <tr>
  294.         <td class="TableHeader" noWrap colSpan="3">&nbsp;备 注</td>
  295.       </tr>
  296.       <tr>
  297.         <td colSpan="3"><span class="TableHeader"><b>
  298.           <textarea   name="remark" cols="70" rows="3" wrap="on" id="remark"><%=uad.getRemark()%></textarea>
  299.         </b></span></td>
  300.       </tr>
  301.   <!--      <tr>
  302.         <td class="TableHeader" noWrap colSpan="3"><b>&nbsp;附件文档</b></td>
  303.       </tr>
  304.       <tr>
  305.         <td colSpan="3"> </td>
  306.       </tr>
  307.       <tr>
  308.         <td noWrap>附件上传:</td>
  309.         <td colSpan="2"><input name="attachment" type="file" id="attachment"   title="选择附件文件" size="35"></td>
  310.       </tr>
  311.   -->
  312.       <tr align="center" class="TableControl">
  313.         <td noWrap colSpan="3"><input type=hidden name="name" value="<%=name%>" />
  314.           <input type="submit" value=" 保 存 ">
  315.           &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  316.         <input name="重置" type="reset" onclick="location='blank.php'" value=" 重 置 "></td>
  317.       </tr>
  318.     </tbody>
  319.   </form>
  320. </table>
  321. </body>
  322. </html>