Module: Bastion
- Defined in:
- lib/bastion.rb,
lib/bastion/engine.rb,
lib/bastion/version.rb,
app/helpers/bastion/layout_helper.rb,
app/controllers/bastion/bastion_controller.rb
Defined Under Namespace
Modules: LayoutHelper
Classes: BastionController, Engine
Constant Summary
collapse
- VERSION =
"6.1.23"
- @@plugins =
{}
Class Method Summary
collapse
Class Method Details
.config ⇒ Object
19
20
21
22
23
24
25
26
27
28
29
30
31
|
# File 'lib/bastion.rb', line 19
def self.config
url_root = ENV['RAILS_RELATIVE_URL_ROOT']
base_config = {
'markTranslated' => SETTINGS[:mark_translated] || false,
'relativeUrlRoot' => url_root ? url_root + '/' : '/'
}
Bastion.plugins.each do |name, plugin|
base_config.merge!(plugin[:config]) if plugin[:config]
end
base_config
end
|
.localization_path(locale) ⇒ Object
33
34
35
|
# File 'lib/bastion.rb', line 33
def self.localization_path(locale)
"bastion/angular-i18n/angular-locale_#{locale}.js"
end
|
.plugins ⇒ Object
11
12
13
|
# File 'lib/bastion.rb', line 11
def self.plugins
@@plugins
end
|
.register_plugin(plugin) ⇒ Object
15
16
17
|
# File 'lib/bastion.rb', line 15
def self.register_plugin(plugin)
@@plugins[plugin[:name]] = plugin
end
|