‪TYPO3CMS  11.5
TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn Class Reference
Inheritance diagram for TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn:
TYPO3\CMS\Backend\View\BackendLayout\Grid\AbstractGridObject

Public Member Functions

 isActive ()
 
 addItem (GridColumnItem $item)
 
GridColumnItem[] getItems ()
 
 getColumnNumber ()
 
 getColumnName ()
 
 getIcon ()
 
 getColSpan ()
 
 getRowSpan ()
 
int[] getAllContainedItemUids ()
 
 getEditUrl ()
 
 getNewContentUrl ()
 
 getTitle ()
 
 getTitleInaccessible ()
 
 getTitleUnassigned ()
 
 getBeforeSectionMarkup ()
 
 getAfterSectionMarkup ()
 
 isUnassigned ()
 
 isUnused ()
 
 isContentEditable ()
 
- ‪Public Member Functions inherited from ‪TYPO3\CMS\Backend\View\BackendLayout\Grid\AbstractGridObject
 __construct (PageLayoutContext $context)
 
 getUniqueId ()
 
 getContext ()
 

Public Attributes

$this columnNumber = isset($definition['colPos']) ? (int)$definition['colPos'] : null
 
$this columnName = $definition['name'] ?? $this->columnName
 
$this icon = $definition['icon'] ?? $this->icon
 
$this colSpan = (int)($definition['colspan'] ?? $this->colSpan)
 
$this rowSpan = (int)($definition['rowspan'] ?? $this->rowSpan)
 
$this eventDispatcher = GeneralUtility::makeInstance(EventDispatcherInterface::class)
 
array< string, function getDefinition():array { return $this-> definition
 
 $records [(int) $record['uid']] = $record
 
return $records
 

Protected Member Functions

array< int, getRecords():array { if( $this->items===[]) { return[];} $records=[];foreach( $this->items as $item) { $record=$item-> getRecord ()
 
- ‪Protected Member Functions inherited from ‪TYPO3\CMS\Backend\View\BackendLayout\Grid\AbstractGridObject
 getLanguageService ()
 
 getBackendUser ()
 

Protected Attributes

GridColumnItem[] $items = array( )
 
int null $columnNumber
 
string $columnName = 'default'
 
string null $icon
 
int $colSpan = 1
 
int $rowSpan = 1
 
array< string, $definition;private EventDispatcherInterface $eventDispatcher;public function __construct(PageLayoutContext $context, array $definition) { parent::__construct( $context);$this-> definition = $definition
 
- ‪Protected Attributes inherited from ‪TYPO3\CMS\Backend\View\BackendLayout\Grid\AbstractGridObject
PageLayoutContext $context
 
IconFactory $iconFactory
 

Detailed Description

Grid Column

Object representation (model/proxy) for a single column from a grid defined in a BackendLayout. Stores GridColumnItem representations of content records and provides getter methods which return various properties associated with a single column, e.g. the "edit all elements in content" URL and the "add new content element" URL of the button that is placed in the top of columns in the page layout.

Accessed from Fluid templates.

this is experimental and subject to change in TYPO3 v10 / v11

Definition at line 44 of file GridColumn.php.

Member Function Documentation

◆ addItem()

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::addItem ( GridColumnItem  $item)

Definition at line 101 of file GridColumn.php.

◆ getAfterSectionMarkup()

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::getAfterSectionMarkup ( )

◆ getAllContainedItemUids()

int [] TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::getAllContainedItemUids ( )
Returns
‪int[]

Definition at line 148 of file GridColumn.php.

Referenced by TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn\getEditUrl().

◆ getBeforeSectionMarkup()

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::getBeforeSectionMarkup ( )

◆ getColSpan()

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::getColSpan ( )

◆ getColumnName()

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::getColumnName ( )

◆ getColumnNumber()

◆ getEditUrl()

◆ getIcon()

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::getIcon ( )

◆ getItems()

GridColumnItem [] TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::getItems ( )

◆ getNewContentUrl()

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::getNewContentUrl ( )

◆ getRecord()

array<int, getRecords(): array { if ($this->items === []) { return []; } $records = []; foreach ($this->items as $item) { $record = $item-> TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::getRecord ( )
protected

Get the raw records for the current column

Returns
‪array<int, array<string, mixed>>

◆ getRowSpan()

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::getRowSpan ( )

◆ getTitle()

◆ getTitleInaccessible()

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::getTitleInaccessible ( )

◆ getTitleUnassigned()

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::getTitleUnassigned ( )

◆ isActive()

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::isActive ( )

◆ isContentEditable()

◆ isUnassigned()

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::isUnassigned ( )

◆ isUnused()

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::isUnused ( )

Member Data Documentation

◆ $colSpan

int TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::$colSpan = 1
protected

◆ $columnName

string TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::$columnName = 'default'
protected

◆ $columnNumber

int null TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::$columnNumber
protected

◆ $icon

string null TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::$icon
protected

◆ $items

GridColumnItem [] TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::$items = array( )
protected

◆ $records [1/2]

TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::$records[(int) $record[ 'uid']] = $record

Definition at line 297 of file GridColumn.php.

◆ $records [2/2]

return TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::$records

Definition at line 299 of file GridColumn.php.

◆ $rowSpan

int TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::$rowSpan = 1
protected

◆ colSpan

$this TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::colSpan = (int)($definition['colspan'] ?? $this->colSpan)

Definition at line 83 of file GridColumn.php.

◆ columnName

$this TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::columnName = $definition['name'] ?? $this->columnName

Definition at line 81 of file GridColumn.php.

◆ columnNumber

◆ definition [1/2]

array<string, $definition; private EventDispatcherInterface $eventDispatcher; public function __construct(PageLayoutContext $context, array $definition) { parent::__construct($context); $this-> TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::definition = $definition
protected

mixed>

Definition at line 79 of file GridColumn.php.

◆ definition [2/2]

array<string, function getDefinition(): array { return $this-> TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::definition
Returns
‪array<string, mixed>

Definition at line 93 of file GridColumn.php.

◆ eventDispatcher

$this TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::eventDispatcher = GeneralUtility::makeInstance(EventDispatcherInterface::class)

◆ icon

$this TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::icon = $definition['icon'] ?? $this->icon

Definition at line 82 of file GridColumn.php.

◆ rowSpan

$this TYPO3\CMS\Backend\View\BackendLayout\Grid\GridColumn::rowSpan = (int)($definition['rowspan'] ?? $this->rowSpan)

Definition at line 84 of file GridColumn.php.