Because of this PR:
https://github.com/PrestaShop/PrestaShop/pull/15297
Module developers are unable to determine if product is refreshed in quick view context or not.
We should be able to check wether module is displayed in quick view or not, previously it was possible.
Steps to reproduce the "good" behavior from 1.7.6:
ps_sharebuttons module installed and enabled/themes/classic/modules/ps_sharebuttons/views/templates/hook/ps_sharebuttons.tpl<pre>{$smarty.post|@print_r}</pre>[action] => quickview
[id_product] => 1
[id_product_attribute] => 1
[action] => quickviewOf course this is wrong that id_product_attribute is not updated etc. and at the end #15297 is helping with that but, let's check this on 1.7.7 now:
ps_sharebuttons module installed and enabled/themes/classic/modules/ps_sharebuttons/views/templates/hook/ps_sharebuttons.tpl<pre>{$smarty.post|@print_r}</pre> [action] => quickview
[id_product] => 1
[id_product_attribute] => 1
[ajax] => 1
[action] => refresh
[quantity_wanted] => 1
As you can see action is different than in 1.7.6, because of this I can't as a module developer check from .tpl if module is in quick view or not, because of this some of modules I work with doesn't work.
PR to follow.
Thanks for opening this issue! We will help you to keep its state consistent
Hi @kpodemski ,
I did manage to reproduce your issue in PS 1.7.7.
Result I have in PS 1.7.7 :
Array
(
[ajax] => 1
[action] => refresh
[quantity_wanted] => 1
)
Instead of, like it is in PS 1.7.6 :
Array
(
[action] => quickview
[id_product] => 1
[id_product_attribute] => 1
)
I will add this to the debug roadmap. Thanks for the PR !
@kpodemski I'm sorry but I fail to understand how PR https://github.com/PrestaShop/PrestaShop/pull/15297 could have created this issue. The PR only wraps a hook inside a div 馃 I know PrestaShop has sometimes very weird trick up its sleeves, but that one would be a magical one 馃寛 ?
@matks ajax, as discussed on Slack 馃憤馃徎
Fixed by #21362