Describe the bug
Hook displayAdminLogin is not in table ps_hook, so a module can not be hooked manually in this position unless you call registerHook function.
To Reproduce
Steps to reproduce the behavior:
displayAdminLogin. You can unhook and hook module because now position is at ps_hook table.Hook displayAdminLogin should be inserted in ps_hook table in installation.
Additinnal information
PrestaShop version: 1.7.6
Describe the bug
Hook is linked with "multishop" and it shouldn't. It should be executed always, doesn't matter the shop context.
To Reproduce
Steps to reproduce the behavior:
displayAdminLogin is not executeddisplayAdminLogin is executed (appears a string Dummy module under the login box)Hook is only executed if you install module in "All shops" context or in Multistore ID 1, while in BO login page there is not a shop context yet. Query that retrieves module hooks for hook displayAdminLogin should not take into consideration shop context.
Additional information
PrestaShop version: 1.7.6
Hi @idnovate,
Thanks for your report.
First issue:
I manage to reproduce it with PS1.7.6.0beta1 & PS1.7.5.2
v1 of the module => NOK => displayAdminLogin doesn't exist

v2 of the module => OK => displayAdminLogin exist

Second issue:
I manage to reproduce it with PS1.7.6.0beta1 & PS1.7.5.2
if module installed when shop2 is selected => displayAdminLogin is not executed => NOK

if module installed when shop1 is selected => displayAdminLogin is executed => OK

PS: if shop1 / shop2 are selected & we install the module => it will be installed in all shops
I鈥檒l add this to the debug roadmap so that it鈥檚 fixed. If you have already fixed it on your end or if you think you can do it, please do send us a pull request!
Thanks!
Where are the installation and upgrade SQL scripts?
Here 馃槈
https://github.com/PrestaShop/PrestaShop/tree/develop/install-dev/data installation data, including hooks for BDD
https://github.com/PrestaShop/PrestaShop/tree/develop/install-dev/upgrade upgrade script