Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added Date filter and display to search #31

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

SaffatHasan
Copy link
Owner

@SaffatHasan SaffatHasan commented Mar 9, 2020

Added a date to the display and filter the results to only display
Itineraries by date.

closes #34

Added a date to the display and filter the results to only display
Itineraries by date.
public boolean isTripOnDate(String date)
{
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("MM/dd/yyyy");
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you move this code into the constructor of Itinerary instead?

<form action="#" id="userProfileForm" method="post" th:action="@{/trips/search/submit}"
th:object="${TripSearchRequest}">
<label>Departure Date: <input type="text" id="datepicker" th:field="*{date}"></label>
Copy link
Owner Author

@SaffatHasan SaffatHasan Mar 9, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does something like th:type="${#date}" work here?
Saw <p th:text="${#dates.format(standardDate, 'dd-MM-yyyy HH:mm')}"></p> online at this link.

@epp26 epp26 self-assigned this Mar 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Search - Filter By Date
2 participants