Encountered an issue when selecting product options using the swatches in product details page wherein the price of the item in a previously selected currency gets displayed instead of the corresponding price in the currently selected currency. Disabling Block HTML cache type seems to prevent this issue from happening.




Correct equivalent price in the current currency should be displayed
The price in the previously selected currency gets displayed
internal jira to track this : MAGETWO-60977
Updated to Magento 2.1.3 and it seems the issue has worsened. When switching to JPY, the correct price briefly shows up, then suddenly gets multiplied resulting to a very high product price.
Price in AUD after clicking product options:

Price in GBP after clicking product options:

Price in JPY upon page load:

And then after a few seconds or once the document is completely loaded:

Also having this issue.. Upgraded to Magento 2.1.3 and getting really odd prices until you select a swatch. Using configurable products w/ swatches and multi-currency. Unlike @eldonbite , it's still happening for me when I disable block cache.
edit: actually, sometimes choosing a swatch doesn't fix the price..
@dthampy There's already MAGETWO-62682, which should be the same as MAGETWO-60977, no?
@erfanimani, MAGETWO-62682 created for tracking #7941 is a duplicate.
The same issue. Do you have a quick fix?
@AlexanderVekerik No quick fix as far as I'm aware. Do post it if you figure it out.
Same bug, Who knows when it will be fixed?
Same bug here, Magento 2.1.3, double conversion rate with all configurable products when no options selected and displaying prices in a different currency than the base currency.
Did anyone figure out a fix, please?
Doesn't seem it got fixed in 2.1.4 :(
@erfanimani It's predictable, mate. It won't fixed till Magento 3, I guess.
Seems to be patched here: https://github.com/magento/magento2/pull/8593/files/92a6e89f97e68222565539d87c1006f93d155513
@mmansoorebay Actually, this needs to be re-opened. The main issue here doesn't seem to have been solved and is still happening for me on a stock M2.1.4 install: When on a configurable product page and having selected a different currency than the base one - correct price shows up briefly, then gets swapped out for a wrong value which seems to have double conversion rate applied. Regardless of using catalog rule discounts or not.
To be exact, the correct price shows up, until the priceBox JS module is loaded. priceBox gets its config from Magento\Catalog\Block\Product\View::getJsonConfig, and I'm assuming there's a double conversion going on in there for configurable products and it's chosen as the minimum price, until an option is chosen. Hope that helps - will look into it some more.
CC @orlangur
Actually, disregard my comment. The fix for the double conversion seems to have been pulled into the development branch of Magento 2 - I didn't see the diff for it referenced in this thread, so assumed it wasn't fixed. @mmansoorebay @orlangur
Diff/patches:
edit: and it was fixed back in November (but never pulled into a release), before this issue was even created! :') I guess the joke's on me
Hi @erfanimani, I cannot give you any official answer or reopen ticket anyway as I'm not a part of Magento :)
For such cases - when issue is really important, fixed but not backported to 2.1.x yet - it may be worth reporting new issue explicitly stating 2.1.x problem referring to this one and appropriate commit. It is especially useful with reference to commits - if you cherry-picked some from develop and it fixed the problem for your 2.1.x instance - as it would simplify backporting.
I saw in some other ticket here statement "there are lot of fixes not backported, vote for important ones so that we can define priorities".
Thanks @orlangur, I do think this issue is really important - it essentially prevents stores from using configurable products in combination with multi-currency (and I don't understand why not more people are complaining about it).
I think at least Magento should put a message in the ticket saying that the fix for this is already in the development branch. I only found out after figuring out exactly where in the code the bug is located, and then looking in the development branch and seeing that it was already fixed, almost half a year ago.
I don't like opening a new Github issue though - there are already so many new tickets being created, and it seems to be a massive overhead for them to filter through it, and it doesn't seem the right place to report a backport. Maybe I'll try the forums.
Anyhow, for anyone looking to solve the same bug - it's already fixed in the two commits I posted earlier. Keep in mind that, when "patching" through DI/preference, you'll also need to add the getCacheKeyInfo to Magento\Swatches\Block\Product\Renderer\Configurable.
CC @dthampy
@erfanimani Regarding to your previous comment, could you give me a lead about
Keep in mind that, when "patching" through DI/preference, you'll also need to add the
getCacheKeyInfotoMagento\Swatches\Block\Product\Renderer\Configurable.
Are you mean MagentoConfigurableProductBlockProductViewTypeConfigurable? Because that is the class name which added getCacheKeyInfo in the two commits you posted.
Thanks.
Hi Toan,
If you patch through DI, meaning if you create a class that rewrites the
class referenced in the commit, you'll also need to rewrite that swatches
class I posted, because it directly extends from
Magento\ConfigurableProduct\Block\Product\View\Type\Configurable.
Hope that made sense.
On 9 Mar 2017 6:28 PM, "Toan Nguyen" notifications@github.com wrote:
@erfanimani https://github.com/erfanimani Regarding to your previous
comment, could you give me a lead about
Keep in mind that, when "patching" through DI/preference, you'll also need
to add the getCacheKeyInfo to MagentoSwatchesBlock
ProductRendererConfigurable.
Are you mean MagentoConfigurableProductBlockProductViewTypeConfigurable?
Because that is the class name which added getCacheKeyInfo in the two
commits you posted.
Thanks.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/magento/magento2/issues/7371#issuecomment-285314314,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AA4ypqWSA6THxp5ZBTEC_YtmWhhid5uCks5rj9Q5gaJpZM4KtJJe
.
@erfanimani I don't know how could you solve this problem, but seem this pull request can't work for me.
I added getCacheKeyInfo to Magento\Swatches\Block\Product\Renderer\Configurable.
The price is not correct after you choose a new currency, for e.g 32AUD -> 10.37GBP (must be 18.36GBP). This price is only correct if I choose a swatch, the first load of configurable product doesn't display the correct price....
Do you have any idea about this?
@nntoan Sorry no, I did exactly the same as that PR, except that I also added the getCacheKeyInfo method to Magento\Swatches\Block\Product\Renderer\Configurable (in addition to Magento\ConfigurableProduct\Block\Product\View\Type\Configurable.
That did the job for me.
There's also another issue related to this one, and it seems if you have catalog price rules, the same symptoms of this bug happen.
@orlangur can you help me with this currency issue for my multi store view multi currency site ?please
@niko7869 please check 2.1-develop branch first, this issue was probably fixed in https://github.com/magento/magento2/pull/9841. If not, two comments by @erfanimani https://github.com/magento/magento2/issues/7371#issuecomment-282458188 and https://github.com/magento/magento2/issues/7371#issuecomment-285582524 are probably describing solution which worked for him.
@oroskodias thank you for reply but i dont know what to do as i m not developer :(
i dont know what to do as i m not developer :(
@niko7869 Have you tried hiring a developer? =)
Otherwise you're largely on your own. This is a bugtracker, not a help desk.
If you are looking for help or an advice, you might have better chances on the Community Forums or the Magento Stack Exchange
@korostii thank you for your opinion about the issue :)
Not sure if this is the correct solution, but this worked for me on 2.1.9.
Changed vendormagentomodule-catalogBlockProductView.php Line: 237-262 with this code:
$config = [
'productId' => $product->getId(),
'priceFormat' => $this->_localeFormat->getPriceFormat(),
'prices' => [
'oldPrice' => [
'amount' =>
$product->getPriceInfo()->getPrice('regular_price')->getAmount()->getValue()
,
'adjustments' => []
],
'basePrice' => [
'amount' =>
$product->getPriceInfo()->getPrice('final_price')->getAmount()->getBaseAmount()
,
'adjustments' => []
],
'finalPrice' => [
'amount' =>
$product->getPriceInfo()->getPrice('final_price')->getAmount()->getValue()
,
'adjustments' => []
]
],
'idSuffix' => '_clone',
'tierPrices' => $tierPrices
];
@traff1kash That's a different story, this is reproducible after you setup catalog price rule.
@traff1kash Thanks for posting solution. Your solution work for me.
Most helpful comment
Thanks @orlangur, I do think this issue is really important - it essentially prevents stores from using configurable products in combination with multi-currency (and I don't understand why not more people are complaining about it).
I think at least Magento should put a message in the ticket saying that the fix for this is already in the development branch. I only found out after figuring out exactly where in the code the bug is located, and then looking in the development branch and seeing that it was already fixed, almost half a year ago.
I don't like opening a new Github issue though - there are already so many new tickets being created, and it seems to be a massive overhead for them to filter through it, and it doesn't seem the right place to report a backport. Maybe I'll try the forums.
Anyhow, for anyone looking to solve the same bug - it's already fixed in the two commits I posted earlier. Keep in mind that, when "patching" through DI/preference, you'll also need to add the
getCacheKeyInfotoMagento\Swatches\Block\Product\Renderer\Configurable.CC @dthampy