ActiveTypoScriptController extends AbstractTemplateModuleController
The "TypoScript -> Active TypoScript" Backend module
This is a specific Backend Controller implementation and is not considered part of the Public TYPO3 API.
Attributes
- #[AsController]
Table of Contents
Properties
- $connectionPool : ConnectionPool
- $iconFactory : IconFactory
- $siteFinder : SiteFinder
- $uriBuilder : UriBuilder
Methods
- __construct() : mixed
- editAction() : ResponseInterface
- Edit a single property. Linked from "show" view when clicking a property.
- indexAction() : ResponseInterface
- Default view renders options, constant and setup conditions, constant and setup tree.
- injectConnectionPool() : mixed
- injectDataHandler() : mixed
- injectIconFactory() : void
- injectSiteFinder() : mixed
- injectUriBuilder() : mixed
- updateAction() : ResponseInterface
- Add a line to selected sys_template record of given page after editing or clearing a property or adding a child in 'edit' view. Update either 'constants' or 'config' field using DataHandler, add a flash message and redirect to default "show" action.
- addPreviewButtonToDocHeader() : void
- createExtensionTemplateAction() : ResponseInterface
- Action shared by info/modify ond constant editor to create a new "extension template"
- createNewWebsiteTemplateAction() : ResponseInterface
- Action shared by info/modify ond constant editor to create a new "site template"
- getAllTemplateRecordsOnPage() : array<string|int, mixed>
- Get an array of all template records on a page.
- getBackendUser() : BackendUserAuthentication
- getClosestAncestorPageWithTemplateRecord() : array<string|int, mixed>
- Get the closest page row that has a template up in rootline
- getFirstTemplateRecordOnPage() : array<string, mixed>|false
- Get a single sys_template record attached to a single page.
- getLanguageService() : LanguageService
- getScopedRootline() : array<string|int, mixed>
- getTemplateQueryBuilder() : QueryBuilder
- Helper method to prepare the query builder for getting sys_template records from a given pid.
Properties
$connectionPool
protected
ConnectionPool
$connectionPool
$iconFactory
protected
IconFactory
$iconFactory
$siteFinder
protected
SiteFinder
$siteFinder
$uriBuilder
protected
UriBuilder
$uriBuilder
Methods
__construct()
public
__construct(ContainerInterface $container, ModuleTemplateFactory $moduleTemplateFactory, FlashMessageService $flashMessageService, SysTemplateRepository $sysTemplateRepository, SysTemplateTreeBuilder $treeBuilder) : mixed
Parameters
- $container : ContainerInterface
- $moduleTemplateFactory : ModuleTemplateFactory
- $flashMessageService : FlashMessageService
- $sysTemplateRepository : SysTemplateRepository
- $treeBuilder : SysTemplateTreeBuilder
editAction()
Edit a single property. Linked from "show" view when clicking a property.
public
editAction(ServerRequestInterface $request) : ResponseInterface
Parameters
- $request : ServerRequestInterface
Return values
ResponseInterfaceindexAction()
Default view renders options, constant and setup conditions, constant and setup tree.
public
indexAction(ServerRequestInterface $request) : ResponseInterface
Parameters
- $request : ServerRequestInterface
Return values
ResponseInterfaceinjectConnectionPool()
public
injectConnectionPool(ConnectionPool $connectionPool) : mixed
Parameters
- $connectionPool : ConnectionPool
injectDataHandler()
public
injectDataHandler(DataHandler $dataHandler) : mixed
Parameters
- $dataHandler : DataHandler
injectIconFactory()
public
injectIconFactory(IconFactory $iconFactory) : void
Parameters
- $iconFactory : IconFactory
injectSiteFinder()
public
injectSiteFinder(SiteFinder $siteFinder) : mixed
Parameters
- $siteFinder : SiteFinder
injectUriBuilder()
public
injectUriBuilder(UriBuilder $uriBuilder) : mixed
Parameters
- $uriBuilder : UriBuilder
updateAction()
Add a line to selected sys_template record of given page after editing or clearing a property or adding a child in 'edit' view. Update either 'constants' or 'config' field using DataHandler, add a flash message and redirect to default "show" action.
public
updateAction(ServerRequestInterface $request) : ResponseInterface
Parameters
- $request : ServerRequestInterface
Return values
ResponseInterfaceaddPreviewButtonToDocHeader()
protected
addPreviewButtonToDocHeader(ModuleTemplate $view, int $pageId, int $dokType) : void
Parameters
- $view : ModuleTemplate
- $pageId : int
- $dokType : int
createExtensionTemplateAction()
Action shared by info/modify ond constant editor to create a new "extension template"
protected
createExtensionTemplateAction(ServerRequestInterface $request, string $redirectTarget) : ResponseInterface
Parameters
- $request : ServerRequestInterface
- $redirectTarget : string
Return values
ResponseInterfacecreateNewWebsiteTemplateAction()
Action shared by info/modify ond constant editor to create a new "site template"
protected
createNewWebsiteTemplateAction(ServerRequestInterface $request, string $redirectTarget) : ResponseInterface
Parameters
- $request : ServerRequestInterface
- $redirectTarget : string
Return values
ResponseInterfacegetAllTemplateRecordsOnPage()
Get an array of all template records on a page.
protected
getAllTemplateRecordsOnPage(int $pageId) : array<string|int, mixed>
Parameters
- $pageId : int
Return values
array<string|int, mixed>getBackendUser()
protected
getBackendUser() : BackendUserAuthentication
Return values
BackendUserAuthenticationgetClosestAncestorPageWithTemplateRecord()
Get the closest page row that has a template up in rootline
protected
getClosestAncestorPageWithTemplateRecord(int $pageId) : array<string|int, mixed>
Parameters
- $pageId : int
Return values
array<string|int, mixed>getFirstTemplateRecordOnPage()
Get a single sys_template record attached to a single page.
protected
getFirstTemplateRecordOnPage(int $pageId[, int $templateUid = 0 ]) : array<string, mixed>|false
If multiple template records are on this page, the first (order by sorting) record will be returned, unless a specific template uid is specified via $templateUid
Parameters
- $pageId : int
-
The pid to select sys_template records from
- $templateUid : int = 0
-
Optional template uid
Return values
array<string, mixed>|false —Returns the template record or false if none was found
getLanguageService()
protected
getLanguageService() : LanguageService
Return values
LanguageServicegetScopedRootline()
protected
getScopedRootline(SiteInterface $site, array<string|int, mixed> $fullRootLine) : array<string|int, mixed>
Parameters
- $site : SiteInterface
- $fullRootLine : array<string|int, mixed>
Return values
array<string|int, mixed>getTemplateQueryBuilder()
Helper method to prepare the query builder for getting sys_template records from a given pid.
protected
getTemplateQueryBuilder(int $pid) : QueryBuilder
Parameters
- $pid : int