0

I am looking for a good working solution to prevent Magento 2.4 to apply catalogrules to products that have a special price.

When trying to do it via a plugin/override on getMatchingProductIds from Magento\CatalogRule\Model\Rule and then checking the product id's for special prices is costing a lot of time resulting in some rules taking over an hour.

1 Answer 1

1

One way you could do it is to put your discounted products in to a hidden category, then exclude that category from your catalog rules.

E.g, create a category "Discounted items", set "enabled" to false, then select the products with special prices. Update your catalogue rules Conditions to "Category IS NOT X".

You'll have to make sure all products are in the category, including all Simple products belonging to Configurable items.

1
  • 1
    While I would agree with this solution, it's not manageable for 1000 catalog rules and over 100k products. And very error prone. As people who create a new rule would always have to keep this in mind.
    – JJ15
    Feb 10 at 7:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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