Boardroom_Edit.jsp
上传用户:guhaomin
上传日期:2007-06-10
资源大小:23203k
文件大小:10k
源码类别:

电子政务应用

开发平台:

Java

  1. <%
  2. /**
  3.  *  $ RCSfile: Boardroom_Edit.jsp,v $
  4.  *  $ Revision: 1.0 $
  5.  *  $ Date: 2001/07/018 20:18:46 ,created by Shiyong Jian $
  6.  *  $ /mainctrl/boardroom/edit $
  7.  *
  8.  *  This is the boardroom edit  page.
  9.  *  @author Copyright (c) May. 2001, by VisionNex  Technologies Inc., All Right Reversed.
  10.  */
  11. %>
  12. <!--%@ page errorPage="/vnex/intranet/office/boardroom/Boardroom_Error_Page.jsp" %-->
  13. <%@ page errorPage="/vnex/ErrorPage.jsp" %>
  14. <%@ page import="com.vnex.intranet.conference.value.BoardroomValueBean" %>
  15. <%@ page import="com.vnex.intranet.conference.util.*" %>
  16. <%@ page import="com.vnex.intranet.util.FieldUtil" %>
  17. <%@ taglib uri="/vnex_hr.tld" prefix="hr" %>
  18. <%@ taglib uri="/vnex_organization.tld" prefix="org" %>
  19. <%@ taglib uri="/vnex.tld" prefix="vnex" %>
  20. <jsp:useBean id="boardroomValueBean" scope="session" class="com.vnex.intranet.conference.value.BoardroomValueBean" />
  21. <jsp:setProperty name="boardroomValueBean" property="*" />
  22. <%
  23.    String flag = request.getParameter("flag");
  24.     /* if( flag != null && flag.equals("fromBrowsePage") )
  25.         boardroomValueBean = ( BoardroomValueBean ) session.getAttribute("boardroomValueBean" );
  26.      else*/
  27.         session.setAttribute("boardroomValueBean" ,boardroomValueBean );
  28.         int brId = boardroomValueBean.getId();
  29.       
  30.        // this part is for the show employee and orgnazation custom tag.
  31.         int deptId = 1;
  32.         // the general company id equals 1.
  33.         if( request.getParameter("deptId") != null )
  34.         {
  35.             deptId = Integer.parseInt ( request.getParameter("deptId") );
  36.         }
  37. %>
  38. <HTML>
  39. <jsp:include page="/vnex/page/FORM_HEAD.jsp" />
  40. <script language="JavaScript1.2" src="/vnex/menu/dockmenu_office.js"></script>
  41. <script language="JavaScript1.2" src="/vnex/menu/dockmenu.js"></script>
  42. <script language="JavaScript1.2" src="/vnex/util/validate.js"></script>
  43. <script language="JavaScript1.2" src="/vnex/intranet/office/boardroom/checkBoardroom.js"></script>
  44. <script Language="JavaScript">
  45. function submitForm(act)
  46. {
  47.     if ( act == 'save' )
  48.     {
  49.          if ( !checkBoardroom( document.forms[0] ) )
  50.               return false;
  51.          document.forms[0].action='/mainctrl/boardroom/updateBoardroom';
  52.          document.forms[0].submit();
  53.     }
  54.     if( act == 'stop' )
  55.     {
  56.         document.forms[0].action='/mainctrl/boardroom/updateBoardroom?flag=stop&boardroomId=<%=brId%>';
  57.         document.forms[0].submit();
  58.     } 
  59.     if( act == 'resume' )
  60.     {
  61.         document.forms[0].action='/mainctrl/boardroom/updateBoardroom?flag=resume&boardroomId=<%=brId%>';
  62.         document.forms[0].submit();
  63.     } 
  64.     if( act == 'return' )
  65.     {
  66.         document.forms[0].action='/mainctrl/boardroom/browseDetails?boardroomId=<%=brId%>';
  67.         document.forms[0].submit();
  68.     } 
  69.     if( act == 'delete' )
  70.     {
  71.         if ( confirm("确定删除?" ) )
  72.         {
  73.             document.forms[0].action='/mainctrl/boardroom/deleteBoardroom?boardroomId=<%=brId%>';
  74.             document.forms[0].submit();
  75.         }
  76.     }
  77.    
  78. }   
  79. function changeIt(form)
  80. {    
  81.      form.action = "/mainctrl/boardroom/editPage"
  82.      form.submit();
  83. }     
  84.   
  85. </script>  
  86. <BODY text=#000000 vLink=#000000 aLink=#000000 link=#000000 bgColor=#ffffff topMargin=20 leftmargin="0" marginwidth="0" marginheight="0">
  87. <DIV align=center>
  88.   <form name="form1" method="post" >
  89.     <TABLE class=outter cellSpacing=0 cellPadding=0 border=0 width="600">
  90.        <jsp:include page="/vnex/page/TTOA_TABLE_TOP.jsp" />
  91.     <TR> 
  92.         <TD colSpan=3 align="center"><br>
  93.           <table width="600" border="1" cellspacing="1" bordercolor="#666666">
  94.             <tr bgcolor="#FAFAFA"> 
  95.               <td> 
  96.                 <table class=title width="600" border="0" cellspacing="1" cellpadding="2">
  97.                   <tr bgcolor="#666666"> 
  98.                     <td colspan="3" height="15"> <font class="strongw">
  99.                     <jsp:include page="Boardroom_Navibar_Head.jsp" />
  100.                     &gt;&gt;修改会议室 
  101.                       </font> </td>
  102.                   </tr>
  103.                   <tr bgcolor="#e0e0e0"> 
  104.                     <td width="121"><font class="strong">&nbsp;编号:</font> </td>
  105.                     <td colspan="2"> 
  106.                       <input type="text" name="code" class="file" size="6" value="<%=FieldUtil.filterScriptTag( FieldUtil.filterQuotTag (boardroomValueBean.getCode()) ) %>">&nbsp;*&nbsp;(注:带*为必填内容)
  107.                     </td>
  108.                   </tr>
  109.                   <tr bgcolor="#fafafa"> 
  110.                     <td width="121"><font class="strong">&nbsp;名称:</font> </td>
  111.                     <td colspan="2"> 
  112.                       <input type="text" name="name" class="file" value="<%=FieldUtil.filterScriptTag( FieldUtil.filterQuotTag ( boardroomValueBean.getName() ) ) %>" size="24">&nbsp;*
  113.                     </td>
  114.                   </tr>
  115.                   <tr bgcolor="#e0e0e0"> 
  116.                     <td width="121"><font class="strong">&nbsp;位置:</font> </td>
  117.                     <td colspan="2"> 
  118.                       <input type="text" name="position" class="file" size="24" value="<%=FieldUtil.filterScriptTag( FieldUtil.filterQuotTag ( boardroomValueBean.getPosition() ) ) %>">
  119.                     </td>
  120.                   </tr>
  121.                   <tr bgcolor="#fafafa"> 
  122.                     <td width="121"><font  class="strong">&nbsp;座位数: </font> </td>
  123.                     <td colspan="2"> 
  124.                       <input type="text" name="seatAmount" class="file" size="4" maxlength="4" value="<%=boardroomValueBean.getSeatAmount() %>">&nbsp;*
  125.                     </td>
  126.                   </tr>
  127.                   <tr bgcolor="#e0e0e0"> 
  128.                     <td width="121"><font  class="strong">&nbsp;管理人: </font></td>
  129.                     <td width="64"> 
  130.                     
  131.                     <select name="deptId" onChange="changeIt(this.form)" class="file">
  132.                         <org:DivisionList> <vnex:items select='<%=request.getParameter("deptId") %>'> 
  133.                         <option value='<org:DivisionAttribute attribute="id" />'<org:DivisionAttribute attribute="isSelected" /> >
  134.                         <org:DivisionAttribute attribute="levelStr"/>+<org:DivisionAttribute attribute="name"/> 
  135.                         </option>
  136.                         </vnex:items> </org:DivisionList> 
  137.                       </select>                    
  138.                     </td>
  139.                     <td width="396"> 
  140.                       <select name="administrator"   class="file"  >
  141.                         <hr:EmployeeList divisionid='<%=deptId %>'   > 
  142.                         <vnex:items select='<%=boardroomValueBean.getAdministrator()+""%>'> 
  143.                         <option value='<hr:EmployeeAttribute attribute="id" />' <hr:EmployeeAttribute attribute="isSelected" /> > 
  144.                         <hr:EmployeeAttribute attribute="employee_name" /></option>
  145.                         </vnex:items> </hr:EmployeeList> 
  146.                       </select>&nbsp;*
  147.                     </td>
  148.                   </tr>
  149.                   <tr bgcolor="#fafafa"> 
  150.                     <td width="121"><font  class="strong">&nbsp;设备:</font></td>
  151.                     <td colspan="2"> 
  152.                       <textarea rows="4" name="devices" cols="59"><%=FieldUtil.filterScriptTag( FieldUtil.filterQuotTag ( boardroomValueBean.getDevices() ) ) %></textarea>
  153.                     </td>
  154.                   </tr>
  155.                   <tr bgcolor="#e0e0e0"> 
  156.                     <td width="121" bgcolor="#e0e0e0"><font  class="strong">&nbsp;描述:</font> 
  157.                     </td>
  158.                     <td colspan="2"> 
  159.                       <textarea rows="4" name="description" cols="59"><%=FieldUtil.filterScriptTag( FieldUtil.filterQuotTag ( boardroomValueBean.getDescription() ) )%></textarea>
  160.                     </td>
  161.                   </tr>
  162.                   <%
  163.                       String theValue= "";
  164.                       String theScript="";
  165.                       if ( boardroomValueBean.getStatusId() == ConferenceConstant.PAUSED_BOARDROOM )
  166.                       {
  167.                           theValue ="恢复使用";
  168.                           theScript = "submitForm('resume')";
  169.                       }
  170.                       else
  171.                       {
  172.                           theValue="暂停使用";
  173.                           theScript="submitForm('stop')";
  174.                       }
  175.                       %> 
  176.                   <tr align="center" bgcolor="#fafafa"> 
  177.                     <td colspan="3" height="30"> 
  178.                     
  179.                       <input type="button" name="saveButton" class="file" onClick=" submitForm('save') " value="保存">&nbsp;&nbsp; 
  180.                       <input type="reset" name="resetButton" value="重置" class="file">&nbsp;&nbsp; 
  181.                       <input type="button" name="cancle" value="放弃" class="file" onClick=" submitForm('return') ">&nbsp;&nbsp; 
  182.                       <% if ( boardroomValueBean.getStatusId() != ConferenceConstant.BOOKED_BOARDROOM )
  183.                         {
  184.                       %>
  185.                       <input type="button" name="deleteButton" value="删除" onClick=" submitForm('delete') " class=text>&nbsp;&nbsp;
  186.                       <input type="button" name="stopButton" style="width:60px" value="<%=theValue %>" onClick= "<%=theScript%>" class=file> 
  187.                       <%
  188.                       }
  189.                       %>
  190.                     </td>
  191.                   </tr>
  192.                 </table>
  193.               </td>
  194.             </tr>
  195.           </table>
  196.        <jsp:include page="/vnex/page/TTOA_HELP.jsp" />
  197.       </TD>
  198.     </TR>
  199.       <jsp:include page="/vnex/page/TTOA_TABLE_BOTTOM.jsp" />
  200.   </TABLE>
  201.   <BR>
  202.    <jsp:include page="/vnex/page/TTOA_PRODUCER_LOGO.jsp" />
  203.  </form>
  204. </DIV>
  205. </BODY>
  206. </HTML>