For developers
PSR-14 events
| Event | Dispatched | Listeners can |
|---|---|---|
DWenzel\ | In every demanded repository before the constraints are applied to the query (frontend and backend). | Read and replace the query, the demand and the list of
constraints (methods get and set). |
DWenzel\ | In the list action of the performance list. | Read the result, settings, demand, content element data and
visitor selection; add template variables with
set. |
DWenzel\ | Replacement of the former signals. Names: list,
show, quick of the event and performance
controllers and of the backend modules,
handle. | Check get and get; change the template
variables with set. For
handle, set redirect in the
arguments to redirect. |
Example listener that restricts all event queries:
use DWenzel\T3events\Domain\Model\Dto\EventDemand;
use DWenzel\T3events\Events\QueryGeneratePreMatchEvent;
use TYPO3\CMS\Core\Attribute\AsEventListener;
#[AsEventListener]
final class OnlyFeaturedEvents
{
public function __invoke(QueryGeneratePreMatchEvent $event): void
{
if (!$event->getDemand() instanceof EventDemand) {
return;
}
$query = $event->getQuery();
$constraints = $event->getConstrains();
$constraints[] = $query->equals('keywords', 'featured');
$event->setConstrains($constraints);
}
}
Copied!
ViewHelpers
Namespace DWenzel\, used as ts in the default
templates.
| ViewHelper | Purpose |
|---|---|
ts: | Date range of all performances of an event (event,
format, start, end, glue). |
ts: | Date range of a performance. |
ts: | Formats a date (DateTime, string or timestamp); formats with
% use the strftime notation. |
ts: | Deprecated. Date range or crucial status of the performances of an
event (type = date). |
ts:, ts: | Number of distinct event locations of an event, or the locations. |
ts: | Events with a performance on a given day. |
ts: | An array as one CSV line. |
ts: | URL of the backend form of a record. |
ts:, ts:, ts: | Head data, meta tag and page title. meta options and
title on TYPO3 14 do not work in 4.0. |
Notification service
DWenzel\ renders Fluid templates and
sends them as e-mail (notify, render, send for stored
Notification records). t3events itself does not send notifications; the
service is used by extensions based on t3events.
Development environment
The repository dwenzel/ provides a DDEV setup with one
TYPO3 instance per supported version. Testing is described in
TESTING. in the extension repository.