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

@@ -7,8 +7,6 @@ class Admin::Poll::QuestionsController < Admin::Poll::BaseController
def index
@polls = Poll.not_budget
@search = search_params[:search]
@questions = @questions.search(search_params).page(params[:page]).order("created_at DESC")
@proposals = Proposal.successful.sort_by_confidence_score