-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Has many association of variants with prices #8678
Comments
Hi @arjun289 Your initial feeling is correct. Although the query you've provided doesn't mention it the |
@mdavo6 |
I’m currently setting up a spree store now with multiple currencies all running on one domain. I chose to use Spree specifically because spree can handle multiple languages and multiple currencies all in one instance. I was sick of the SEO and content updating nightmare of having multiple stores for multiple currencies. I also have an existing Spree store set up using sub domains for each currency, again all handled from one Spree admin with the multiple domain plugin, either way the multiple currencies setup that Spree uses is a super powerful feature. You can create one SKU and give it many different currencies then have that single product appear in different sub domains stores based on currency, or run a single domain and set the landing currency currencies via a string query in the url or currency switching drop down. |
Hi @arjun289 Agree with @MatthewKennedy 's comments above. You essentially have two options - 1. Multiple stores each with one currency (per your Amazon example) or 2. One store with multiple currencies. As @MatthewKennedy has described, the major benefit from option 2 is less ongoing management - due to the fact you have only one listing to manage for each product vs multiple. Another point to mention is inventory. Depends on the individual specifications of the store, but you may run into issues keeping stock counts accurate across multiple single currency sites. |
Context
I was looking at the spree code for the
variants
entity and found out that it has an associationhas_many
withprices
entity.Ideally seeing this relationship makes me feel, this must have been provided so that
products/variants can have multiple prices in different currencies.
The gentlemen here feels the same
http://grokbase.com/t/gg/spree-user/135ef1d6s3/question-about-variant-has-many-prices
If you look at the solution to this query, it has been mentioned that the feature
products/variants can have multiple prices in different currencies
wasn't the goal of this.I just want to understand then, what's the motive behind keeping this
ha_many
association betweenvariants
andprices
?Expected Behavior
Most of the e-commerce websites usually support only one currency and thus, each variant of a product has only one price.
So, shouldn't the association be
has_one
? If the answer is no, then what could be the possible reasons ?The text was updated successfully, but these errors were encountered: