Notice: You are browsing the documentation for PrestaShop 9, which is currently in development.

You might want to look at the current version, PrestaShop 8. Read the current version of the documentation

Hook actionValidateCartRule

Informations

Alter cart rule validation process Allow modules to implement their own rules to validate a cart rule.
Hook actionValidateCartRule
Locations
FO
Type action
Origin core
Aliases
Description Allow modules to implement their own rules to validate a cart rule.

Located in

Origin File
core classes/CartRule.php

Call of the Hook in the origin file

Hook::exec(
            'actionValidateCartRule',
            [
                'cart_rule' => $this,
                'cart' => $cart,
                'alreadyInCart' => $alreadyInCart,
                'display_error' => $display_error,
                'check_carrier' => $check_carrier,
                'useOrderPrices' => $useOrderPrices,
                'isValidatedByModules' => &$isValidatedByModules,
                'isValidatedByModulesError' => &$isValidatedByModulesError,
            ]
        );