diff --git a/CHANGELOG.md b/CHANGELOG.md index 846c797..c6e165c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,9 @@ +## Version 2.6.0 (unreleased) + +Compatibility: requires minimum Kimai 2.15.0 + +- Use "main" menu instead of "Apps" menu + ## Version 2.5.0 Compatibility: requires minimum Kimai 2.15.0 diff --git a/EventSubscriber/MenuSubscriber.php b/EventSubscriber/MenuSubscriber.php index c24f78d..1e95f8f 100644 --- a/EventSubscriber/MenuSubscriber.php +++ b/EventSubscriber/MenuSubscriber.php @@ -17,7 +17,7 @@ final class MenuSubscriber implements EventSubscriberInterface { - public function __construct(private AuthorizationCheckerInterface $security) + public function __construct(private readonly AuthorizationCheckerInterface $security) { } @@ -37,7 +37,7 @@ public function onMenuConfigure(ConfigureMainMenuEvent $event): void } if ($auth->isGranted('demo')) { - $event->getAppsMenu()->addChild( + $event->getMenu()->addChild( new MenuItemModel('demo', 'Demo', 'demo', [], 'fas fa-snowman') ); } diff --git a/composer.json b/composer.json index 3a3fad4..01907ab 100644 --- a/composer.json +++ b/composer.json @@ -3,7 +3,7 @@ "description": "Showcase plugin for Kimai, with demos for many extension points within the core", "homepage": "https://github.com/Keleo/DemoBundle", "type": "kimai-plugin", - "version": "2.5.0", + "version": "2.6.0", "keywords": [ "kimai", "kimai-plugin"