MainController

Main controller for the admin panel.

Note this is a "shared" / singleton object: Middleware AdminPanelInitiator instantiates the object and eventually calls initialize(). Later, AdminPanelRenderer calls render() on the same object.

Internal
Attributes
#[Autoconfigure]
$public: true

Table of Contents

Properties

$adminPanelModuleConfiguration  : array<string|int, mixed>
$modules  : array<string, ModuleInterface>

Methods

__construct()  : mixed
initialize()  : ServerRequestInterface
Initializes settings for the admin panel.
render()  : string
Renders the admin panel - Called in PSR-15 Middleware
storeData()  : void
Stores data for admin panel in cache - Called in PSR-15 Middleware
generateBackendUrl()  : string
Generate a url to a backend route
getBackendUser()  : BackendUserAuthentication
initializeModules()  : ServerRequestInterface
storeDataPerModule()  : ModuleDataStorageCollection

Properties

$adminPanelModuleConfiguration

protected array<string|int, mixed> $adminPanelModuleConfiguration

Methods

initialize()

Initializes settings for the admin panel.

public initialize(ServerRequestInterface $request) : ServerRequestInterface
Parameters
$request : ServerRequestInterface
Return values
ServerRequestInterface

render()

Renders the admin panel - Called in PSR-15 Middleware

public render(ServerRequestInterface $request) : string
Parameters
$request : ServerRequestInterface
Tags
see
AdminPanelRenderer
Return values
string

storeData()

Stores data for admin panel in cache - Called in PSR-15 Middleware

public storeData(ServerRequestInterface $request) : void
Parameters
$request : ServerRequestInterface
Tags
see
AdminPanelDataPersister

generateBackendUrl()

Generate a url to a backend route

protected generateBackendUrl(string $route) : string
Parameters
$route : string
Return values
string

initializeModules()

protected initializeModules(ServerRequestInterface $request, array<string, ModuleInterface$modules) : ServerRequestInterface
Parameters
$request : ServerRequestInterface
$modules : array<string, ModuleInterface>
Return values
ServerRequestInterface

        
On this page

Search results