Prestashop hookActionProductCancel 不起作用

问题描述

我正在为 Prestashop 1.7.7 开发支付模块,我想向 hookActionProductCancel 添加一些功能。我尝试将它添加到我的主 my_module.PHP 文件中,但它不起作用。

public function hookActionProductCancel($params)
{
    Tools::dieObject($params);
}

另外,我注册了钩子:

public function install()
{
    return parent::install()
        && $this->registerHook('header')
        && $this->registerHook('displayPaymentReturn')
        && $this->registerHook('actionProductCancel')
        && $this->registerHook('paymentOptions');
}

解决方法

已解决,这是此处描述的错误 https://github.com/PrestaShop/PrestaShop/issues/20712 并已在 Prestashop 版本 1.7.7.1 上解决