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

电子政务应用

开发平台:

Java

  1. <%@ page errorPage="/vnex/ErrorPage.jsp" %>
  2. <%@ taglib uri="/vnex.tld" prefix="vnex" %>
  3. <%@ taglib uri="/vnex_archive.tld" prefix="archive" %>
  4. <%
  5.     String queryStr = " where borrow_flag=0 ";
  6.     String pageName = "/mainctrl/archive/borrowArchiveList?a";
  7.     String historyLink = "no";
  8.     if(request.getParameter("search") == null)
  9.     {
  10.        session.removeAttribute("conditionBean");
  11.        session.removeAttribute("condition");
  12.     }
  13.     else
  14.        pageName += "&search";
  15.     if(request.getParameter("history") != null)
  16.     {
  17.        queryStr = " where borrow_flag=1 ";   
  18.        pageName += "&history";
  19.        historyLink = "yes";
  20.     }   
  21.     if(session.getAttribute("condition") != null)
  22.     {
  23.        queryStr += (String)session.getAttribute("condition");
  24.     }
  25. %>
  26. <script language="JavaScript" src="/vnex/util/strUtil.js"></script>
  27. <script language=JavaScript>
  28. function deleteThem(form)
  29. {
  30.    if(form.borrowIds == null)
  31.    {
  32.       alert("目前尚未有数据可供删除");
  33.       return;
  34.    }
  35.    if(!isChecked(form.borrowIds))
  36.    {
  37.       alert("请至少选择一条记录再进行删除");
  38.       return;
  39.    }
  40.    if(confirm("是否删除所选记录?"))
  41.    {
  42.       form.action="/mainctrl/archive/deleteBorrowArchives";
  43.       form.submit();
  44.    }   
  45. }
  46. function SelectAll(form)
  47. {
  48.   for (var i=0;i<form.elements.length;i++)
  49.   {
  50.     var e = form.elements[i];
  51.     if (e.name != 'C1')
  52.        e.checked = form.C1.checked;
  53.   }
  54. }
  55. function showHistory(form)
  56. {
  57.    form.action="/mainctrl/archive/borrowArchiveList?history";
  58.    form.submit();
  59. }   
  60. </script>
  61. <HTML>
  62. <jsp:include page="/vnex/page/FORM_HEAD.jsp" />
  63. <BODY text=#000000 vLink=#000000 aLink=#000000 link=#000000 bgColor=#ffffff topMargin=20 leftmargin="0" marginwidth="0" marginheight="0">
  64. <script language="JavaScript1.2" src="/vnex/menu/dockmenu_archives.js"></script>
  65. <script language="JavaScript1.2" src="/vnex/menu/dockmenu.js"></script>
  66. <DIV align=center>
  67. <form name="form1" method="post">
  68.   <TABLE class=outter cellSpacing=0 cellPadding=0 width=600 border=0>
  69.     <TBODY> 
  70.     <jsp:include page="/vnex/page/TTOA_TABLE_TOP.jsp" />
  71.     <TR> 
  72.         <TD colSpan=3 align="center"><br>
  73.           <table width="600" border="1" cellspacing="1" bordercolor="#666666">
  74.             <tr> 
  75.               <td align="center" colspan="2" bgcolor="#FFFFFF"> 
  76.                 <table width="600" border="0" cellspacing="0" cellpadding="0">
  77.                   <tr bgcolor="#666666"> 
  78.                       <td><font class="strongw"><a href="/mainctrl/home/index"><font color="#ffffff">首页</font></a>&gt;&gt;<a href="/mainctrl/archives/main"><font color="#ffffff">档案管理</font></a>&gt;&gt;借阅记录</font>
  79.                       </td>
  80.                   </tr>
  81.                 </table>
  82.                 <table class=title border="0" cellpadding="2" cellspacing="1" width="600">
  83.                   <tr> 
  84.                     <td colspan="6" height="30" bgcolor="#fafafa">&nbsp;
  85. <%    
  86.               if(request.getParameter("history") == null)
  87.               {
  88. %>                                    
  89.                       <input type="button" class="text" name="B1" value="查询" onclick="location='/mainctrl/archive/queryBorrowArchive'">
  90.                       &nbsp;&nbsp;
  91.                       <input type="button" value="借阅历史记录" name="B253" class="text" onclick="showHistory(this.form)" style="width:85px">
  92. <%            }
  93.               else
  94.               {
  95. %>             
  96.                       <input type="button" value="删除" name="B252" class="text" onclick="deleteThem(this.form)">
  97.                       &nbsp;&nbsp;
  98.                       <input type="button" value="返回" name="B254" class="text" onclick="location='/mainctrl/archive/borrowArchiveList'">
  99. <%            }%>                                                                  
  100.                     </td>
  101.                   </tr>
  102.                         <tr align="center">
  103. <%            if(request.getParameter("history") != null)
  104.               {%>
  105.                           <td width="7%"><strong>选择</strong></td>
  106. <%            }%>                          
  107.                           <td width="8%"><strong>编号</strong></td>
  108.                           <td width="14%"><strong>借阅日期</strong></td>
  109.                           <td width="46%" align="center"><strong>档案标题</strong></td>
  110.                           <td width="10%"><strong>借阅人</strong></td>
  111.                           <td width="14%"><strong>归还期限</strong></td>
  112.                         </tr>
  113.                         <archive:borrowList queryStr="<%=queryStr%>">
  114.                         <vnex:items paging="true">
  115.                         <tr bgcolor="<vnex:itemsColor />" align="center"> 
  116. <%            if(request.getParameter("history") != null)
  117.               {%>
  118.                           <td align="center" width="7%"> 
  119.                              <input type="checkbox" name="borrowIds" value="<archive:borrowAttribute attribute="borrow_id" />"></td>
  120. <%            }%>                             
  121.                           <td width="8%"><a href="/mainctrl/archive/borrowArchiveDetail?borrowId=<archive:borrowAttribute attribute="borrow_id" />&history=<%=historyLink%>"><archive:borrowAttribute attribute="borrow_id" /></a></td>
  122.                           <td width="14%"><archive:borrowAttribute attribute="borrow_date" /></td>
  123.                   <td width="46%"><archive:borrowAttribute attribute="archive_title" />
  124.                   </td>
  125.                   <td width="10%"><archive:borrowAttribute attribute="borrower" /></td>
  126.                   <td width="14%"><archive:borrowAttribute attribute="return_date" /></td>
  127.                         </tr>
  128.                         </vnex:items>
  129. <%            if(request.getParameter("history") != null)
  130.               {%>
  131.                         <tr bgcolor="#e0e0e0">
  132.                           <td width="7%" align="center">
  133.                               <input type="checkbox" name="C1" onclick="SelectAll(this.form)">
  134.                           </td>
  135.                           <td colspan="5">&nbsp;&nbsp;全选</td>
  136.                         </tr>
  137. <%            }%>
  138.                         <tr>
  139.                            <td colspan="6" align="left" bgcolor="#fafafa">&nbsp;&nbsp;<vnex:pagingTag pageName="<%=pageName%>" /> 
  140.                            </td>
  141.                         </tr>
  142.                          </archive:borrowList>
  143.                      </table>
  144.                    </td>
  145.                  </tr>
  146.             </table>
  147.           <jsp:include page="/vnex/page/TTOA_HELP.jsp" />
  148.        </TD>
  149.      </TR>
  150.      <jsp:include page="/vnex/page/TTOA_TABLE_BOTTOM.jsp" />
  151.     </TBODY> 
  152.   </TABLE>
  153.     <BR>
  154.   <jsp:include page="/vnex/page/TTOA_PRODUCER_LOGO.jsp" />
  155. </form>
  156. </DIV>
  157. </BODY>
  158. </HTML>