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

Jsp/Servlet

开发平台:

Java

  1. <%@ page contentType="text/html; charset=utf-8"%>
  2. <%@ page import="com.redmoon.oa.pvg.*"%>
  3. <%@ page import="com.redmoon.oa.person.*"%>
  4. <%@ page import="cn.js.fan.util.*"%>
  5. <%@ page import="cn.js.fan.db.*"%>
  6. <%@ page import="cn.js.fan.web.*"%>
  7. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  8. <html>
  9. <head>
  10. <title>管理登录</title>
  11. <link href="default.css" rel="stylesheet" type="text/css">
  12. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  13. <style type="text/css">
  14. <!--
  15. .style4 {
  16. color: #FFFFFF;
  17. font-weight: bold;
  18. }
  19. -->
  20. </style>
  21. </head>
  22. <body bgcolor="#FFFFFF" text="#000000">
  23. <%
  24. String op = ParamUtil.get(request, "op");
  25. UserGroupDb ug = null;
  26. boolean isEdit = false;
  27. if (op.equals("edit")) {
  28. isEdit = true;
  29. String code = ParamUtil.get(request, "code");
  30. if (code.equals("")) {
  31. StrUtil.Alert_Back("编码不能为空!");
  32. return;
  33. }
  34. ug = new UserGroupDb(code);
  35. }
  36. if (op.equals("editdo")) {
  37. isEdit = true;
  38. UserGroupMgr usergroupmgr = new UserGroupMgr();
  39. try {
  40. if (usergroupmgr.update(request))
  41. out.print(StrUtil.Alert("修改成功!"));
  42. }
  43. catch (ErrMsgException e) {
  44. out.print(StrUtil.Alert_Back(e.getMessage()));
  45. }
  46. String code = ParamUtil.get(request, "code");
  47. if (code.equals("")) {
  48. StrUtil.Alert_Back("编码不能为空!");
  49. return;
  50. }
  51. ug = usergroupmgr.getUserGroupDb(code);
  52. }
  53. %>
  54. <table cellSpacing="0" cellPadding="0" width="100%">
  55.   <tbody>
  56.     <tr>
  57.       <td class="head">管理用户组</td>
  58.     </tr>
  59.   </tbody>
  60. </table>
  61. <br>
  62. <TABLE 
  63. style="BORDER-RIGHT: #a6a398 1px solid; BORDER-TOP: #a6a398 1px solid; BORDER-LEFT: #a6a398 1px solid; BORDER-BOTTOM: #a6a398 1px solid" 
  64. cellSpacing=0 cellPadding=3 width="95%" align=center>
  65.   <!-- Table Head Start-->
  66.   <TBODY>
  67.     <TR>
  68.       <TD class=thead style="PADDING-LEFT: 10px" noWrap width="70%">
  69.   <%if (isEdit) {%>
  70.      修改用户组
  71.   <%}else{%>
  72.   添加用户组
  73.   <%}%>
  74.   </TD>
  75.     </TR>
  76.     <TR class=row style="BACKGROUND-COLOR: #fafafa">
  77.       <TD height="175" align="center" style="PADDING-LEFT: 10px"><table class="frame_gray" width="53%" border="0" cellpadding="0" cellspacing="1">
  78.           <tr>
  79.             <td align="center"><table width="65%" border="0" cellpadding="0" cellspacing="0">
  80.                 <form name="form1" method="post" action="<%=isEdit?"user_group_op.jsp?op=editdo":"user_group_m.jsp?op=add"%>">
  81.                   <tr>
  82.                     <td width="105" height="31" align="center">代码</td>
  83.                   <td align="left"><input name="code" value="<%=isEdit?ug.getCode():""%>" <%=isEdit?"readonly":""%>></td>
  84.                   </tr>
  85.                   <tr>
  86.                     <td height="32" align="center">描述</td>
  87.                   <td align="left"><input name="desc" value="<%=isEdit?ug.getDesc():""%>"></td>
  88.                   </tr>
  89.                   <tr>
  90.                     <td colspan="2" align="center">
  91.                     </td>
  92.                   </tr>
  93.                   <tr>
  94.                     <td height="43" colspan="2" align="center"><input name="Submit" type="submit" class="singleboarder" value="提交">
  95. &nbsp;&nbsp;&nbsp;
  96.                       <input name="Submit" type="reset" class="singleboarder" value="重置"></td>
  97.                   </tr>
  98.                 </form>
  99.             </table></td>
  100.           </tr>
  101.       </table></TD>
  102.     </TR>
  103.     <!-- Table Body End -->
  104.     <!-- Table Foot -->
  105.     <TR>
  106.       <TD class=tfoot align=right><DIV align=right> </DIV></TD>
  107.     </TR>
  108.     <!-- Table Foot -->
  109.   </TBODY>
  110. </TABLE>
  111. <br>
  112. <br>
  113. </body>
  114. <script language="javascript">
  115. <!--
  116. function form1_onsubmit()
  117. {
  118. }
  119. //-->
  120. </script>
  121. </html>