Merge pull request #5327 from NamelessContributor/feat-count-search

post counts: add search field.
This commit is contained in:
evazion
2022-11-04 02:16:36 -05:00
committed by GitHub

View File

@@ -3,6 +3,13 @@
<div id="c-counts"> <div id="c-counts">
<div id="a-posts"> <div id="a-posts">
<h1>Post Counts</h1>
<%= search_form_for(posts_counts_path) do |f| %>
<%= f.input :tags, label: "Tags", input_html: { value: params[:tags], data: { autocomplete: "tag-query" }, name: "tags" } %>
<%= f.submit "Search" %>
<% end %>
Post count for <%= link_to params[:tags].present? ? params[:tags] : "/posts", posts_path(:tags => params[:tags]) %>: Post count for <%= link_to params[:tags].present? ? params[:tags] : "/posts", posts_path(:tags => params[:tags]) %>:
<% if @count.nil? %> <% if @count.nil? %>
timed out timed out