diff --git a/Classes/Helper/GetEventHelper.php b/Classes/Helper/GetEventHelper.php index 9abea54..e0aa88e 100644 --- a/Classes/Helper/GetEventHelper.php +++ b/Classes/Helper/GetEventHelper.php @@ -17,15 +17,22 @@ use Contao\FilesModel; use Contao\InsertTags; use Contao\System; +use Doctrine\ORM\EntityManager; class GetEventHelper { + /** + * @var EntityManager + */ + private $entityManager = null; + /** * GetEventHelper constructor. */ public function __construct() { System::loadLanguageFile('default'); + $this->entityManager = System::getContainer()->get('doctrine.orm.default_entity_manager'); } @@ -35,6 +42,7 @@ public function __construct() */ public function getExportEvent($exportSettings) { + $exportSettings = $this->getSettings($exportSettings); $filename = $this->parseFilename($exportSettings); $foldername = $this->getPath($exportSettings); $event = new ExportRunEvent(); diff --git a/Resources/contao/languages/de/tl_c4g_export.php b/Resources/contao/languages/de/tl_c4g_export.php index c389083..8ce7863 100755 --- a/Resources/contao/languages/de/tl_c4g_export.php +++ b/Resources/contao/languages/de/tl_c4g_export.php @@ -69,6 +69,7 @@ $GLOBALS['TL_LANG'][$strName]['copy'] = array($strElement . ' kopieren', $strElement . ' mit der ID %s kopieren'); $GLOBALS['TL_LANG'][$strName]['delete'] = array($strElement . ' löschen', $strElement . ' mit der ID %s löschen'); $GLOBALS['TL_LANG'][$strName]['show'] = array($strElement . ' anzeigen', 'Details des ' . $strElement . 's mit der ID %s anzeigen'); +$GLOBALS['TL_LANG'][$strName]['runexport'] = ["Export ausführen", "Den Export mit der ID %s ausführen."]; /** Options */ $GLOBALS['TL_LANG'][$strName]['contaodb'] = 'Contao Datenbank'; diff --git a/Resources/contao/languages/en/tl_c4g_export.php b/Resources/contao/languages/en/tl_c4g_export.php index 312d532..c23c8e6 100755 --- a/Resources/contao/languages/en/tl_c4g_export.php +++ b/Resources/contao/languages/en/tl_c4g_export.php @@ -69,6 +69,7 @@ $GLOBALS['TL_LANG'][$strName]['copy'] = array('Copy ' . $strElement, 'Copy ' . $strElement . ' with ID %s'); $GLOBALS['TL_LANG'][$strName]['delete'] = array('Delete ' . $strElement, 'Delete ' . $strElement . ' with ID %s'); $GLOBALS['TL_LANG'][$strName]['show'] = array('Show ' . $strElement, 'Show details of the ' . $strElement . 'with ID %s'); +$GLOBALS['TL_LANG'][$strName]['runexport'] = ["Run export", "Run the export with ID %s."]; /** Options */ $GLOBALS['TL_LANG'][$strName]['contaodb'] = 'Contao Database';