Magento Extensions Rating 2024
EXTENSIONS BY CATEGORY
B2B (Business-To-Business)
Blog
Customer
ERP (Enterprise Resource Planning)
Mega Menu
One Step Checkout
Order
POS (Point Of Sale)
Search
Shopping Cart
Sitemap
SEO
Social
Stock & Inventory Management
EXTENSIONS BY DEVELOPER
aheadWorks
Amasty
Boost My Shop
BSS Commerce
Magestore
MageWorx
Mirasvit
Templates Master
Wyomind
XTENTO
Magento 2 Documentation
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
vendor
magento
module-review
Controller
Adminhtml
Product.php
Go to the documentation of this file.
1
<?php
6
namespace
Magento\Review\Controller\Adminhtml
;
7
8
use
Magento\Backend\App\Action
;
9
use
Magento\Backend\App\Action\Context
;
10
use
Magento\Framework\Registry
;
11
use Magento\Review\Model\ReviewFactory;
12
use Magento\Review\Model\RatingFactory;
13
17
abstract
class
Product
extends
Action
18
{
24
protected
$_publicActions
= [
'edit'
];
25
31
protected
$coreRegistry
=
null
;
32
38
protected
$reviewFactory
;
39
45
protected
$ratingFactory
;
46
53
public
function
__construct
(
54
Context
$context,
55
Registry
$coreRegistry
,
56
ReviewFactory
$reviewFactory
,
57
RatingFactory
$ratingFactory
58
) {
59
$this->coreRegistry =
$coreRegistry
;
60
$this->reviewFactory =
$reviewFactory
;
61
$this->ratingFactory =
$ratingFactory
;
62
parent::__construct($context);
63
}
64
68
protected
function
_isAllowed
()
69
{
70
switch
($this->
getRequest
()->getActionName()) {
71
case
'pending'
:
72
return
$this->_authorization->isAllowed(
'Magento_Review::pending'
);
73
break
;
74
default
:
75
return
$this->_authorization->isAllowed(
'Magento_Review::reviews_all'
);
76
break
;
77
}
78
}
79
}
Magento\Review\Controller\Adminhtml
Magento\Review\Controller\Adminhtml\Product
Definition:
Product.php:17
Magento\Review\Controller\Adminhtml\Product\__construct
__construct(Context $context, Registry $coreRegistry, ReviewFactory $reviewFactory, RatingFactory $ratingFactory)
Definition:
Product.php:53
Magento\Framework\App\Action\AbstractAction\getRequest
getRequest()
Definition:
AbstractAction.php:60
Magento\Review\Controller\Adminhtml\Product\$coreRegistry
$coreRegistry
Definition:
Product.php:31
Magento\Backend\App\Action
Definition:
Action.php:17
Magento\Review\Controller\Adminhtml\Product\$_publicActions
$_publicActions
Definition:
Product.php:24
Magento\Review\Controller\Adminhtml\Product\$reviewFactory
$reviewFactory
Definition:
Product.php:38
Magento\Review\Controller\Adminhtml\Product\$ratingFactory
$ratingFactory
Definition:
Product.php:45
Magento\Review\Controller\Adminhtml\Product\_isAllowed
_isAllowed()
Definition:
Product.php:68
Magento\Backend\App\Action\Context
Definition:
Context.php:25
Magento\Framework\Registry
Definition:
Registry.php:18
Magento\Backend\App\Action
Definition:
Context.php:6