Cross Reference:
xref
: /
ontohub
/
app
/
controllers
/
entities_search_controller.rb
Home
History
Annotate
Line#
Navigate
Download
Search
only in
./
entities_search_controller.rb revision 28c62a48f3ecfd2a6a44552bf9bac888fae7a6a5
#
# Allow searching for entities
#
class
EntitiesSearchController
<
ApplicationController
def
index
@
query
=
params
[:q]
@
max_groups
=
100
if
@
query.blank
?
@
query
=
nil
else
@
search
=
Entity.search
_with_ontologies
(@
query
, @
max_groups
)
@
group
= @
search.group
(:
ontology_id_str
)
@
groups
= @
group.groups
end
end
end