problems with product combinations #15946
Labels
1.7.6.1
Affects versions
BO
Category: Back Office
Bug
Type: Bug
Combinations
Product type: issue about products with combinations
No change required
Resolution: issue closed because expected as is
Old Products Page
Concerns the old product page
The Prestashop version is 1.7.6.1, the default language is Romanian and the default currency is RON. When the product does not have combinations everything works fine, when the combinations are added there is thrown an 500 error: An exception has been thrown during the rendering of a template ("Catchable Fatal Error: Object of class Currency could not be converted to string").
The issue can be found in the file src/PrestaShopBundle/Resources/views/Admin/Product/ProductPage/Forms/form_combination.html.twig (line 32) ( {{ default_currency }}) and anytime the default currency is requested in the file (for the price).
The php file that is generated from the twig file contains the following text "($context["default_currency"] ?? $this->getContext($context, "default_currency"))". When the text is replaced with "RON" everything works fine again (at least until the cache is erased and / or debug mode is off).
The text was updated successfully, but these errors were encountered: