I need to develop a function in the cart rules.

Basically it is to check the amount that is added in the cart and apply a fixed price to the product.

I have in mind how to apply the logic. But I need to see the functionality of magento to observe the cart and be able to validate this rule.

I know it's the SalesRule extension but I can not find the correct classes.


You have to check Magento\SalesRule\Model\Validator. This is the main class from where validation is checking.

Rules validator classes are exits at


Rules render at admin from Magento\SalesRule\Model\Rule\Condition\Combine

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.