33 lines
1.2 KiB
Ruby
33 lines
1.2 KiB
Ruby
module Space
|
|
class Engine < ::Rails::Engine
|
|
initializer "space" do
|
|
OrbitApp.registration "Space", :type => "ModuleApp" do
|
|
module_label "space.space"
|
|
base_url File.expand_path File.dirname(__FILE__)
|
|
frontend_enabled
|
|
categorizable
|
|
side_bar do
|
|
head_label_i18n 'space.space', icon_class: "icons-leaf"
|
|
available_for "users"
|
|
active_for_controllers (['admin/spaces'])
|
|
head_link_path "admin_spaces_path"
|
|
|
|
context_link 'space.buildings',
|
|
:link_path=>"admin_spaces_path" ,
|
|
:priority=>1,
|
|
:active_for_action=>{'admin/spaces'=>'index'},
|
|
:available_for => 'users'
|
|
|
|
context_link 'categories',
|
|
:link_path=>"admin_module_app_categories_path" ,
|
|
:link_arg=>"{:module_app_id=>ModuleApp.find_by(:key=>'space').id}",
|
|
:priority=>3,
|
|
:active_for_action=>{'admin/spaces'=>'categories'},
|
|
:active_for_category => 'Announcement',
|
|
:available_for => 'managers'
|
|
end
|
|
end
|
|
end
|
|
end
|
|
end
|