/**
  * Append sales rule product attribute keys to select by quote item collection
  *
  * @param \Magento\Quote\Model\Quote\Config $subject
  * @param array $attributeKeys
  *
  * @return array
  * @SuppressWarnings(PHPMD.UnusedFormalParameter)
  */
 public function afterGetProductAttributes(\Magento\Quote\Model\Quote\Config $subject, array $attributeKeys)
 {
     $attributes = $this->_ruleResource->getActiveAttributes();
     foreach ($attributes as $attribute) {
         $attributeKeys[] = $attribute['attribute_code'];
     }
     return $attributeKeys;
 }
Ejemplo n.º 2
0
 /**
  * {@inheritdoc}
  */
 public function getActiveAttributes()
 {
     $pluginInfo = $this->pluginList->getNext($this->subjectType, 'getActiveAttributes');
     if (!$pluginInfo) {
         return parent::getActiveAttributes();
     } else {
         return $this->___callPlugins('getActiveAttributes', func_get_args(), $pluginInfo);
     }
 }