开发者

Filter Magento Product collection for products that have a review

Hi as per title I want to filter for products that have a approved review.

Any help appreciated.

I have a feeling its 开发者_StackOverflow社区based around the rating summary but not sure how to filter for that?

Thanks in advance.

Chris


function getReviews() {
$reviews = Mage::getModel('review/review')->getResourceCollection();
$reviews->addStoreFilter( Mage::app()->getStore()->getId() )
                ->addStatusFilter( Mage_Review_Model_Review::STATUS_APPROVED )
                ->setDateOrder()
                ->addRateVotes()
                ->load();        

return $reviews;

}

Source: Here

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜