added new permission to separate time and money budget (#3352)

This commit is contained in:
Kevin Papst
2022-06-11 12:23:02 +02:00
committed by GitHub
parent 3f827b3104
commit b46fdcefad
47 changed files with 853 additions and 346 deletions

View File

@@ -333,7 +333,7 @@ final class ProjectController extends AbstractController
$rates = $rateRepository->getRatesForProject($project);
}
if ($this->isGranted('budget', $project)) {
if ($this->isGranted('budget', $project) || $this->isGranted('time', $project)) {
$stats = $statisticService->getBudgetStatisticModel($project, $now);
}
@@ -563,6 +563,7 @@ final class ProjectController extends AbstractController
'currency' => $currency,
'timezone' => $this->getDateTimeFactory()->getTimezone()->getName(),
'include_budget' => $this->isGranted('budget', $project),
'include_time' => $this->isGranted('time', $project),
'time_increment' => 15,
]);
}