Skip to content

Added Date filter and display to search#31

Open
SaffatHasan wants to merge 2 commits into
masterfrom
add-date-to-search
Open

Added Date filter and display to search#31
SaffatHasan wants to merge 2 commits into
masterfrom
add-date-to-search

Conversation

@SaffatHasan

@SaffatHasan SaffatHasan commented Mar 9, 2020

Copy link
Copy Markdown
Owner

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
Copy Markdown
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>

@SaffatHasan SaffatHasan Mar 9, 2020

Copy link
Copy Markdown
Owner Author

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