Common fields
Mandatory fields
If the table has a TCA definition, TYPO3 will automatically create the following fields:
uid
- An auto-incrementing unique identifier. This field is used as table key and as a reference in relationships between records.
pid
- The
uid
field of the parent page. The record is situated on this page. If this value is 0 the record is not connected to any page.
There is no separate TCA definition of these fields in the TCA configuration. It is not possible to use other names for these fields.
Fields used by convention
Warning
It is possible to change the names of the following fields, however this is strongly discouraged as it breaks convention and may lead to compatibility issues with third party extensions.
All fields mentioned below get added to the database automatically. It is
not recommended to define them in the ext_
. Doing so
with incompatible SQL settings can lead to problems later on.
Soft delete
deleted
-
This field is used to enable soft delete in records. In can be configured by setting ctrl->delete:
Warning
If no
deleted
field is configured, records will be hard deleted. The DataHandler in the backend and Extbase will automatically executeDELETE
statements.The
deleted
field is never directly visible in backend forms. It is handled separately by the DataHandler. Therefore it needs no definition in thecolumns
section.
Enablecolumns
Changed in version 13.3
The column definitions for these settings are auto-created. See also Migration.
hidden
-
This field is used to enable soft hiding of records. In can be configured by setting ctrl->enablecolumns->disabled:
<?php return [ 'ctrl' => [ 'enablecolumns' => [ 'disabled' => 'hidden', ], // ... ], 'palettes' => [ 'visibility' => [ 'showitem' => 'hidden', ], ], 'types' => [ 0 => [ 'showitem' => ' --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:general, [...], --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:access, --palette--;;visibility, ', ], ], ];
starttime
andendtime
-
This field is used to enable records by a starttime and or disable them with an endtime. In can be configured by ctrl->enablecolumns->starttime or endtime:
<?php return [ 'ctrl' => [ 'enablecolumns' => [ 'disabled' => 'hidden', 'starttime' => 'starttime', 'endtime' => 'endtime', ], // ... ], 'palettes' => [ 'access' => [ 'showitem' => 'starttime, endtime', ], 'visibility' => [ 'showitem' => 'hidden', ], ], 'types' => [ 0 => [ 'showitem' => ' --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:general, [...], --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:access, --palette--;;visibility, --palette--;;access, ', ], ], ];
fe_
group -
This field is used to enable soft delete of records. In can be configured by ctrl->enablecolumns->fe_group:
<?php return [ 'ctrl' => [ 'enablecolumns' => [ 'fe_group' => 'fe_group', ], // ... ], 'palettes' => [ 'access' => [ 'label' => 'LLL:EXT:frontend/Resources/Private/Language/locallang_ttc.xlf:palette.access', 'showitem' => ' fe_group, ', ], ], 'types' => [ 0 => [ 'showitem' => ' --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:general, [...], --div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:access, --palette--;;access, ', ], ], ];
Warning
These enable fields are only respected in the frontend if you use proper queries or Extbase repository settings in your extensions code. See Enablecolumns / enablefields usage for more information.
Manual sorting in the backend
sorting
-
This field is used to manually sort records in the backend. In can be configured by ctrl->sortby:
Attention
The sortby field contains an integer and is managed by the DataHandler. It therefore should have no definition in the Field definitions (columns) section. Any value in this field can be changed at any time by the DataHandler.
Use default_sortby if you want to sort by an existing field of the domain instead.
Fields managed by the DataHandler
The following fields are automatically set when a record is written by the DataHandler. They should never be displayed in backend forms or explicitly set, therefore they need no entry in the Field definitions (columns) section of the TCA.
<?php
return [
'ctrl' => [
'tstamp' => 'tstamp',
'crdate' => 'crdate',
'origUid' => 't3_origuid',
// ...
],
];
tstamp
-
This field is automatically updated to the current timestamp each time the record is updated or saved in the DataHandler.
It can be configured by setting ctrl->tstamp.
crdate
-
This field is automatically set to the current timestamp if the record is created by the DataHandler.
It can be configured by setting ctrl->crdate.
t3_
origuid -
Field name, which contains the uid of the original record in case a record is created as a copy or new version of another record.
It can be configured by setting ctrl->origUid.