PageLayoutController

The Web > Page module.

Attributes
#[AsController]

Table of Contents

Properties

$availableLanguages  : array<string|int, SiteLanguage>
$backendLayoutRenderer  : BackendLayoutRenderer
$backendLayoutView  : BackendLayoutView
$currentSelectedLanguage  : int
$eventDispatcher  : EventDispatcherInterface
$iconFactory  : IconFactory
$id  : int
Page uid for which to make the listing
$MOD_MENU  : array<string|int, mixed>
$moduleData  : ModuleData|null
$moduleProvider  : ModuleProvider
$moduleTemplateFactory  : ModuleTemplateFactory
$pageinfo  : array<string|int, mixed>|bool
Current page record
$pageRenderer  : PageRenderer
$pageRepository  : PageRepository
$uriBuilder  : UriBuilder

Methods

__construct()  : mixed
mainAction()  : ResponseInterface
Injects the request object for the current request or subrequest As this controller goes only through the main() method, it is rather simple for now
addJavaScriptModuleInstructions()  : void
createPageLayoutContext()  : PageLayoutContext
generateMessagesForCurrentPage()  : array<string|int, mixed>
Return an array of various messages for the current page record, such as if the page has a special doktype, that can be rendered as info boxes.
getBackendUser()  : BackendUserAuthentication
getLanguageService()  : LanguageService
getLocalizedPageRecord()  : array<string|int, mixed>|null
getNumberOfHiddenElements()  : int
Returns the number of hidden elements (including those hidden by start/end times) on the current page (for the current site language)
getPageLinksWhereContentIsAlsoShownOn()  : string
Get all pages with links where the content of a page $pageId is also shown on.
getShortcutTitle()  : string
Returns the shortcut title for the current page
getTargetPageIfVisible()  : array<string|int, mixed>
Returns the target page if visible
initialize()  : void
initializeClipboard()  : void
Initializes the clipboard for generating paste links dynamically via JavaScript after each "+ Content" symbol
isContentEditable()  : bool
Check if content can be edited by current user
isPageEditable()  : bool
Check if page can be edited by current user.
makeActionMenu()  : void
This creates the dropdown menu with the different actions this module is able to provide.
makeButtons()  : void
This creates the buttons for the modules
makeCloseButton()  : ButtonInterface|null
makeEditButton()  : ButtonInterface|null
Edit Button
makeLanguageSwitchButton()  : ButtonInterface|null
Language Switch
makeViewButton()  : ButtonInterface|null
View Button
menuConfig()  : void
Initialize menu array
resolveExternalUrl()  : string
Returns the redirect URL for the input page row IF the doktype is set to 3.

Properties

$currentSelectedLanguage

protected int $currentSelectedLanguage

$eventDispatcher read-only

protected EventDispatcherInterface $eventDispatcher

$id

Page uid for which to make the listing

protected int $id = 0

$MOD_MENU

protected array<string|int, mixed> $MOD_MENU

$pageinfo

Current page record

protected array<string|int, mixed>|bool $pageinfo = false

Methods

__construct()

public __construct(IconFactory $iconFactory, PageRenderer $pageRenderer, UriBuilder $uriBuilder, PageRepository $pageRepository, ModuleTemplateFactory $moduleTemplateFactory, EventDispatcherInterface $eventDispatcher, ModuleProvider $moduleProvider, BackendLayoutRenderer $backendLayoutRenderer, BackendLayoutView $backendLayoutView) : mixed
Parameters
$iconFactory : IconFactory
$pageRenderer : PageRenderer
$uriBuilder : UriBuilder
$pageRepository : PageRepository
$moduleTemplateFactory : ModuleTemplateFactory
$eventDispatcher : EventDispatcherInterface
$moduleProvider : ModuleProvider
$backendLayoutRenderer : BackendLayoutRenderer
$backendLayoutView : BackendLayoutView

mainAction()

Injects the request object for the current request or subrequest As this controller goes only through the main() method, it is rather simple for now

public mainAction(ServerRequestInterface $request) : ResponseInterface
Parameters
$request : ServerRequestInterface
Return values
ResponseInterface

addJavaScriptModuleInstructions()

protected addJavaScriptModuleInstructions() : void

createPageLayoutContext()

protected createPageLayoutContext(ServerRequestInterface $request, array<string|int, mixed> $tsConfig) : PageLayoutContext
Parameters
$request : ServerRequestInterface
$tsConfig : array<string|int, mixed>
Return values
PageLayoutContext

generateMessagesForCurrentPage()

Return an array of various messages for the current page record, such as if the page has a special doktype, that can be rendered as info boxes.

protected generateMessagesForCurrentPage(ServerRequestInterface $request) : array<string|int, mixed>
Parameters
$request : ServerRequestInterface
Return values
array<string|int, mixed>

getLocalizedPageRecord()

protected getLocalizedPageRecord(int $languageId) : array<string|int, mixed>|null
Parameters
$languageId : int
Return values
array<string|int, mixed>|null

getNumberOfHiddenElements()

Returns the number of hidden elements (including those hidden by start/end times) on the current page (for the current site language)

protected getNumberOfHiddenElements(DrawingConfiguration $drawingConfiguration) : int
Parameters
$drawingConfiguration : DrawingConfiguration
Return values
int

getPageLinksWhereContentIsAlsoShownOn()

Get all pages with links where the content of a page $pageId is also shown on.

protected getPageLinksWhereContentIsAlsoShownOn(int $pageId) : string
Parameters
$pageId : int
Return values
string

getShortcutTitle()

Returns the shortcut title for the current page

protected getShortcutTitle() : string
Return values
string

getTargetPageIfVisible()

Returns the target page if visible

protected getTargetPageIfVisible(array<string|int, mixed> $targetPage) : array<string|int, mixed>
Parameters
$targetPage : array<string|int, mixed>
Return values
array<string|int, mixed>

initialize()

protected initialize(ServerRequestInterface $request) : void
Parameters
$request : ServerRequestInterface

initializeClipboard()

Initializes the clipboard for generating paste links dynamically via JavaScript after each "+ Content" symbol

protected initializeClipboard(ServerRequestInterface $request) : void
Parameters
$request : ServerRequestInterface

isContentEditable()

Check if content can be edited by current user

protected isContentEditable(int $languageId) : bool
Parameters
$languageId : int
Return values
bool

isPageEditable()

Check if page can be edited by current user.

protected isPageEditable(int $languageId) : bool
Parameters
$languageId : int
Return values
bool

makeActionMenu()

This creates the dropdown menu with the different actions this module is able to provide.

protected makeActionMenu(ModuleTemplate $view, array<string|int, mixed> $tsConfig) : void

For now, they are Columns and Languages.

Parameters
$view : ModuleTemplate
$tsConfig : array<string|int, mixed>

makeButtons()

This creates the buttons for the modules

protected makeButtons(ModuleTemplate $view, ServerRequestInterface $request, array<string|int, mixed> $tsConfig) : void
Parameters
$view : ModuleTemplate
$request : ServerRequestInterface
$tsConfig : array<string|int, mixed>

menuConfig()

Initialize menu array

protected menuConfig() : void

resolveExternalUrl()

Returns the redirect URL for the input page row IF the doktype is set to 3.

protected resolveExternalUrl(array<string|int, mixed> $pagerow, ServerRequestInterface $request) : string
Parameters
$pagerow : array<string|int, mixed>
$request : ServerRequestInterface
Return values
string

        
On this page

Search results