Revert "Allow overriding the search form action (preserving filters)"
This reverts commit 1b579184e0962689c95e6b72cef9bcf6d139fbb2. This is very error prone since I'm using GET
- Id
- cf8c51c0467f132cd9ceba3f423a23c77d8f89ca
- Author
- Caio
- Commit time
- 2019-05-21T12:43:13+02:00
Modified src/main/java/co/caio/tablier/model/SiteInfo.java
}
@Value.Default
- default String searchAction() {
- return "/search";
- }
-
- @Value.Default
default String searchValue() {
return "";
}
Modified src/main/java/co/caio/tablier/view/searchform.rocker.html
<h2 class="subtitle">
Over a million recipes, zero ads.
</h2>
-<form action="@site.searchAction()" method="get">
+<form action="/search?#results" method="get">
<div class="field has-addons has-addons-centered">
<div class="control">
<input class="input" @if (site.isUnstable()) { disabled } type="search" name="q" @if (site.searchIsAutoFocus()) { autofocus } placeholder="Ingredients, diets, etc." value="@site.searchValue()">