40 lines
1.6 KiB
Ruby
40 lines
1.6 KiB
Ruby
module Emailer
|
|
module Emailer
|
|
class Engine < ::Rails::Engine
|
|
initializer "emailer" do
|
|
OrbitApp.registration "Emailer", :type => "ModuleApp" do
|
|
module_label "emailer.emailer"
|
|
base_url File.expand_path File.dirname(__FILE__)
|
|
categorizable
|
|
side_bar do
|
|
head_label_i18n 'emailer.emailer', icon_class: "icons-mail"
|
|
available_for "users"
|
|
active_for_controllers (['admin/emailers'])
|
|
head_link_path "admin_emailers_path"
|
|
|
|
context_link 'emailer.all',
|
|
:link_path=>"admin_emailers_path" ,
|
|
:priority=>1,
|
|
:active_for_action=>{'admin/emailers'=>'index'},
|
|
:available_for => 'users'
|
|
|
|
context_link 'new_',
|
|
:link_path=>"new_admin_emailer_path" ,
|
|
:priority=>2,
|
|
:active_for_action=>{'admin/announcements'=>'new'},
|
|
:available_for => 'users'
|
|
|
|
context_link 'categories',
|
|
:link_path=>"admin_module_app_categories_path" ,
|
|
:link_arg=>"{:module_app_id=>ModuleApp.find_by(:key=>'emailer').id}",
|
|
:priority=>3,
|
|
:active_for_action=>{'admin/emailers'=>'categories'},
|
|
:active_for_category => 'Emailer',
|
|
:available_for => 'managers'
|
|
end
|
|
end
|
|
end
|
|
end
|
|
end
|
|
end
|