예제 #1
0
 public function __construct(\Magento\Framework\Model\Context $context, \Magento\Framework\Registry $registry, \Magento\Framework\Module\ModuleList $moduleList, \Magento\Framework\App\Config\MutableScopeConfigInterface $scopeConfig, \Magento\Framework\UrlInterface $urlBuilder, \Magento\Framework\Session\SessionManagerInterface $session, \Wyomind\Core\Helper\Data $coreHelper, \Magento\Framework\Filesystem\Directory\ReadFactory $directoryRead, \Magento\Framework\Filesystem\File\ReadFactory $fileRead, \Magento\Framework\App\Filesystem\DirectoryList $directoryList, \Magento\Framework\Model\ResourceModel\AbstractResource $resource = null, \Magento\Framework\Data\Collection\AbstractDb $resourceCollection = null, array $data = [])
 {
     parent::__construct($context, $registry, $resource, $resourceCollection, $data);
     $this->_magentoVersion = $coreHelper->getMagentoVersion();
     $this->_moduleList = $moduleList;
     $this->_scopeConfig = $scopeConfig;
     $this->_urlBuilder = $urlBuilder;
     $this->_cacheManager = $context->getCacheManager();
     $this->_session = $session;
     $this->_coreHelper = $coreHelper;
     $root = $directoryList->getPath(\Magento\Framework\App\Filesystem\DirectoryList::ROOT);
     if (file_exists($root . "/vendor/wyomind/")) {
         $this->_directoryRead = $directoryRead->create($root . "/vendor/wyomind/");
     } else {
         $this->_directoryRead = $directoryRead->create($root . "/app/code/Wyomind/");
     }
     $this->_httpRead = $fileRead;
     $this->_directoryList = $directoryList;
     $this->_version = $this->_moduleList->getOne("Wyomind_Core")['setup_version'];
     $this->_refreshCache = false;
     $this->getValues();
     foreach ($this->_values as $ext) {
         $this->checkActivation($ext);
     }
     if ($this->_refreshCache) {
         $this->_cacheManager->clean(['config']);
     }
 }
예제 #2
0
 public function __construct(\Magento\Framework\Model\Context $context, \Magento\Framework\Registry $registry, \Wyomind\Core\Helper\Data $coreHelper, \Wyomind\SimpleGoogleShopping\Logger\Logger $sgsLogger, \Magento\Framework\View\Asset\Repository $assetRepo, \Magento\Store\Model\StoreManagerInterface $storeManager, \Magento\Framework\Message\ManagerInterface $messageManager, \Magento\Framework\Filesystem $filesystem, \Magento\Framework\Stdlib\DateTime\DateTime $coreDate, \Magento\Framework\App\Filesystem\DirectoryList $directoryList, \Magento\Framework\App\ResourceConnection $appResource, \Magento\Tax\Model\ResourceModel\Calculation $taxCalculation, \Magento\Eav\Model\ResourceModel\Entity\Attribute\Option\CollectionFactory $attributeOptionValueCollectionFactory, \Wyomind\SimpleGoogleShopping\Model\ResourceModel\Product\CollectionFactory $productCollectionFactory, \Wyomind\SimpleGoogleShopping\Model\ResourceModel\Functions\CollectionFactory $functionCollectionFactory, \Magento\Store\Model\StoreFactory $storeFactory, \Magento\Catalog\Model\CategoryFactory $categoryFactory, \Magento\Eav\Model\Entity\TypeFactory $attributeTypeFactory, \Magento\Eav\Model\Entity\AttributeFactory $attributeFactory, \Magento\Directory\Model\Currency $currency, \Wyomind\SimpleGoogleShopping\Helper\Parser $parserHelper, \Wyomind\SimpleGoogleShopping\Helper\Data $dataHelper, \Wyomind\SimpleGoogleShopping\Helper\Requirements $requirementsHelper, \Wyomind\SimpleGoogleShopping\Helper\Attributes $attributesHelper, \Wyomind\SimpleGoogleShopping\Model\ResourceModel\TaxClassFactory $taxClassResourceModelFactory, \Wyomind\SimpleGoogleShopping\Model\ResourceModel\ImagesFactory $imagesResourceModelFactory, \Magento\Framework\Model\ResourceModel\AbstractResource $resource = null, \Magento\Framework\Data\Collection\AbstractDb $resourceCollection = null, array $data = [])
 {
     $coreHelper->constructor($this, func_get_args());
     $this->{$this->x0c->x954->{$this->x0c->x954->{$this->x0c->x954->xad3}}} = $assetRepo->{$this->x55->x954->x17bf}();
     $this->{$this->xf0->x954->{$this->xf0->x954->xa16}} = $coreHelper;
     $this->{$this->x55->x954->{$this->x0c->x954->{$this->xf0->x954->x9f5}}} = $sgsLogger;
     $this->{$this->xf0->x954->{$this->x0c->x954->xa03}} = $dataHelper;
     $this->{$this->xf0->x954->{$this->xf0->x954->{$this->x55->x954->xaeb}}} = $assetRepo;
     $this->{$this->x55->x979->{$this->xf0->x979->x2443}} = $storeManager;
     $this->{$this->x55->x954->{$this->x55->x954->{$this->x0c->x954->x9db}}} = $messageManager;
     $this->{$this->xf0->x954->{$this->xf0->x954->{$this->xf0->x954->xafb}}} = $filesystem;
     $this->{$this->xf0->x979->x2416} = $coreDate;
     $this->{$this->x55->x979->{$this->xf0->x979->x244a}} = $directoryList;
     $this->{$this->x55->x954->{$this->x55->x954->{$this->x0c->x954->x9cf}}} = $appResource;
     $this->{$this->x55->x979->x2492} = $taxCalculation;
     $this->{$this->xf0->x954->{$this->x55->x954->xaad}} = $attributeOptionValueCollectionFactory;
     $this->{$this->x55->x954->{$this->x0c->x954->xa84}} = $productCollectionFactory;
     $this->{$this->xf0->x954->{$this->xf0->x954->xb06}} = $functionCollectionFactory;
     $this->{$this->x55->x954->{$this->x55->x954->xa32}} = $storeFactory;
     $this->{$this->xf0->x954->{$this->x55->x954->xa3e}} = $categoryFactory;
     $this->{$this->x55->x954->{$this->x0c->x954->xa4a}} = $attributeTypeFactory;
     $this->{$this->x0c->x954->{$this->x55->x954->xa54}} = $attributeFactory;
     $this->{$this->x55->x954->{$this->x0c->x954->{$this->xf0->x954->{$this->x55->x954->xa68}}}} = $currency;
     $this->{$this->x0c->x954->{$this->xf0->x954->{$this->x0c->x954->{$this->xf0->x954->xa9c}}}} = $parserHelper;
     $this->{$this->xf0->x954->{$this->xf0->x954->{$this->x55->x954->{$this->x55->x954->xac2}}}} = $requirementsHelper;
     $this->{$this->x0c->x979->{$this->x0c->x979->x24b9}} = $attributesHelper;
     $this->{$this->xf0->x979->{$this->x55->x979->x2515}} = $this->{$this->xf0->x954->{$this->xf0->x954->{$this->xf0->x954->xafb}}}->{$this->x0c->x954->x17d3}(\Magento\Framework\App\Filesystem\DirectoryList::ROOT);
     $this->{$this->xf0->x979->x2519} = $filesystem->{$this->x0c->x954->x17d3}(\Magento\Framework\App\Filesystem\DirectoryList::ROOT);
     $this->taxClassResourceModelFactory = $taxClassResourceModelFactory;
     $this->{$this->xf0->x954->{$this->xf0->x954->{$this->x55->x954->{$this->x0c->x954->xb29}}}} = $imagesResourceModelFactory->{$this->x0c->x954->x17e7}();
     $this->{$this->x0c->x954->{$this->x55->x954->xb10}} = $taxClassResourceModelFactory->{$this->x0c->x954->x17e7}();
     parent::__construct($context, $registry, $resource, $resourceCollection, $data);
 }