InformationList.jsp~63~
上传用户:zghglow
上传日期:2022-08-09
资源大小:27227k
文件大小:6k
源码类别:

WEB源码(ASP,PHP,...)

开发平台:

JavaScript

  1. <%@ page contentType="text/html; charset=GBK" %>
  2. <%@ taglib uri="http://java.sun.com/jstl/core_rt" prefix="c" %>
  3. <%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
  4. <html>
  5. <head>
  6. <title>InformationList</title>
  7. <link href="Css/skinv2.0.css" rel="stylesheet" type="text/css" />
  8. <script type="text/javascript">
  9. function doPost(params){
  10.   var action="<%=request.getContextPath()%>/Manage/informationAction.do?todo=OpenInformationList"+"&"+params;
  11.   <c:if test="${param.menuID != null}">
  12.   action += "";
  13.   </c:if>
  14.   var form=document.getElementById("form");
  15.   form.action=action;
  16.   form.submit();
  17. }
  18. function searchAction() {
  19.   var action = '<%=request.getContextPath()%>/Manage/Information.do?todo=OpenInformationList&menuID=<c:out value="${param.menuID}" />';
  20.   var form = document.getElementById("form");
  21.   form.action = action;
  22.   form.submit();
  23. }
  24. function AddInfo(){
  25.   <c:if test="${cat != null}">
  26.   location.href = '<%=request.getContextPath()%>/Manage/Information.do?todo=OpenInformation&catID=' + <c:out value="${cat.cat_ID}" />;
  27.   </c:if>
  28.   <c:if test="${menu != null}">
  29.   location.href = '<%=request.getContextPath()%>/Manage/Information.do?todo=OpenInformation&menID=' + <c:out value="${menu.men_ID}" />;
  30.   </c:if>
  31. }
  32. function EditInfo(id){
  33.   <c:if test="${cat != null}">
  34.   location.href = '<%=request.getContextPath()%>/Manage/Information.do?todo=OpenInformation&infID=' + id + '&catID=' + <c:out value="${cat.cat_ID}" />;
  35.   </c:if>
  36.   <c:if test="${menu != null}">
  37.   location.href = '<%=request.getContextPath()%>/Manage/Information.do?todo=OpenInformation&infID=' + id + '&menID=' + <c:out value="${menu.men_ID}" />;
  38.   </c:if>
  39. }
  40. </script>
  41. </head>
  42. <body bgcolor="#ffffff">
  43. <form name="form" method="post" action="InformationList.jsp">
  44. <table cellspacing="0" cellpadding="0" width="100%" border="0">
  45.   <tr bgcolor="#cfdbe8">
  46.     <td style="WIDTH: 20px" width="20" bgColor="#cfdbe8" height="19">
  47.       &nbsp;<img height="10" src="<%=request.getContextPath()%>/Manage/images/icon.gif" width="12" alt="" />
  48.     </td>
  49.     <td valign="middle" bgcolor="#cfdbe8" colSpan="2">&nbsp; <c:out value="${MainTitle}" /></td>
  50.   </tr>
  51.   <tr>
  52.     <td style="HEIGHT: 31px" valign="top" align="left" height="80">&nbsp;</td>
  53.     <td style="HEIGHT: 31px" valign="middle" align="left" colSpan="2">
  54.       &nbsp;<img src="<%=request.getContextPath()%>/Manage/images/edit.gif" alt="" />
  55.       &nbsp;<c:out value="${ChildTitle}" />
  56.     </td>
  57.   </tr>
  58.   <tr>
  59.     <td style="HEIGHT: 1px" valign="top" align="left"></td>
  60.     <td style="HEIGHT: 1px" valign="top" align="left" width="820" bgcolor="#cfdbe8"></td>
  61.     <td style="HEIGHT: 1px" valign="top" align="left" width="144"></td>
  62.   </tr>
  63.   <tr>
  64.     <td style="HEIGHT: 381px" valign="top" align="left"></td>
  65.     <td style="HEIGHT: 381px" valign="top" align="left" colspan="2">
  66.       <br/>
  67.       查询关键字:
  68.       <input type="text" id="txtCondition" value='<c:out value="${condition}" />' name="condition" class="input000000_1" />
  69.       <input type="hidden" name="hidCondition" value='<c:out value="${condition}" />' />
  70.       <input type="button" name="btnQuery" value="  重新刷新" class="Botton" onclick="searchAction();" />
  71.       <input type="button" name="btnQuery" value="  添加记录" class="Botton" onclick="AddInfo();" />
  72.       <br /><br />
  73.       <table width="640" border="0" cellpadding="0" cellspacing="0" class="table_Left">
  74.         <tr>
  75.           <td width="400" height="30" align="center" bgcolor="#5983B0" class="STYLE1 table_Right"><strong>信息标题</strong></td>
  76.           <td width="120" align="center" bgcolor="#5983B0" class="STYLE1 table_Right"><strong>发布时间</strong></td>
  77.           <td width="120" align="center" bgcolor="#5983B0" class="STYLE1 table_Right"><strong>操作</strong></td>
  78.         </tr>
  79.       </table>
  80.       <div id="divList">
  81.         <c:forEach var="inf" items="${pageInfo.rows}" varStatus="status">
  82.           <table width="640" border="0" cellpadding="0" cellspacing="0" class="table_Left">
  83.             <tr>
  84.               <td width="400" height="25" class="table_Right">
  85.                 &nbsp;<c:out value="${inf.inf_Title}" />
  86.               </td>
  87.               <td width="120" align="center" class="table_Right">
  88.                 <bean:write name="inf" property="inf_Time" format="yyyy-MM-dd"/>
  89.               </td>
  90.               <td width="120" align="center" class="table_Right">
  91.                 <a href='javascript:EditInfo(<c:out value="${inf.inf_ID}" />)'>编辑</a>
  92.                 &nbsp;|&nbsp;
  93.                 <a href='<%=request.getContextPath()%>/Manage/Information.do?todo=DeleteInformation&infID=<c:out value="${inf.inf_ID}" />&menuID=<c:out value="${param.menuID}" />&catID=<c:out value="${param.catID}" />'>删除</a>
  94.               </td>
  95.             </tr>
  96.           </table>
  97.         </c:forEach>
  98.       </div>
  99.       <table width="640" border="0" cellpadding="0" cellspacing="0" class="table_Left">
  100.         <tr>
  101.           <td valign="middle" colspan="9" align="center" class="STYLE1 table_Right" height="30">
  102.             <div align="right" >
  103.               共<c:out value="${pageInfo.totalRows}"/>条记录 共<c:out value="${pageInfo.totalPages}"/>页 当前第<c:out value="${pageInfo.currentPageNO+1}"/>页
  104.               &nbsp;&nbsp;&nbsp;&nbsp;
  105.               <c:choose>
  106.                 <c:when test="${pageInfo.firstPageNO>=pageInfo.currentPageNO}">
  107.                 第一页
  108.                 |
  109.                 上一页
  110.                 </c:when>
  111.                 <c:otherwise>
  112.                   <a href="javascript:doPost('pageNo=<c:out value="${pageInfo.firstPageNO}"/>')">第一页</a>
  113.                   |
  114.                   <a href="javascript:doPost('pageNo=<c:out value="${pageInfo.previousPageNO}"/>')">上一页</a>
  115.                 </c:otherwise>
  116.               </c:choose>
  117.               |
  118.               <c:choose>
  119.                 <c:when test="${pageInfo.lastPageNO<=pageInfo.currentPageNO}">
  120.                 下一页
  121.                 |
  122.                 最后页
  123.                 </c:when>
  124.                 <c:otherwise>
  125.                   <a href="javascript:doPost('pageNo=<c:out value="${pageInfo.nextPageNO}"/>')">下一页</a>
  126.                   |
  127.                   <a href="javascript:doPost('pageNo=<c:out value="${pageInfo.lastPageNO}"/>')">最后页</a>
  128.                 </c:otherwise>
  129.               </c:choose>&nbsp;&nbsp;
  130.             </div>
  131.           </td>
  132.         </tr>
  133.       </table>
  134.     </td>
  135.   </tr>
  136. </table>
  137. </form>
  138. </body>
  139. </html>