0

I'm having troubles with Catalog Price rules. I have a rule that says YY% discount on products of manufacturer "X" for all members of customer-group "resellers"

I save and apply the rule (and cron is running so it updates every day), yet it does not work as expected.

The discount correctly shows on the product page, yet once you add the product to the cart, it reverts back to the original price, and this is the same for the actual checkout.

Yet if I create an order from the backend for the same customer, the discount is correctly applied...

Both the cart and the checkout use the stock base/default .phtml files for display of products/price/tax etc...

I've been experiencing this issue with Magento 1.8x, and just upgraded to 1.9.0.1 and still the same issue.

  • What other 3rd party extensions are you using? – JamesAllwood Nov 20 '14 at 22:07
  • @JamesAllwood Currently these extensions are installed: Amasty_Base Amasty_Catcopy Amasty_Imgupload Amasty_Notfound Amasty_Number Amasty_Oaction Amasty_Paction Amasty_Pgrid Aoe_Scheduler Aoe_TemplateHints AvS_ScopeHint Bubble_Queryfier Cm_RedisSession Creare_CreareSeoCore Creare_CreareSeoSitemap Ebizmarts_AbandonedCart Ebizmarts_Autoresponder Ebizmarts_MageMonkey Ebizmarts_Mandrill FireGento_MageSetup FlyWebdesign_PaypalFee Fooman_GoogleAnalyticsPlus Hackathon_LocaleFallback IntegerNet_Autoshipping IntegerNet_RemoveCustomerAccountLinks – Ottonet Nov 20 '14 at 22:26
  • @JamesAllwood - exactly the same extensions/setup as in my dev setup, where everything is working like a charm. Have been studying database differences, yet can't seem to find what's causing this. – Ottonet Nov 20 '14 at 22:27
  • And staging site runs on same server? – JamesAllwood Nov 20 '14 at 22:30
  • Yup. Just different DB and different directory. – Ottonet Nov 20 '14 at 22:36
1

Not a set X to Y solution, but may help you debug this.

I'm not 100% at this point how the catalog price rules are applied to the products in the catalog, but what I can say is that they are applied differently in the catalog to in the cart.

Mage_CatalogRule_Model_Observer::processFrontFinalPrice() is where the catalog rules are applied to the cart items, so for example if I simply add return $this straight away I can replicated the exact behaviour your seeing, with the rules applied in the catalog, and indeed the admin as those are added in processAdminFinalPrice() but the cart rules are not applied.

    public function prepareCatalogProductCollectionPrices(Varien_Event_Observer $observer)
    {
        return $this;
        ...

Not a great answer but atleast this gives you somewhere to look.

Does the same problem happen when you don't set a specific customer group ID but instead select them all?

|improve this answer|||||
  • "Does the same problem happen when you don't set a specific customer group ID but instead select them all?" Well.. I just applied the discount to all websites and all customer groups including Not-logged-in; and hit save&apply. It worked as expected. First I removed not-logged-in and hit save&apply. It still was OK. Then I removed other unwanted groups/websites for this rule and much to my surprise it still works. I still have no idea what went/is wrong, so I'll keep the question open for a few days while monitoring the situation.... Thanks so far! – Ottonet Nov 21 '14 at 14:31
  • 1
    Although I have deleted and recreated the catalog rule many many times, I can confirm that it seems to work in my -original- live db as well (last test was after a dump/import in a new db) - just by selecting a few more groups, save&apply and then removing these groups. Funny thing is that I don't receive a message to clear the cache anymore... While experiencing the problems I got this message everytime after hitting save&apply on this rule. The issue seems to be gone yet I have no clue what or why – Ottonet Nov 21 '14 at 14:52

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.