Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
On a fresh install, I've selected Euro as default currency.
After adding products and going through the checkout process, i've noticed the shipping prices are still in $
Comments
Comment #1
Cookiz CreditAttribution: Cookiz commentedComment #2
vasikeindeed. i found that in the "commerce_kickstart_product" features module, the Flat Rate Services are built with "USD" currency.
I created a patch that change settings to use the "commerce_default_currency"
Comment #3
vasikealso commited with Gerrit : https://code.drupalcommerce.org/#/c/103/
Comment #4
GuGuss CreditAttribution: GuGuss commentedComment #5
davereplicant CreditAttribution: davereplicant commentedHi
I hope I've been able to add this to the right part of the original post.
I'm experiencing the Shipping bug and I can't seem to fix it - I've found the relevant file in a different location to the one mentioned.
I have GBP set as my currency and the Shipping insists on being DOLLARS.
If you choose Express shipping the page freezes.
I wish I was able to be more help here, am I doing something wrong by replacing the line
'currency_code' => variable_get('commerce_default_currency', 'USD'),
When I do this it still doen't work.
Thanks in advance.
Dave
Comment #6
pcambraOption one: implement an alter hook to the services and provide the correct currency.
This has the risk of altering a currency that the user has set on purpose so it will override an user setting which is bad. Needs testing if this alter can notice if the service has been altered and not override the user setting.
Moving the service creation to install is the second option.
Comment #7
jsacksick CreditAttribution: jsacksick commentedWe can't implement the second option as the shipping services can only be defined via the hooks, the attached patch check if the currency code of the defined service is enabled, if not then we're setting the currency to the default currency of the site.
Comment #8
bojanz CreditAttribution: bojanz commented#7 sounds like it would also modify shipping services that don't belong to the demo store.
Could we use a features preprocess hook instead? (if any?)
Comment #9
vasikewithin #7 patch, alter only its own defined shipping services.
i don't think features provides a way to alter this, as a features preprocess hook
Comment #10
vasikehere is gerrit commit for limiting changes to its own defined shipping services:
https://code.drupalcommerce.org/#/c/683/
my previous patch was a mess.
Comment #11
lsolesen CreditAttribution: lsolesen commented@vasike han you create it as a regular patch against latest version
Comment #12
vasike@lsolesen: almost missed, lucky i faced this issue working on other module within kickstart.
here it is.
Comment #13
mglamanComment #14
rszrama CreditAttribution: rszrama at Centarro commentedCommerce Kickstart 2.x is in minimal maintenance mode. Closing out all outdated tickets now to maintain focus on Commerce Kickstart 3.x.