Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix seeder error when overriding Spree::Zone name field with globalize #183

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/views/spree/admin/avatax_settings/show.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
<% unless address_validated_countries.nil? %>
<ul style="list-style: inside;">
<% address_validated_countries.each do |country| %>
<li><%= Spree::Country.find_by_name(country) %></li>
<li><%= Spree::Country.find_by(name: country) %></li>
<% end %>
</ul>
<% end %>
Expand Down
2 changes: 1 addition & 1 deletion lib/solidus_avatax_certified/seeder.rb
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def create_tax
shipping_tax.zone = tax_zone
shipping_tax.show_rate_in_label = false
end
shipping_tax.update!(amount: BigDecimal('0'), zone: ::Spree::Zone.find_by_name('North America'), show_rate_in_label: false, calculator: ::Spree::Calculator::AvalaraTransaction.create!)
shipping_tax.update!(amount: BigDecimal('0'), zone: ::Spree::Zone.find_by(name: 'North America'), show_rate_in_label: false, calculator: ::Spree::Calculator::AvalaraTransaction.create!)
end

def add_tax_category_to_shipping_methods
Expand Down