Example #1
0
 public function __construct(\Magento\Backend\Model\UrlInterface $url, \Magento\Eav\Model\Config $config, \Magento\Eav\Model\ResourceModel\Entity\Attribute\Set\Collection $attrSetCollection, \Magento\Catalog\Model\ProductFactory $productFactory, \Magento\Framework\Locale\FormatInterface $localeFormat, \Ess\M2ePro\Model\Factory $modelFactory, \Ess\M2ePro\Helper\Factory $helperFactory, \Magento\Rule\Model\Condition\Context $context, array $data = [])
 {
     $this->url = $url;
     $this->config = $config;
     $this->attrSetCollection = $attrSetCollection;
     $this->productFactory = $productFactory;
     $this->localeFormat = $localeFormat;
     parent::__construct($modelFactory, $helperFactory, $context, $data);
 }
Example #2
0
 public function __construct(\Ess\M2ePro\Model\Factory $modelFactory, \Ess\M2ePro\Helper\Factory $helperFactory, \Magento\Rule\Model\Condition\Context $context, array $data = [])
 {
     $this->_logger = $context->getLogger();
     parent::__construct($modelFactory, $helperFactory, $context, $data);
     $this->setType('Magento\\Rule\\Model\\Condition\\Combine')->setAggregator('all')->setValue(true)->setConditions(array())->setActions(array());
     $this->loadAggregatorOptions();
     if ($options = $this->getAggregatorOptions()) {
         foreach ($options as $aggregator => $dummy) {
             $this->setAggregator($aggregator);
             break;
         }
     }
 }
Example #3
0
 /**
  * @param Context $context
  * @param array $data
  */
 public function __construct(Context $context, array $data = [])
 {
     $this->_conditionFactory = $context->getConditionFactory();
     $this->_logger = $context->getLogger();
     parent::__construct($context, $data);
     $this->setType('Magento\\Rule\\Model\\Condition\\Combine')->setAggregator('all')->setValue(true)->setConditions([])->setActions([]);
     $this->loadAggregatorOptions();
     $options = $this->getAggregatorOptions();
     if ($options) {
         foreach (array_keys($options) as $aggregator) {
             $this->setAggregator($aggregator);
             break;
         }
     }
 }