/** * Runs the actual export */ public function run() { $repository = Shopware()->Models()->getRepository('Shopware\\CustomModels\\Bundle\\Bundle'); /** @var Shopware\CustomModels\Bundle\Bundle $bundle */ foreach ($repository->findAll() as $bundle) { try { PlentymarketsMappingController::getItemBundleByShopwareID($bundle->getId()); continue; } catch (PlentymarketsMappingExceptionNotExistant $e) { } $exportEntityItemBundle = new PlentymarketsExportEntityItemBundle($bundle); $exportEntityItemBundle->export(); } }