stadtratmonitor/app/controllers/search_controller.rb
2014-11-19 22:34:14 +01:00

9 lines
236 B
Ruby

class SearchController < ApplicationController
def index
@result = if params[:q].present?
es = Elasticsearch::Client.new
# TODO: Add pagination
es.search index: 'loris', q: params[:q], size: 30
end
end
end