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