* @copyright Since 2007 PrestaShop SA and Contributors * @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0) */ namespace PrestaShop\PrestaShop\Core\ConstraintValidator\Constraints; use PrestaShop\PrestaShop\Core\ConstraintValidator\ReductionValidator; use Symfony\Component\Validator\Constraint; /** * Constraint for validating reduction */ final class Reduction extends Constraint { public $invalidTypeMessage = 'Reduction type "%type%" is invalid. Allowed types are: %types%.'; public $invalidAmountValueMessage = 'Reduction value "%value%" is invalid. It must be greater than 0.'; public $invalidPercentageValueMessage = 'Reduction value "%value%" is invalid. Value must be more than zero and maximum %max%.'; /** * {@inheritdoc} */ public function validatedBy() { return ReductionValidator::class; } }