‪TYPO3CMS  11.5
TYPO3\CMS\Impexp\Controller\ImportController Class Reference
Inheritance diagram for TYPO3\CMS\Impexp\Controller\ImportController:
TYPO3\CMS\Impexp\Controller\ImportExportController

Public Member Functions

ResponseInterface mainAction (ServerRequestInterface $request)
 
- ‪Public Member Functions inherited from ‪TYPO3\CMS\Impexp\Controller\ImportExportController
 __construct (IconFactory $iconFactory, PageRenderer $pageRenderer, UriBuilder $uriBuilder, ModuleTemplateFactory $moduleTemplateFactory)
 

Protected Member Functions

 preprocessInputData (array $inData)
 
array handleUpload (ServerRequestInterface $request, array $inData)
 
array importData (array $inData)
 
 getFilePathWithinFileMountBoundaries (string $filePath)
 
 registerDocHeaderButtons ()
 
 makeForm ()
 
File[] getExportFiles ()
 
File ProcessedFile null getFile (string $combinedIdentifier)
 
- ‪Protected Member Functions inherited from ‪TYPO3\CMS\Impexp\Controller\ImportExportController
 main (ServerRequestInterface $request)
 
BackendUserAuthentication getBackendUser ()
 
LanguageService getLanguageService ()
 

Protected Attributes

const NO_UPLOAD = 0
 
const UPLOAD_DONE = 1
 
const UPLOAD_FAILED = 2
 
string $routeName = 'tx_impexp_import'
 
Import $import
 
- ‪Protected Attributes inherited from ‪TYPO3\CMS\Impexp\Controller\ImportExportController
int $id
 
array $pageInfo
 
string $permsClause
 
string $routeName = ''
 
ModuleTemplate $moduleTemplate
 
string $returnUrl
 
LanguageService $lang
 
StandaloneView $standaloneView
 
IconFactory $iconFactory
 
PageRenderer $pageRenderer
 
UriBuilder $uriBuilder
 
ModuleTemplateFactory $moduleTemplateFactory
 

Detailed Description

Main script class for the Import facility

This class is not considered part of the public TYPO3 API.

Definition at line 42 of file ImportController.php.

Member Function Documentation

◆ getExportFiles()

File [] TYPO3\CMS\Impexp\Controller\ImportController::getExportFiles ( )
protected

Gets all export files.

Returns
‪File[]
Exceptions

Definition at line 278 of file ImportController.php.

Referenced by TYPO3\CMS\Impexp\Controller\ImportController\makeForm().

◆ getFile()

File ProcessedFile null TYPO3\CMS\Impexp\Controller\ImportController::getFile ( string  $combinedIdentifier)
protected

Gets a file by combined identifier.

Parameters
string$combinedIdentifier
Returns
‪File|ProcessedFile|null

Definition at line 300 of file ImportController.php.

◆ getFilePathWithinFileMountBoundaries()

TYPO3\CMS\Impexp\Controller\ImportController::getFilePathWithinFileMountBoundaries ( string  $filePath)
protected

◆ handleUpload()

array TYPO3\CMS\Impexp\Controller\ImportController::handleUpload ( ServerRequestInterface  $request,
array  $inData 
)
protected

◆ importData()

array TYPO3\CMS\Impexp\Controller\ImportController::importData ( array  $inData)
protected

Import part of module

Parameters
array$inData
Returns
‪array Modified data
Exceptions

Definition at line 180 of file ImportController.php.

References TYPO3\CMS\Core\Messaging\AbstractMessage\ERROR, and TYPO3\CMS\Impexp\Controller\ImportController\getFilePathWithinFileMountBoundaries().

Referenced by TYPO3\CMS\Impexp\Controller\ImportController\mainAction().

◆ mainAction()

ResponseInterface TYPO3\CMS\Impexp\Controller\ImportController::mainAction ( ServerRequestInterface  $request)

Incoming array has syntax:

id = import page id (must be readable)

file = pointing to filename relative to public web path

[all relation fields are clear, but not files]

  • ‪page-tree is written first
  • ‪then remaining pages (to the root of import)
  • ‪then all other records are written either to related included pages or if not found to import-root (should be a sysFolder in most cases)
  • ‪then all internal relations are set and non-existing relations removed, relations to static tables preserved.
Parameters
ServerRequestInterface$request
Returns
‪ResponseInterface
Exceptions
Exception

Reimplemented from TYPO3\CMS\Impexp\Controller\ImportExportController.

Definition at line 75 of file ImportController.php.

References TYPO3\CMS\Impexp\Controller\ImportExportController\getBackendUser(), TYPO3\CMS\Impexp\Controller\ImportController\handleUpload(), TYPO3\CMS\Impexp\Controller\ImportController\importData(), TYPO3\CMS\Impexp\Controller\ImportExportController\main(), TYPO3\CMS\Impexp\Controller\ImportController\makeForm(), TYPO3\CMS\Impexp\Controller\ImportController\preprocessInputData(), and TYPO3\CMS\Impexp\Controller\ImportController\registerDocHeaderButtons().

◆ makeForm()

TYPO3\CMS\Impexp\Controller\ImportController::makeForm ( )
protected

◆ preprocessInputData()

TYPO3\CMS\Impexp\Controller\ImportController::preprocessInputData ( array  $inData)
protected

◆ registerDocHeaderButtons()

TYPO3\CMS\Impexp\Controller\ImportController::registerDocHeaderButtons ( )
protected

Create the panel of buttons for submitting the form or otherwise perform operations.

Reimplemented from TYPO3\CMS\Impexp\Controller\ImportExportController.

Definition at line 224 of file ImportController.php.

References TYPO3\CMS\Backend\Routing\PreviewUriBuilder\create(), and TYPO3\CMS\Core\Imaging\Icon\SIZE_SMALL.

Referenced by TYPO3\CMS\Impexp\Controller\ImportController\mainAction().

Member Data Documentation

◆ $import

Import TYPO3\CMS\Impexp\Controller\ImportController::$import
protected

Definition at line 54 of file ImportController.php.

◆ $routeName

string TYPO3\CMS\Impexp\Controller\ImportController::$routeName = 'tx_impexp_import'
protected

Definition at line 50 of file ImportController.php.

◆ NO_UPLOAD

const TYPO3\CMS\Impexp\Controller\ImportController::NO_UPLOAD = 0
protected

◆ UPLOAD_DONE

const TYPO3\CMS\Impexp\Controller\ImportController::UPLOAD_DONE = 1
protected

◆ UPLOAD_FAILED

const TYPO3\CMS\Impexp\Controller\ImportController::UPLOAD_FAILED = 2
protected