Skip to content

armgit / spree

Public Imported from GitHub
0

Open Source Platform for DTC, B2B Commerce, Marketplaces & Omnichannel. REST APIs, TypeScript SDKs, and production-ready Next.js storefront. Self-host it. Own your data. No vendor lock-in. Zero platform fees.

Fixed: added Australia and Oceania market/zone in seeds (#12176)

Damian Legawiecdfc546ec3a9a
diff --git a/core/app/services/spree/seeds/zones.rb b/core/app/services/spree/seeds/zones.rb
index 47af40c377..bf414261a2 100644
--- a/core/app/services/spree/seeds/zones.rb
+++ b/core/app/services/spree/seeds/zones.rb
@@ -10,12 +10,14 @@ module Spree
Spree::Zone.where(name: 'South America', description: 'South America', kind: 'country').first_or_create!
middle_east = Spree::Zone.where(name: 'Middle East', description: 'Middle East', kind: 'country').first_or_create!
asia = Spree::Zone.where(name: 'Asia', description: 'Asia', kind: 'country').first_or_create!
+ australia_and_oceania = Spree::Zone.where(name: 'Australia and Oceania', description: 'Australia and Oceania', kind: 'country').first_or_create!
create_zone_members(eu_vat, %w(PL FI PT RO DE FR SK HU SI IE AT ES IT BE SE LV BG LT CY LU MT DK NL EE HR CZ GR))
create_zone_members(north_america, %w(US CA))
create_zone_members(middle_east, %w(BH CY EG IR IQ IL JO KW LB OM QA SA SY TR AE YE))
create_zone_members(asia, %w(AF AM AZ BH BD BT BN KH CN CX CC GE HK IN ID IR IQ IL JP JO KZ KW KG LA LB MO MY MV MN MM NP
KP OM PK PS PH QA SA SG KR LK SY TW TJ TH TR TM AE UZ VN YE))
+ create_zone_members(australia_and_oceania, %w(AU NZ))
uk_vat.zone_members.where(zoneable: Spree::Country.find_by(iso: 'GB')).first_or_create!
end