use events for budget calculation (#2544)
This commit is contained in:
29
src/Event/ProjectStatisticEvent.php
Normal file
29
src/Event/ProjectStatisticEvent.php
Normal file
@@ -0,0 +1,29 @@
|
||||
<?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 App\Entity\Project;
|
||||
use App\Model\ProjectStatistic;
|
||||
|
||||
final class ProjectStatisticEvent extends AbstractProjectEvent
|
||||
{
|
||||
private $statistic;
|
||||
|
||||
public function __construct(Project $project, ProjectStatistic $statistic)
|
||||
{
|
||||
parent::__construct($project);
|
||||
$this->statistic = $statistic;
|
||||
}
|
||||
|
||||
public function getStatistic(): ProjectStatistic
|
||||
{
|
||||
return $this->statistic;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user