Allow to customize statistic queries (#5827)

* use TimesheetStatisticsQUery for all repository calls
* send event to customize statistics query
This commit is contained in:
Kevin Papst
2026-02-24 13:27:48 +01:00
committed by GitHub
parent d9ef6dfcad
commit 77afa207e0
6 changed files with 124 additions and 10 deletions

View File

@@ -0,0 +1,25 @@
<?php
/*
* This file is part of the Kimai time-tracking app.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace App\Event;
use Doctrine\ORM\QueryBuilder;
use Symfony\Contracts\EventDispatcher\Event;
final class TimesheetStatisticsQueryEvent extends Event
{
public function __construct(private readonly QueryBuilder $queryBuilder)
{
}
public function getQueryBuilder(): QueryBuilder
{
return $this->queryBuilder;
}
}