importService = $importService; } public function doImport() { try { $files = []; foreach (ImportService::$entityTypes as $entityType) { if (Input::file("{$entityType}_file")) { $files[$entityType] = Input::file("{$entityType}_file")->getRealPath(); } } $imported_files = $this->importService->import(Input::get('source'), $files); Session::flash('message', trans('texts.imported_file').' - '.$imported_files); } catch (Exception $exception) { Session::flash('error', $exception->getMessage()); } return Redirect::to('/settings/'.ACCOUNT_IMPORT_EXPORT); } }