Sha256: f22cb71faf12512e30cfddaa9eadf01714026b200089668105d1a838d8c55289
Contents?: true
Size: 419 Bytes
Versions: 2
Compression:
Stored size: 419 Bytes
Contents
module Para module Admin class SearchController < ApplicationController include Para::ModelHelper include Para::SearchHelper def index model = params[:model_name].constantize attributes = model_field_mappings(model).fields @results = model.ransack(fulltext_search_param_for(attributes) => params[:search]).result render layout: false end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
para-0.7.1 | app/controllers/para/admin/search_controller.rb |
para-0.7.0 | app/controllers/para/admin/search_controller.rb |