ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
BadgeMainBarProvider.php
Go to the documentation of this file.
1<?php
2
20
24
29{
30 public function getStaticTopItems(): array
31 {
32 return [];
33 }
34
35 public function getStaticSubItems(): array
36 {
37 $title = $this->dic->language()->txt("mm_badges");
38 $icon = $this->dic->ui()->factory()->symbol()->icon()->standard("bdga", $title);
39
40 return [
41 $this->mainmenu->link($this->if->identifier('mm_pd_badges'))
42 ->withTitle($title)
43 ->withAction("ilias.php?baseClass=ilDashboardGUI&cmd=jumpToBadges")
44 ->withPosition(40)
45 ->withParent(StandardTopItemsProvider::getInstance()->getAchievementsIdentification())
46 ->withSymbol($icon)
47 ->withNonAvailableReason($this->dic->ui()->factory()->legacy()->content($this->dic->language()->txt('component_not_active')))
48 ->withAvailableCallable(
49 function () {
50 return ilBadgeHandler::getInstance()->isActive();
51 }
52 ),
53 ];
54 }
55}
Class ilBadgeHandler.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
if(!file_exists('../ilias.ini.php'))