Magento Customer Prices

In a recent project we had to implement an extension to enable specific prices for each customer. Our customer is a hardware retailer and its customer range varies from the single plumber to huge companies. Companies normally tend to be hard negotiating partner and demand discounts as they order not just a single hammer or nail.

We started out with the extension from Webtex called “Prices per Customer for Magento” (PPC) which implements this functionality in a solid way and everything went pretty good in the beginning. PPC creates an additional table where customer and price relevant data is stored.

But after a while we noticed issues regarding the performance. Especially on views where multiple products are shown. Turned out our customer price table got quiet heavy: 2.2M entries!

Magento’s caching integration is quiet clever and definitely is worth it. But in our case it didn’t really helped as for each customer there could be a special price for each product. How the hell would you cache that?

After some experiments to extend caching, which failed, we again wrapped our heads around the issue. Here’s a solution: Why not request the customer related price in the background? Use the full power of Magento’s cache integration and only request the related prices if needed.

https://bitbucket.org/subsolutions/ajaxcustomerprice/overview

 

Leave a Reply

Your email address will not be published. Required fields are marked *