Reuse admin search component in other sections

There are some sections where we are not reusing it:

* The budget investments search is completely different, so this
  component isn't appropriate there
* Booth assignment and officers are slightly different, and I'm not
  entirely sure it's safe to refactor these cases
This commit is contained in:
Javi Martín
2020-12-03 17:33:57 +01:00
parent a9427f5971
commit e33794e45e
17 changed files with 49 additions and 112 deletions

View File

@@ -5,7 +5,10 @@
<h2><%= t("admin.debates.index.title") %></h2>
<% if @debates.any? %>
<%= render "/admin/shared/debate_search", url: admin_debates_path %>
<%= render Admin::SearchComponent.new(
url: admin_debates_path,
label: t("admin.shared.debate_search.placeholder")
) %>
<h3 class="inline-block"><%= page_entries_info @debates %></h3>