20 protected $_template =
'Magento_Review::rating/stars/summary.phtml';
53 \
Magento\Review\Model\RatingFactory $ratingFactory,
57 $this->_votesFactory = $votesFactory;
58 $this->_ratingFactory = $ratingFactory;
60 parent::__construct($context,
$data);
70 if ($this->_coreRegistry->registry(
'review_data')) {
71 $this->setReviewId($this->_coreRegistry->registry(
'review_data')->getId());
82 if (!$this->getRatingCollection()) {
85 )->addRatingInfo()->load();
88 return $this->getRatingCollection();
98 if (!$this->getRatingSummaryCache()) {
99 $this->setRatingSummaryCache($this->_ratingFactory->create()->getReviewSummary($this->getReviewId()));
102 return $this->getRatingSummaryCache();
__construct(\Magento\Backend\Block\Template\Context $context, \Magento\Review\Model\ResourceModel\Rating\Option\Vote\CollectionFactory $votesFactory, \Magento\Review\Model\RatingFactory $ratingFactory, \Magento\Framework\Registry $registry, array $data=[])