Developer guide
Quick start
composer require hrr/t3-datatable- Tag
Gridimplementations in yourInterface Services.yaml - Implement a grid class (table + columns)
- Load the JS module in your backend module template
- Call
initwith your grid identifierData Table ()
Core contract
namespace HRR\T3Datatable\Contract;
interface GridInterface
{
public function getIdentifier(): string;
public function getTableName(): string;
public function isAccessible(BackendUserAuthentication $backendUser): bool;
public function build(GridDefinition $definition): void;
}
Copied!
isAccessible() is mandatory. It must enforce the module, table, and
record-level permissions appropriate to the grid; authentication alone does not
authorize a user to read every registered grid.
AJAX endpoint
Every grid shares one route, so you never have to register your own AJAX endpoint:
| Route key | t3datatable_data |
|---|---|
| Path | /t3datatable/data |
| Query param | grid={your_grid_identifier} |
| Controller | HRRT3Datatable |
In JavaScript, use TYPO3.settings.ajaxUrls.t3datatable_data.
Response shape
{
"draw": 1,
"recordsTotal": 150,
"recordsFiltered": 42,
"data": [
{"uid": 1, "title": "Example"}
]
}
Copied!
PHP classes
| Class | Role |
|---|---|
Grid | Resolves grids by identifier via DI tag |
Data | Parses DataTables AJAX parameters |
Query | Builds and executes Doctrine queries |
Column | Validates searchable/orderable columns |
Data | Builds JSON payload |
Compatibility policy
Only GridInterface, GridDefinition, ColumnDefinition, and the
documented JavaScript exports are public API. Other PHP classes are internal
implementation details. Minor releases add backwards-compatible functionality;
deprecated public API remains until the next major release and is recorded in
the changelog and upgrade guide.