Sha256: 190ec908bd9a5c8e43885fcc3e439cf4efb9a07ab710cd2186fde0abe3f9aee2
Contents?: true
Size: 843 Bytes
Versions: 4
Compression:
Stored size: 843 Bytes
Contents
module SpreeZaezCorreios class Engine < Rails::Engine require 'spree/core' isolate_namespace Spree engine_name 'spree_zaez_correios' # use rspec for tests config.generators do |g| g.test_framework :rspec end def self.activate Dir.glob(File.join(File.dirname(__FILE__), '../../app/**/*_decorator*.rb')) do |c| Rails.configuration.cache_classes ? require(c) : load(c) end end initializer 'spree_zaez_correios.register.calculators' do |app| app.config.spree.calculators.shipping_methods << Spree::Calculator::Shipping::PAC app.config.spree.calculators.shipping_methods << Spree::Calculator::Shipping::SEDEX app.config.spree.calculators.shipping_methods << Spree::Calculator::Shipping::SEDEX10 end config.to_prepare &method(:activate).to_proc end end
Version data entries
4 entries across 4 versions & 1 rubygems