src/Resources/contao/classes/Backup.php
/**
	 * Generate the module's output
	 *
	 * @return	string
	 */
Generate the module's output
@return      string
Generate the module ' s output @return string
public function generate() {
		switch (\Input::get('action')) {
			case 'download':
				$this->downloadExportFile();
				break;
			case 'upload':
				$this->uploadImportFile();
				break;
			case 'cleanup-upload':
				$this->removeImportFile();
				break;
			case 'analysis':
				if (\Input::get('step')) {
					die(json_encode($this->analyseImport(\Input::get('step'))));
				}
				break;
			case 'import-action':
				if (\Input::get('item') !== null && \Input::get('index') !== null) {
					die(json_encode($this->importDoItemAction(\Input::get('item'), \Input::get('index'))));
				}
				break;
			case 'import-group':
				if (\Input::get('group')) {
					die(json_encode($this->importDoNextGroupAction(\Input::get('group'))));
				}
				break;
		}
		if (!$this->Template->lexA) {
			$this->Template->lexA = "generate";
		}
		else {
			$this->Template->lexA .= ",generate";
		}
		$GLOBALS['TL_CSS'][] = 'bundles/hoerelectroniccontaoimport/style.css';
		$GLOBALS['TL_JAVASCRIPT'][] = 'bundles/hoerelectroniccontaoimport/fx.js';
		\System::loadLanguageFile('tl_isobackup');
		return parent::generate();
	}
public function generate ( ) { switch ( \ Input :: get ( 'action' ) ) { case 'download' : $ this -> downloadExportFile ( ) ; break ; case 'upload' : $ this -> uploadImportFile ( ) ; break ; case 'cleanup-upload' : $ this -> removeImportFile ( ) ; break ; case 'analysis' : if ( \ Input :: get ( 'step' ) ) { die ( json_encode ( $ this -> analyseImport ( \ Input :: get ( 'step' ) ) ) ) ; } break ; case 'import-action' : if ( \ Input :: get ( 'item' ) !== null && \ Input :: get ( 'index' ) !== null ) { die ( json_encode ( $ this -> importDoItemAction ( \ Input :: get ( 'item' ) , \ Input :: get ( 'index' ) ) ) ) ; } break ; case 'import-group' : if ( \ Input :: get ( 'group' ) ) { die ( json_encode ( $ this -> importDoNextGroupAction ( \ Input :: get ( 'group' ) ) ) ) ; } break ; } if ( ! $ this -> Template -> lexA ) { $ this -> Template -> lexA = " generate " ; } else { $ this -> Template -> lexA .= " ,generate " ; } $ GLOBALS [ 'TL_CSS' ] [ ] = 'bundles/hoerelectroniccontaoimport/style.css' ; $ GLOBALS [ 'TL_JAVASCRIPT' ] [ ] = 'bundles/hoerelectroniccontaoimport/fx.js' ; \ System :: loadLanguageFile ( 'tl_isobackup' ) ; return parent :: generate ( ) ; }
Generate the module's output
 @return      string
Generate the module ' s output @return string
// $return = [ // 	'introduction' => [], // ]; // if (\BackendUser::getInstance()->isAdmin) { //     $objTemplate = new \BackendTemplate('be_isobackup_introduction'); // 	$return['introduction']['label'] = &$GLOBALS['TL_LANG']['tl_isobackup']['title_legend']; //     $return['introduction']['html']  = $objTemplate->parse(); // }