Module: Plugins::PluginClass::MainHelper
- Included in:
- AdminController, FrontController
- Defined in:
- lib/generators/camaleon_cms/gem_plugin_template/app/helpers/plugins/my_plugin/main_helper.rb
Class Method Summary collapse
Instance Method Summary collapse
-
#pluginKey_on_active(plugin) ⇒ Object
here all actions on going to active you can run sql commands like this: results = ActiveRecord::Base.connection.execute(query); plugin: plugin model.
-
#pluginKey_on_inactive(plugin) ⇒ Object
here all actions on going to inactive plugin: plugin model.
-
#pluginKey_on_upgrade(plugin) ⇒ Object
here all actions to upgrade for a new version plugin: plugin model.
Class Method Details
.included(klass) ⇒ Object
2 3 4 |
# File 'lib/generators/camaleon_cms/gem_plugin_template/app/helpers/plugins/my_plugin/main_helper.rb', line 2 def self.included(klass) # klass.helper_method [:my_helper_method] rescue "" # here your methods accessible from views end |
Instance Method Details
#pluginKey_on_active(plugin) ⇒ Object
here all actions on going to active you can run sql commands like this: results = ActiveRecord::Base.connection.execute(query); plugin: plugin model
10 11 |
# File 'lib/generators/camaleon_cms/gem_plugin_template/app/helpers/plugins/my_plugin/main_helper.rb', line 10 def pluginKey_on_active(plugin) end |
#pluginKey_on_inactive(plugin) ⇒ Object
here all actions on going to inactive plugin: plugin model
15 16 |
# File 'lib/generators/camaleon_cms/gem_plugin_template/app/helpers/plugins/my_plugin/main_helper.rb', line 15 def pluginKey_on_inactive(plugin) end |
#pluginKey_on_upgrade(plugin) ⇒ Object
here all actions to upgrade for a new version plugin: plugin model
20 21 |
# File 'lib/generators/camaleon_cms/gem_plugin_template/app/helpers/plugins/my_plugin/main_helper.rb', line 20 def pluginKey_on_upgrade(plugin) end |