Jump to content

Discounts slowing down the store


sawyer_sp

Recommended Posts

Good morning everyone,

 

I noticed that my store is very slow when I create discount rules and apply them to certain categories. I usually use 5 rules and they are associated with categories 10% OFF, 20% OFF, 30% OFF, 40% OFF and 50% OFF. Therefore, whenever I associate a product with a certain category, it automatically gets the category discount. This way, I can link several products to the category at once and thus get the desired discount, without having to go into each product and set the discount I want. However, I noticed that the store is much slower. When I set individual discounts, within the registration of each product, the store flows better. So should I always do it like this?

Link to comment
Share on other sites

Hi,

To diagnose the performance issue with category-based discount rules, you can use PrestaShop's Debug Profiler to identify the root cause. Here's how they can do it:
In the PrestaShop back office, go to Advanced Parameters > Performance.
Scroll to Debug Mode and enable Debug profiling.

Check for slow queries related to cart_rule, product, or category.
Review which part (queries, hooks, or loading) takes the most time.

This will help pinpoint whether category discount rules or specific queries are causing the slowdown.

If Category discount is causing the issue, then try assigning the discounts directly to products.

Regards.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...