-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Panchenko. Added new features for tours - available in time slot, all…
… and weekly schedule
- Loading branch information
1 parent
19264eb
commit edafddb
Showing
11 changed files
with
196 additions
and
47 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
<%@ page session="false" %> | ||
<%@ page contentType="text/html;charset=UTF-8" language="java" %> | ||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> | ||
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> | ||
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> | ||
<%@ taglib prefix="sf" uri="http://www.springframework.org/tags/form" %> | ||
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %> | ||
|
||
<spring:url value="/tours/all" var="all" /> | ||
<spring:url value="/tours/timeslot" var="slot" /> | ||
<spring:url value="/tours/from" var="from" /> | ||
|
||
<html> | ||
<jsp:include page="../head.jsp"></jsp:include> | ||
<body> | ||
<jsp:include page="../menu.jsp"></jsp:include> | ||
|
||
<!-- Page content --> | ||
<div class="w3-content" style="max-width: 2000px; margin-top: 46px"> | ||
<div class="w3-container w3-content w3-center w3-padding-64" style="max-width: 800px" > | ||
<h2 class="w3-wide">Find available tours:</h2> | ||
<div class="w3-container w3-content w3-center" style="max-width:260px"> | ||
<form method="POST" action="${slot}"> | ||
<p>From: <input type="datetime-local" name="start" class="w3-input w3-border" /></p> | ||
<p>To: <input type="datetime-local" name="end" class="w3-input w3-border" /></p> | ||
<p><input type="submit" class="w3-btn-block w3-round w3-teal"/></p> | ||
</form> | ||
</div> | ||
</div> | ||
</div> | ||
|
||
|
||
<div class="w3-content" style="max-width: 2000px;"> | ||
<div class="w3-container w3-content w3-center" | ||
style="max-width: 800px" > | ||
<h3 class="w3-wide"><spring:message code="menu.tours" /></h3> | ||
<div class="w3-container w3-content w3-center" style="max-width: 200px"> | ||
<p><a href="${tours}" class="w3-btn-block w3-round w3-teal">Available tours</a></p> | ||
<p><a href="${all}" class="w3-btn-block w3-round w3-teal">Weekly schedule</a></p> | ||
</div> | ||
</div> | ||
</div> | ||
|
||
<!-- Footer --> | ||
<footer | ||
class="w3-container w3-padding-64 w3-center w3-opacity w3-light-grey w3-xlarge"> | ||
</footer> | ||
|
||
</body> | ||
</html> | ||
|
66 changes: 66 additions & 0 deletions
66
WebContent/WEB-INF/views/excursions/excursionsInSlotResults.jsp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
<%@ page session="false" %> | ||
<%@ page contentType="text/html;charset=UTF-8" language="java" %> | ||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> | ||
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> | ||
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> | ||
<%@ taglib prefix="sf" uri="http://www.springframework.org/tags/form" %> | ||
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %> | ||
|
||
<spring:url value="/tours" var="tours" /> | ||
<spring:url value="/tours/all" var="all" /> | ||
<spring:url value="/tours/timeslot" var="slot" /> | ||
<spring:url value="/tours/from" var="from" /> | ||
|
||
<html> | ||
<jsp:include page="../head.jsp"></jsp:include> | ||
<body> | ||
<jsp:include page="../menu.jsp"></jsp:include> | ||
|
||
<!-- Page content --> | ||
<div class="w3-content" style="max-width: 2000px; margin-top: 46px"> | ||
<div class="w3-container w3-content w3-center w3-padding-64" style="max-width: 800px" > | ||
<h2 class="w3-wide">Tours in given time slot:</h2> | ||
<c:choose> | ||
<c:when test="${not empty excursions}"> | ||
<table class="w3-table w3-striped w3-border w3-bordered w3-hoverable"> | ||
<thead> | ||
<tr class="w3-light-grey"><th>Name</th><th>Start</th><th>Duration</th><th>Guide</th></tr> | ||
</thead> | ||
<jsp:useBean id="myFormatter" class="com.softserve.museum.utils.LocalDateTimeCustomFormatter" scope="page"></jsp:useBean> | ||
<c:forEach items="${excursions}" var="current"> | ||
<tr> | ||
<td>${current.details.name}</td> | ||
<td>${myFormatter.format(current.start)}</td> | ||
<td>${current.details.duration}</td> | ||
<td>${current.guide.firstName} ${current.guide.lastName}</td> | ||
</tr> | ||
</c:forEach> | ||
</table> | ||
</c:when> | ||
<c:otherwise> | ||
<h2 class="w3-wide">not found!</h2> | ||
</c:otherwise> | ||
</c:choose> | ||
</div> | ||
</div> | ||
|
||
|
||
<div class="w3-content" style="max-width: 2000px;"> | ||
<div class="w3-container w3-content w3-center" style="max-width: 800px" > | ||
<h3 class="w3-wide"><spring:message code="menu.tours" /></h3> | ||
<div class="w3-container w3-content w3-center" style="max-width: 200px"> | ||
<p><a href="${tours}" class="w3-btn-block w3-round w3-teal">Available tours</a></p> | ||
<p><a href="${all}" class="w3-btn-block w3-round w3-teal">Weekly schedule</a></p> | ||
<!--p><a href="${from}" class="w3-btn-block w3-round w3-teal">All after...</a></p--> | ||
</div> | ||
</div> | ||
</div> | ||
|
||
<!-- Footer --> | ||
<footer | ||
class="w3-container w3-padding-64 w3-center w3-opacity w3-light-grey w3-xlarge"> | ||
</footer> | ||
|
||
</body> | ||
</html> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters