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-sales-rule
Model
Plugin
QuoteConfigProductAttributes.php
Go to the documentation of this file.
1
<?php
6
namespace
Magento\SalesRule\Model\Plugin
;
7
8
use
Magento\Store\Model\StoreManagerInterface
;
9
use
Magento\Customer\Model\Session
;
10
use
Magento\SalesRule\Model\ResourceModel\Rule
as
RuleResource
;
11
12
class
QuoteConfigProductAttributes
13
{
17
protected
$_ruleResource
;
18
22
public
function
__construct
(
RuleResource
$ruleResource)
23
{
24
$this->_ruleResource = $ruleResource;
25
}
26
36
public
function
afterGetProductAttributes
(\
Magento
\
Quote
\Model\
Quote
\
Config
$subject, array $attributeKeys)
37
{
38
$attributes
= $this->_ruleResource->getActiveAttributes();
39
foreach
(
$attributes
as
$attribute
) {
40
$attributeKeys[] =
$attribute
[
'attribute_code'
];
41
}
42
return
$attributeKeys;
43
}
44
}
Magento\Customer\Model\Session
Definition:
Storage.php:8
$attribute
$attribute
Definition:
attribute_set_with_image_attribute.php:41
Magento\SalesRule\Model\Plugin\QuoteConfigProductAttributes\__construct
__construct(RuleResource $ruleResource)
Definition:
QuoteConfigProductAttributes.php:22
Magento\SalesRule\Model\Plugin\QuoteConfigProductAttributes\$_ruleResource
$_ruleResource
Definition:
QuoteConfigProductAttributes.php:17
Magento\SalesRule\Model\Plugin\QuoteConfigProductAttributes\afterGetProductAttributes
afterGetProductAttributes(\Magento\Quote\Model\Quote\Config $subject, array $attributeKeys)
Definition:
QuoteConfigProductAttributes.php:36
Magento\Store\Model\StoreManagerInterface
Definition:
StoreManagerInterface.php:17
Magento\SalesRule\Model\ResourceModel\Rule
Definition:
CollectionTest.php:6
Magento\SalesRule\Model\Plugin
Definition:
QuoteConfigProductAttributes.php:6
Magento
$attributes
$attributes
Definition:
matrix.phtml:13
Magento\Framework\DB\Platform\Quote
Definition:
Quote.php:13
Magento\Framework\App\ResourceConnection\Config
Definition:
Config.php:14
Magento\SalesRule\Model\Plugin\QuoteConfigProductAttributes
Definition:
QuoteConfigProductAttributes.php:12