RecyclerUtility
Helper class for the 'recycler' extension.
Table of Contents
Methods
- checkAccess() : bool
- Checks the page access rights (Code for access check mostly taken from FormEngine) as well as the table access rights of the user.
- getDeletedField() : string
- Gets the name of the field with the information whether a record is deleted.
- getModifyableTables() : mixed
- Returns the modifiable tables of the current user
- getPidOfUid() : int
- Get pid of uid
- getRecordPath() : string
- Returns the path (visually) of a page $uid, fx. "/First page/Second page/Another subpage" Each part of the path will be limited to $titleLimit characters Deleted pages are filtered out.
- getTableTCA() : array<string|int, mixed>|false
- Gets the TCA of the table used in the current context.
- isParentPageDeleted() : bool
- Check if parent record is deleted
- getBackendUser() : BackendUserAuthentication
- Returns the BackendUser
- getLanguageService() : LanguageService
- Returns an instance of LanguageService
Methods
checkAccess()
Checks the page access rights (Code for access check mostly taken from FormEngine) as well as the table access rights of the user.
    public
            static        checkAccess(string $table, array<string|int, mixed> $row) : bool
    Parameters
- $table : string
- 
                    The table to check access for 
- $row : array<string|int, mixed>
- 
                    Record array 
Return values
bool —Returns TRUE is the user has access, or FALSE if not
getDeletedField()
Gets the name of the field with the information whether a record is deleted.
    public
            static        getDeletedField(string $tableName) : string
    Parameters
- $tableName : string
- 
                    Name of the table to get the deleted field for 
Return values
string —Name of the field with the information whether a record is deleted
getModifyableTables()
Returns the modifiable tables of the current user
    public
            static        getModifyableTables() : mixed
    getPidOfUid()
Get pid of uid
    public
            static        getPidOfUid(int $uid, string $table) : int
    Parameters
- $uid : int
- $table : string
Return values
intgetRecordPath()
Returns the path (visually) of a page $uid, fx. "/First page/Second page/Another subpage" Each part of the path will be limited to $titleLimit characters Deleted pages are filtered out.
    public
            static        getRecordPath(int $uid) : string
    Parameters
- $uid : int
- 
                    Page uid for which to create record path 
Return values
string —Path of record (string) OR array with short/long title if $fullTitleLimit is set.
getTableTCA()
Gets the TCA of the table used in the current context.
    public
            static        getTableTCA(string $tableName) : array<string|int, mixed>|false
    Parameters
- $tableName : string
- 
                    Name of the table to get TCA for 
Return values
array<string|int, mixed>|false —TCA of the table used in the current context
isParentPageDeleted()
Check if parent record is deleted
    public
            static        isParentPageDeleted(int $pid) : bool
    Parameters
- $pid : int
Return values
boolgetBackendUser()
Returns the BackendUser
    protected
            static        getBackendUser() : BackendUserAuthentication
    Return values
BackendUserAuthenticationgetLanguageService()
Returns an instance of LanguageService
    protected
            static        getLanguageService() : LanguageService