Sha256: 1d651573d086563afada3511ef3a4768d441712c77bf1d06d72dc2c76aa6a661

Contents?: true

Size: 833 Bytes

Versions: 6

Compression:

Stored size: 833 Bytes

Contents

require 'sofa_gallery'
require 'rails'
require 'paperclip'

module CmsGallery
  class Engine < Rails::Engine
    initializer 'sofa_gallery.helper' do |app|
      if defined?(ComfortableMexicanSofa)
        # applying configuraion
        SofaGallery.configure do |conf|
          conf.admin_route_prefix = ComfortableMexicanSofa.config.admin_route_prefix
          conf.upload_options     = ComfortableMexicanSofa.config.upload_file_options
          conf.admin_controller   = 'CmsAdmin::BaseController'
          conf.form_builder       = 'ComfortableMexicanSofa::FormBuilder'
        end
        # applying nav elements
        ComfortableMexicanSofa::ViewHooks.add(:navigation, '/sofa_gallery/admin/navigation')
        ComfortableMexicanSofa::ViewHooks.add(:html_head, '/sofa_gallery/admin/html_head')
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
sofa_gallery-0.0.6 lib/sofa_gallery/engine.rb
sofa_gallery-0.0.5 lib/sofa_gallery/engine.rb
sofa_gallery-0.0.4 lib/sofa_gallery/engine.rb
sofa_gallery-0.0.3 lib/sofa_gallery/engine.rb
sofa_gallery-0.0.2 lib/sofa_gallery/engine.rb
sofa_gallery-0.0.1 lib/sofa_gallery/engine.rb