fix deprecations

This commit is contained in:
Kevin Papst
2026-01-03 00:09:59 +01:00
parent c92a8949b2
commit aaa58e6d20
5 changed files with 20 additions and 9 deletions

View File

@@ -3569,11 +3569,6 @@ parameters:
count: 1
path: src/Twig/Runtime/ThemeExtension.php
-
message: "#^Method App\\\\User\\\\LoginManager\\:\\:logInUser\\(\\) has no return type specified\\.$#"
count: 1
path: src/User/LoginManager.php
-
message: "#^Method App\\\\User\\\\UserService\\:\\:updateUser\\(\\) has parameter \\$groups with no value type specified in iterable type array\\.$#"
count: 1

View File

@@ -87,10 +87,14 @@ final class ActiveUsers extends AbstractWidget
$days->setDate($d);
}
$today = $factory->create();
$beginOfDay = $today->modify('00:00:00');
$endOfDay = $today->modify('23:59:59');
return [
'days' => $days->getDays(),
'now' => $this->countActiveEntries(),
'today' => $this->getDataForTimeRange($factory->createStartOfDay(), $factory->createEndOfDay()),
'today' => $this->getDataForTimeRange($beginOfDay, $endOfDay),
'week' => $this->getDataForTimeRange($factory->getStartOfWeek(), $factory->getEndOfWeek()),
'month' => $this->getDataForTimeRange($factory->getStartOfMonth(), $factory->getEndOfMonth()),
'year' => $this->getDataForTimeRange($factory->createStartOfYear(), $factory->createEndOfYear()),

View File

@@ -79,9 +79,13 @@ final class Duration extends AbstractWidget
$days->setDate($d);
}
$today = $factory->create();
$beginOfDay = $today->modify('00:00:00');
$endOfDay = $today->modify('23:59:59');
return [
'days' => $days->getDays(),
'today' => $this->getDataForTimeRange($factory->createStartOfDay(), $factory->createEndOfDay()),
'today' => $this->getDataForTimeRange($beginOfDay, $endOfDay),
'week' => $this->getDataForTimeRange($factory->getStartOfWeek(), $factory->getEndOfWeek()),
'month' => $this->getDataForTimeRange($factory->getStartOfMonth(), $factory->getEndOfMonth()),
'year' => $this->getDataForTimeRange($factory->createStartOfYear(), $factory->createEndOfYear()),

View File

@@ -51,8 +51,12 @@ final class Revenue extends AbstractWidget
}
if ($data === null) {
$today = $factory->create();
$beginOfDay = $today->modify('00:00:00');
$endOfDay = $today->modify('23:59:59');
$data = match ($type) {
DateRangeEnum::TODAY => $this->getRevenue($factory->createStartOfDay(), $factory->createEndOfDay()),
DateRangeEnum::TODAY => $this->getRevenue($beginOfDay, $endOfDay),
DateRangeEnum::WEEK => $this->getRevenue($factory->getStartOfWeek(), $factory->getEndOfWeek()),
DateRangeEnum::YEAR => $this->getRevenue($factory->createStartOfYear(), $factory->createEndOfYear()),
DateRangeEnum::TOTAL => $this->getRevenue(null, null),

View File

@@ -51,8 +51,12 @@ final class RevenueUser extends AbstractWidget
}
if ($data === null) {
$today = $factory->create();
$beginOfDay = $today->modify('00:00:00');
$endOfDay = $today->modify('23:59:59');
$data = match ($type) {
DateRangeEnum::TODAY => $this->getRevenue($factory->createStartOfDay(), $factory->createEndOfDay()),
DateRangeEnum::TODAY => $this->getRevenue($beginOfDay, $endOfDay),
DateRangeEnum::WEEK => $this->getRevenue($factory->getStartOfWeek(), $factory->getEndOfWeek()),
DateRangeEnum::YEAR => $this->getRevenue($factory->createStartOfYear(), $factory->createEndOfYear()),
DateRangeEnum::TOTAL => $this->getRevenue(null, null),