NewContentElementController
New Content element wizard. This is the modal that pops up when clicking "+content" in page module, which will trigger wizardAction() since there is a colPos given. Method positionMapAction() is triggered for instance from the list module "+content" on tt_content table header, and from list module doc-header "+" and then "Click here for wizard".
This class is a specific Backend controller implementation and is not considered part of the Public TYPO3 API.
Attributes
- #[AsController]
Table of Contents
Properties
- $backendViewFactory : BackendViewFactory
- $colPos : int|null
- If set, the content is destined for a specific column.
- $dependencyOrderingService : DependencyOrderingService
- $eventDispatcher : EventDispatcherInterface
- $id : int
- $pageInfo : array<string|int, mixed>
- $returnUrl : string
- $sys_language : int
- $uid_pid : int
- $uriBuilder : UriBuilder
Methods
- __construct() : mixed
- handleRequest() : ResponseInterface
- Process incoming request and dispatch to the requested action
- getAppendWizards() : array<string|int, mixed>
- getBackendUser() : BackendUserAuthentication
- getLanguageService() : LanguageService
- getWizards() : array<string|int, mixed>
- Returns the array of elements in the wizard display.
- loadAvailableWizards() : array<string|int, mixed>
- loadAvailableWizardsFromContentElements() : array<string|int, mixed>
- loadAvailableWizardsFromPluginSubTypes() : array<string|int, mixed>
- mergeContentElementWizardsWithPageTSConfigWizards() : array<string|int, mixed>
- This method merges Content Element wizards defined by TCA with wizards defined in PageTSConfig.
- migrateCommonGroupToDefault() : array<string, array<string|int, mixed>>
- This method returns the wizard items, defined in Page TSconfig for b/w compatibility.
- migratePositionalCommonGroupToDefault() : array<string|int, mixed>
- positionMapAction() : ResponseInterface
- Renders the position map
- prepareDependencyOrdering() : array<string|int, mixed>
- Prepare a wizard tab configuration for sorting.
- prepareWizardItem() : array<string|int, mixed>
- removeInvalidWizardItems() : array<string|int, mixed>
- Checks the array for elements which might contain invalid default values and will unset them! Looks for the "defaultValues" key in each element and if found it will traverse that array as fieldname / value pairs and check.
- removeWizardsByPageTs() : array<string|int, mixed>
- wizardAction() : ResponseInterface
- Renders the wizard
Properties
$backendViewFactory read-only
protected
BackendViewFactory
$backendViewFactory
$colPos
If set, the content is destined for a specific column.
protected
int|null
$colPos
= null
$dependencyOrderingService read-only
protected
DependencyOrderingService
$dependencyOrderingService
$eventDispatcher read-only
protected
EventDispatcherInterface
$eventDispatcher
$id
protected
int
$id
= 0
$pageInfo
protected
array<string|int, mixed>
$pageInfo
= []
$returnUrl
protected
string
$returnUrl
= ''
$sys_language
protected
int
$sys_language
= 0
$uid_pid
protected
int
$uid_pid
= 0
$uriBuilder read-only
protected
UriBuilder
$uriBuilder
Methods
__construct()
public
__construct(UriBuilder $uriBuilder, BackendViewFactory $backendViewFactory, EventDispatcherInterface $eventDispatcher, DependencyOrderingService $dependencyOrderingService) : mixed
Parameters
- $uriBuilder : UriBuilder
- $backendViewFactory : BackendViewFactory
- $eventDispatcher : EventDispatcherInterface
- $dependencyOrderingService : DependencyOrderingService
handleRequest()
Process incoming request and dispatch to the requested action
public
handleRequest(ServerRequestInterface $request) : ResponseInterface
Parameters
- $request : ServerRequestInterface
Return values
ResponseInterfacegetAppendWizards()
protected
getAppendWizards(array<string|int, mixed> $wizardElements) : array<string|int, mixed>
Parameters
- $wizardElements : array<string|int, mixed>
Return values
array<string|int, mixed>getBackendUser()
protected
getBackendUser() : BackendUserAuthentication
Return values
BackendUserAuthenticationgetLanguageService()
protected
getLanguageService() : LanguageService
Return values
LanguageServicegetWizards()
Returns the array of elements in the wizard display.
protected
getWizards() : array<string|int, mixed>
For the plugin section there is support for adding elements there from a global variable.
Return values
array<string|int, mixed>loadAvailableWizards()
protected
loadAvailableWizards(string $typeField[, bool $isPluginSubType = false ]) : array<string|int, mixed>
Parameters
- $typeField : string
- $isPluginSubType : bool = false
Return values
array<string|int, mixed>loadAvailableWizardsFromContentElements()
protected
loadAvailableWizardsFromContentElements() : array<string|int, mixed>
Return values
array<string|int, mixed>loadAvailableWizardsFromPluginSubTypes()
protected
loadAvailableWizardsFromPluginSubTypes() : array<string|int, mixed>
Remove in v14, when "sub types" are removed altogether
Return values
array<string|int, mixed>mergeContentElementWizardsWithPageTSConfigWizards()
This method merges Content Element wizards defined by TCA with wizards defined in PageTSConfig.
protected
mergeContentElementWizardsWithPageTSConfigWizards(array<string|int, mixed> $contentElementWizards, array<string|int, mixed> $pageTsConfigWizards) : array<string|int, mixed>
PageTS has precedence. It might happen that both TCA and PageTS define an entry with exactly the same default values. In such a case, the automatically added TCA entry is dropped.
Parameters
- $contentElementWizards : array<string|int, mixed>
- $pageTsConfigWizards : array<string|int, mixed>
Return values
array<string|int, mixed>migrateCommonGroupToDefault()
This method returns the wizard items, defined in Page TSconfig for b/w compatibility.
protected
migrateCommonGroupToDefault(array<string, array<string|int, mixed>> $wizardsFromPageTs) : array<string, array<string|int, mixed>>
Additionally, it migrates previously defined wizard items in the
common
group to the new default
group, which is defined in TCA.
Parameters
- $wizardsFromPageTs : array<string, array<string|int, mixed>>
Return values
array<string, array<string|int, mixed>>migratePositionalCommonGroupToDefault()
protected
migratePositionalCommonGroupToDefault(array<string|int, mixed> $wizards) : array<string|int, mixed>
Parameters
- $wizards : array<string|int, mixed>
Return values
array<string|int, mixed>positionMapAction()
Renders the position map
protected
positionMapAction(ServerRequestInterface $request) : ResponseInterface
Parameters
- $request : ServerRequestInterface
Return values
ResponseInterfaceprepareDependencyOrdering()
Prepare a wizard tab configuration for sorting.
protected
prepareDependencyOrdering(array<string|int, mixed> $wizardGroup, string $key) : array<string|int, mixed>
Parameters
- $wizardGroup : array<string|int, mixed>
- $key : string
Return values
array<string|int, mixed>prepareWizardItem()
protected
prepareWizardItem(array<string|int, mixed> $itemConf) : array<string|int, mixed>
Parameters
- $itemConf : array<string|int, mixed>
Return values
array<string|int, mixed>removeInvalidWizardItems()
Checks the array for elements which might contain invalid default values and will unset them! Looks for the "defaultValues" key in each element and if found it will traverse that array as fieldname / value pairs and check.
protected
removeInvalidWizardItems(array<string|int, mixed> $wizardItems) : array<string|int, mixed>
Parameters
- $wizardItems : array<string|int, mixed>
Return values
array<string|int, mixed>removeWizardsByPageTs()
protected
removeWizardsByPageTs(array<string|int, mixed> $wizards, mixed $wizardsItemsPageTs) : array<string|int, mixed>
Parameters
- $wizards : array<string|int, mixed>
- $wizardsItemsPageTs : mixed
Return values
array<string|int, mixed>wizardAction()
Renders the wizard
protected
wizardAction(ServerRequestInterface $request) : ResponseInterface
Parameters
- $request : ServerRequestInterface