Example #1
0
 /**
  * {@inheritdoc}
  */
 public function run()
 {
     $this->attributeSetup->run();
     $this->categorySetup->run();
     $this->productSetup->run();
     $this->postInstaller->addSetupResource($this->productLinkSetup);
 }
Example #2
0
 /**
  * {@inheritdoc}
  */
 public function run()
 {
     if (!$this->deployHelper->isMediaPresent()) {
         $this->logger->log('Sample Data Media was not installed. Skipping downloadable product installation');
         return;
     }
     $this->gallery->setFixtures(['Downloadable/images_products_training_video.csv']);
     $downloadableFiles = ['Downloadable/downloadable_data_training_video_download.csv'];
     foreach ($downloadableFiles as $downloadableFile) {
         $downloadableFileName = $this->fixtureHelper->getPath($downloadableFile);
         $csvDownloadableReader = $this->csvReaderFactory->create(['fileName' => $downloadableFileName, 'mode' => 'r']);
         foreach ($csvDownloadableReader as $downloadableRow) {
             $sku = $downloadableRow['product_sku'];
             if (!isset($this->downloadableData[$sku])) {
                 $this->downloadableData[$sku] = [];
             }
             $this->downloadableData[$sku] = $this->converter->getDownloadableData($downloadableRow, $this->downloadableData[$sku]);
             $this->downloadableData[$sku]['sample'] = $this->converter->getSamplesInfo();
         }
     }
     parent::run();
 }
Example #3
0
 /**
  * @inheritdoc
  */
 public function run()
 {
     parent::run();
     $this->eavConfig->clear();
 }