Sha256: 34727e45e9ba75bb858cc7236df04420b11bd9c5bbaceaf7016caa403cea4f2f
Contents?: true
Size: 1.08 KB
Versions: 3
Compression:
Stored size: 1.08 KB
Contents
module Homeland module Press class Engine < ::Rails::Engine isolate_namespace Homeland::Press initializer 'homeland.press.init' do |app| if Setting.has_module?(:press) app.config.after_initialize do # Because need use I18n.t # must after Rails application initialized will get correct locale Homeland.register_plugin do |plugin| plugin.name = 'press' plugin.display_name = I18n.t('plugin.press') plugin.description = 'A Press/News plugin for Homeland.' plugin.navbar_link = true plugin.admin_navbar_link = true plugin.root_path = "/posts" plugin.admin_path = "/admin/posts" end end User.send :include, Homeland::Press::UserMixin app.routes.prepend do mount Homeland::Press::Engine => '/' end app.config.paths["db/migrate"].concat(config.paths["db/migrate"].expanded) end end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
homeland-press-0.4.1 | lib/homeland/press/engine.rb |
homeland-press-0.4.0 | lib/homeland/press/engine.rb |
homeland-press-0.3.4 | lib/homeland/press/engine.rb |