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-configurable-product
Controller
Adminhtml
Product
Attribute
SuggestConfigurableAttributes.php
Go to the documentation of this file.
1
<?php
7
namespace
Magento\ConfigurableProduct\Controller\Adminhtml\Product\Attribute
;
8
9
use
Magento\Backend\App\Action
;
10
use
Magento\ConfigurableProduct\Model\SuggestedAttributeList
;
11
12
class
SuggestConfigurableAttributes
extends
Action
13
{
19
const
ADMIN_RESOURCE
=
'Magento_Catalog::products'
;
20
24
protected
$attributeList
;
25
29
protected
$jsonHelper
;
30
36
protected
$storeManager
;
37
44
public
function
__construct
(
45
Action
\
Context
$context,
46
SuggestedAttributeList
$attributeList
,
47
\
Magento
\Framework\Json\Helper\Data
$jsonHelper
,
48
\
Magento
\
Store
\Model\
StoreManagerInterface
$storeManager
49
) {
50
$this->attributeList =
$attributeList
;
51
$this->jsonHelper =
$jsonHelper
;
52
$this->storeManager =
$storeManager
;
53
parent::__construct($context);
54
}
55
61
public
function
execute
()
62
{
63
$this->storeManager->setCurrentStore(\
Magento
\
Store
\Model\
Store::ADMIN_CODE
);
64
65
$this->
getResponse
()->representJson(
66
$this->jsonHelper->jsonEncode(
67
$this->attributeList->getSuggestedAttributes($this->getRequest()->getParam(
'label_part'
))
68
)
69
);
70
}
71
}
Magento\ConfigurableProduct\Controller\Adminhtml\Product\Attribute\SuggestConfigurableAttributes\$jsonHelper
$jsonHelper
Definition:
SuggestConfigurableAttributes.php:29
Magento\ConfigurableProduct\Controller\Adminhtml\Product\Attribute
Definition:
CreateOptions.php:7
Magento\CatalogSearch\Model\Indexer\Fulltext\Store
Definition:
Store.php:17
Magento\ConfigurableProduct\Controller\Adminhtml\Product\Attribute\SuggestConfigurableAttributes\$storeManager
$storeManager
Definition:
SuggestConfigurableAttributes.php:36
Magento\Framework\App\Action\AbstractAction\getResponse
getResponse()
Definition:
AbstractAction.php:70
Magento\ConfigurableProduct\Controller\Adminhtml\Product\Attribute\SuggestConfigurableAttributes
Definition:
SuggestConfigurableAttributes.php:12
Magento\ConfigurableProduct\Controller\Adminhtml\Product\Attribute\SuggestConfigurableAttributes\ADMIN_RESOURCE
const ADMIN_RESOURCE
Definition:
SuggestConfigurableAttributes.php:19
Magento\ConfigurableProduct\Controller\Adminhtml\Product\Attribute\SuggestConfigurableAttributes\execute
execute()
Definition:
SuggestConfigurableAttributes.php:61
Magento\Backend\App\Action
Definition:
Action.php:17
Magento\Store\Model\StoreManagerInterface
Definition:
StoreManagerInterface.php:17
Magento
Magento\Store\Model\Store\ADMIN_CODE
const ADMIN_CODE
Definition:
Store.php:103
Magento\Backend\App\Action\Context
Definition:
Context.php:25
Magento\ConfigurableProduct\Controller\Adminhtml\Product\Attribute\SuggestConfigurableAttributes\__construct
__construct(Action\Context $context, SuggestedAttributeList $attributeList, \Magento\Framework\Json\Helper\Data $jsonHelper, \Magento\Store\Model\StoreManagerInterface $storeManager)
Definition:
SuggestConfigurableAttributes.php:44
Magento\ConfigurableProduct\Controller\Adminhtml\Product\Attribute\SuggestConfigurableAttributes\$attributeList
$attributeList
Definition:
SuggestConfigurableAttributes.php:24
Magento\Backend\App\Action
Definition:
Context.php:6
Magento\ConfigurableProduct\Model\SuggestedAttributeList
Definition:
SuggestedAttributeList.php:10