class BackendRedirectionService (View source)

Properties

protected SessionInterface $session
protected NodeDataRepository $nodeDataRepository
protected WorkspaceRepository $workspaceRepository
protected ContextFactoryInterface $contextFactory
protected DomainRepository $domainRepository
protected SiteRepository $siteRepository
protected UserService $userService
protected PersistenceManagerInterface $persistenceManager
protected PropertyMapper $propertyMapper
protected MenuHelper $menuHelper
protected PrivilegeManagerInterface $privilegeManager
protected string[] $preferedStartModules

Methods

string|null
getAfterLoginRedirectionUri(ControllerContext $controllerContext)

Returns a specific URI string to redirect to after the login; or NULL if there is none.

array|null
determineStartModule(array $availableModules)

No description

string|null
getAfterLogoutRedirectionUri(ActionRequest $actionRequest)

Returns a specific URI string to redirect to after the logout; or NULL if there is none.

NodeInterface|null
getLastVisitedNode(string $workspaceName)

No description

createContext(string $workspaceName)

Create a ContentContext to be used for the backend redirects.

void
createWorkspaceAndRootNodeIfNecessary(string $workspaceName)

If the specified workspace or its root node does not exist yet, the workspace and root node will be created.

Details

string|null getAfterLoginRedirectionUri(ControllerContext $controllerContext)

Returns a specific URI string to redirect to after the login; or NULL if there is none.

Parameters

ControllerContext $controllerContext

Return Value

string|null

Exceptions

IllegalObjectTypeException
MissingActionNameException
Exception

protected array|null determineStartModule(array $availableModules)

No description

Parameters

array $availableModules

Return Value

array|null

string|null getAfterLogoutRedirectionUri(ActionRequest $actionRequest)

Returns a specific URI string to redirect to after the logout; or NULL if there is none.

In case of NULL, it's the responsibility of the AuthenticationController where to redirect, most likely to the LoginController's index action.

Parameters

ActionRequest $actionRequest

Return Value

string|null

A possible redirection URI, if any

Exceptions

Exception
MissingActionNameException

protected NodeInterface|null getLastVisitedNode(string $workspaceName)

No description

Parameters

string $workspaceName

Return Value

NodeInterface|null

protected ContentContext createContext(string $workspaceName)

Create a ContentContext to be used for the backend redirects.

Parameters

string $workspaceName

Return Value

ContentContext

protected void createWorkspaceAndRootNodeIfNecessary(string $workspaceName)

If the specified workspace or its root node does not exist yet, the workspace and root node will be created.

This method is basically a safeguard for legacy and potentially broken websites where users might not have their own workspace yet. In a normal setup, the Domain User Service is responsible for creating and deleting user workspaces.

Parameters

string $workspaceName

Name of the workspace

Return Value

void

Exceptions

IllegalObjectTypeException