Cross Reference: languages_controller.rb
xref
: /
ontohub
/
app
/
controllers
/
languages_controller.rb
Home
History
Annotate
Line#
Navigate
Download
Search
only in
./
languages_controller.rb revision 7c7f3cf9415077b18027586822f15ac1dafbbaa3
422
N/A
#
422
N/A
# Controller for Languages
422
N/A
#
422
N/A
class
LanguagesController
<
InheritedResources
::
Base
422
N/A
422
N/A
respond_to
:
json
, :
xml
422
N/A
has_pagination
422
N/A
has_scope
:
search
422
N/A
422
N/A
load_and_authorize_resource
:
except
=> [:
index
, :
show
]
422
N/A
422
N/A
def
index
422
N/A
super
do
|
format
|
422
N/A
format.html
do
422
N/A
@
search
=
params
[:
search
]
422
N/A
@
search
=
nil
if
@
search.blank
?
422
N/A
end
422
N/A
end
422
N/A
end
422
N/A
422
N/A
def
create
422
N/A
@
language.user
=
current_user
422
N/A
super
422
N/A
end
422
N/A
422
N/A
def
show
422
N/A
super
do
|
format
|
422
N/A
format.html
do
422
N/A
@
mappings_from
=
resource.mappings
_from
422
N/A
@
mappings_to
=
resource.mappings
_to
422
N/A
@
relation_list
||=
RelationList.new
[
resource
, :
supports
],
422
N/A
:
model
=>
Support
,
422
N/A
:
collection
=>
resource.supports
,
422
N/A
:
association
=> :
logic
,
422
N/A
:
scope
=> [
Logic
]
422
N/A
end
422
N/A
end
422
N/A
end
422
N/A
422
N/A
end
422
N/A