0

目录定价规则中的 Magento 1.8.0.0 中是否存在错误。我正在尝试以适当的价格获取数据馈送,但 1.8.0.0 什么也没吐出,而 1.8.1.0 给了我我想要的东西。

$store_id = 1; // Use the default store
$discounted_price = Mage::getResourceModel('catalogrule/rule')->getRulePrice( 
                Mage::app()->getLocale()->storeTimeStamp($store_id), 
                Mage::app()->getStore($store_id)->getWebsiteId(), 
                Mage::getSingleton('customer/session')->getCustomerGroupId(), 
                $_product->getId());

// if the product isn't discounted then default back to the original price
echo $discounted_price;`

不幸的是,我的开发服务器在 1.8.1.0 上,而我的实时站点正在运行 1.8.0.0,任何人都可以提出修复建议。我应该添加前端价格和促销价格都正确显示,所以数据就在某个地方,现在不知道从哪里检索它。

4

1 回答 1

0

这是 Magento CE 1.8.0.0 中的一个错误,已在 1.8.1.0 中修复

如果您只想要修复而不是升级您的实时站点,请使用此修复:

https://bitbucket.org/gferon/magento-1.8-catalogrule-fix/overview

这是在产品上应用现有规则的另一种解决方法。

http://www.techytalk.info/catalog-price-rules-not-being-applied-after-product-save-magento-ce-1-8-0-0/

希望对你有帮助

于 2014-03-20T12:22:42.027 回答