showRecord.jsp 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. <%@ page contentType="text/html;charset=UTF-8" language="java" isELIgnored="false" %>
  2. <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
  3. <%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
  4. <!DOCTYPE html>
  5. <html>
  6. <head>
  7. <title>预约记录查询</title>
  8. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  9. <!-- 引入bootstrap -->
  10. <link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/bootstrap.min.css">
  11. <!-- 引入JQuery bootstrap.js-->
  12. <script src="${pageContext.request.contextPath}/js/jquery-3.2.1.min.js"></script>
  13. <script src="${pageContext.request.contextPath}/js/bootstrap.min.js"></script>
  14. <%--<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">--%>
  15. </head>
  16. <body>
  17. <!-- 顶栏 -->
  18. <!-- 中间主体 --><jsp:include page="top.jsp"></jsp:include>
  19. <div class="container" id="content">
  20. <div class="row">
  21. <jsp:include page="menu.jsp"></jsp:include>
  22. <div class="col-md-10">
  23. <div class="panel panel-default">
  24. <div class="panel-heading">
  25. <div class="row">
  26. <h1 class="col-md-5">预约记录查询</h1>
  27. <%--<form class="bs-example bs-example-form col-md-5" role="form" style="margin: 20px 0 10px 0;" action="${pageContext.request.contextPath}/admin/queryUser" id="form1" method="post">
  28. <div class="input-group">
  29. <input type="text" class="form-control" placeholder="请输入借用人姓名" name="findByName">
  30. <span class="input-group-addon btn" onclick="document.getElementById('form1').submit" id="sub">搜索</span>
  31. </div>
  32. </form>--%>
  33. </div>
  34. </div>
  35. <table class="table table-bordered">
  36. <thead>
  37. <tr>
  38. <th>会议室</th>
  39. <th>借用日期</th>
  40. <th>开始时间</th>
  41. <th>结束时间</th>
  42. <th>借用人</th>
  43. <th>联系方式</th>
  44. <th>状态</th>
  45. </tr>
  46. </thead>
  47. <tbody>
  48. <c:forEach items="${recordList}" var="item">
  49. <tr>
  50. <td>${item.name}</td>
  51. <td><fmt:formatDate value="${item.date}" dateStyle="medium" pattern="yyyy-MM-dd"/></td>
  52. <!--pattern="HH:mm:ss"为24小时计时法,pattern="hh:mm:ss"为12小时计时法-->
  53. <td><fmt:formatDate value="${item.beginTime}" dateStyle="medium" pattern="HH:mm:ss"/></td>
  54. <td><fmt:formatDate value="${item.endTime}" dateStyle="medium" pattern="HH:mm:ss"/></td>
  55. <td>${item.user}</td>
  56. <td>${item.mobile}</td>
  57. <td>${item.mark}</td>
  58. </tr>
  59. </c:forEach>
  60. </tbody>
  61. </table>
  62. <div class="panel-footer">
  63. <c:if test="${pagingVo != null}">
  64. <nav style="text-align: center">
  65. <ul class="pagination">
  66. <li><a href="${pageContext.request.contextPath}/admin/showRecord?page=${pagingVo.upPageNo}">&laquo;上一页</a></li>
  67. <li class="active"><a href="">${pagingVo.curentPageNo}</a></li>
  68. <c:if test="${pagingVo.curentPageNo+1 <= pagingVo.totalCount}">
  69. <li><a href="${pageContext.request.contextPath}/admin/showRecord?page=${pagingVo.curentPageNo+1}">${pagingVo.curentPageNo+1}</a></li>
  70. </c:if>
  71. <c:if test="${pagingVo.curentPageNo+2 <= pagingVo.totalCount}">
  72. <li><a href="${pageContext.request.contextPath}/admin/showRecord?page=${pagingVo.curentPageNo+2}">${pagingVo.curentPageNo+2}</a></li>
  73. </c:if>
  74. <c:if test="${pagingVo.curentPageNo+3 <= pagingVo.totalCount}">
  75. <li><a href="${pageContext.request.contextPath}/admin/showRecord?page=${pagingVo.curentPageNo+3}">${pagingVo.curentPageNo+3}</a></li>
  76. </c:if>
  77. <c:if test="${pagingVo.curentPageNo+4 <= pagingVo.totalCount}">
  78. <li><a href="${pageContext.request.contextPath}/admin/showRecord?page=${pagingVo.curentPageNo+4}">${pagingVo.curentPageNo+4}</a></li>
  79. </c:if>
  80. <li><a href="${pageContext.request.contextPath}/admin/showRecord?page=${pagingVo.totalCount}">最后一页&raquo;</a></li>
  81. </ul>
  82. </nav>
  83. </c:if>
  84. </div>
  85. </div>
  86. </div>
  87. </div>
  88. </div>
  89. <div class="container" id="footer">
  90. <div class="row">
  91. <div class="col-md-12"></div>
  92. </div>
  93. </div>
  94. </body>
  95. <script type="text/javascript">
  96. $("#nav li:nth-child(3)").addClass("active")
  97. <c:if test="${pagingVO != null}">
  98. if (${pagingVO.curentPageNo} == ${pagingVO.totalCount}) {
  99. $(".pagination li:last-child").addClass("disabled")
  100. };
  101. if (${pagingVO.curentPageNo} == ${1}) {
  102. $(".pagination li:nth-child(1)").addClass("disabled")
  103. };
  104. </c:if>
  105. function confirmd() {
  106. var msg = "您真的确定要删除吗?!";
  107. if (confirm(msg)==true){
  108. return true;
  109. }else{
  110. return false;
  111. }
  112. }
  113. $("#sub").click(function () {
  114. $("#form1").submit();
  115. });
  116. </script>
  117. </html>