Skip to content

Commit c2f0d22

Browse files
committed
Modify search by catalog form to use GET method instead of POST.
Addressed to #514 No functional changes.
1 parent e579d53 commit c2f0d22

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/main/java/ru/mystamps/web/controller/SeriesController.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -376,7 +376,7 @@ public String processAskForm(
376376
return redirectTo(Url.INFO_SERIES_PAGE, series.getId());
377377
}
378378

379-
@PostMapping(Url.SEARCH_SERIES_BY_CATALOG)
379+
@GetMapping(Url.SEARCH_SERIES_BY_CATALOG)
380380
public String searchSeriesByCatalog(
381381
@RequestParam("catalogNumber") String catalogNumber,
382382
@RequestParam("catalogName") String catalogName,

src/main/webapp/WEB-INF/views/site/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ <h4 class="panel-title" th:text="#{t_in_db}">In our database</h4>
249249
<h4 class="panel-title" th:text="#{t_search_by_catalog}">Search by catalog</h4>
250250
</div>
251251
<div class="panel-body">
252-
<form method="post" action="../series/search_result.html" th:action="@{${SEARCH_SERIES_BY_CATALOG}}">
252+
<form method="get" action="../series/search_result.html" th:action="@{${SEARCH_SERIES_BY_CATALOG}}">
253253
<div class="form-group" th:classappend="${numberIsEmpty != null ? 'has-error' : ''}">
254254
<label for="catalogNumber" th:text="|#{t_number}:|">Number:</label>
255255
<input id="catalogNumber" name="catalogNumber" type="search" class="form-control"

0 commit comments

Comments
 (0)