Sha256: 4fd912ac931f87b8bf26b34c172514292f1d4b0988062de311477ab0df270725

Contents?: true

Size: 328 Bytes

Versions: 42

Compression:

Stored size: 328 Bytes

Contents

north_america = Spree::Zone.find_by!(name: 'North America')
clothing = Spree::TaxCategory.find_by!(name: 'Clothing')

Spree::TaxRate.where(
  name: 'North America',
  zone: north_america,
  amount: 0.05,
  tax_category: clothing
).first_or_create! do |tax_rate|
  tax_rate.calculator = Spree::Calculator::DefaultTax.create!
end

Version data entries

42 entries across 42 versions & 1 rubygems

Version Path
spree_sample-4.0.9 db/samples/tax_rates.rb
spree_sample-4.0.8 db/samples/tax_rates.rb
spree_sample-3.7.14.1 db/samples/tax_rates.rb
spree_sample-4.0.7.1 db/samples/tax_rates.rb
spree_sample-4.0.7 db/samples/tax_rates.rb
spree_sample-3.7.14 db/samples/tax_rates.rb
spree_sample-4.0.6 db/samples/tax_rates.rb
spree_sample-3.7.13 db/samples/tax_rates.rb
spree_sample-4.0.5 db/samples/tax_rates.rb
spree_sample-3.7.12 db/samples/tax_rates.rb
spree_sample-4.0.4 db/samples/tax_rates.rb
spree_sample-3.7.11 db/samples/tax_rates.rb
spree_sample-3.7.10 db/samples/tax_rates.rb
spree_sample-4.0.3 db/samples/tax_rates.rb
spree_sample-3.7.9 db/samples/tax_rates.rb
spree_sample-4.0.2 db/samples/tax_rates.rb
spree_sample-3.7.8 db/samples/tax_rates.rb
spree_sample-4.0.1 db/samples/tax_rates.rb
spree_sample-3.7.7 db/samples/tax_rates.rb
spree_sample-4.0.0 db/samples/tax_rates.rb