ILIAS  release_7 Revision v7.30-3-g800a261c036
All Data Structures Namespaces Files Functions Variables Modules Pages
ContactMainBarProvider.php
Go to the documentation of this file.
1 <?php namespace ILIAS\Contact\Provider;
2 
3 use ilBuddySystem;
4 use ilContactGUI;
9 
16 {
17 
21  public function getStaticTopItems() : array
22  {
23  return [];
24  }
25 
26 
30  public function getStaticSubItems() : array
31  {
32  $title = $this->dic->language()->txt("mm_contacts");
33 
34  $icon = $this->dic->ui()->factory()
35  ->symbol()
36  ->icon()
37  ->standard(Standard::CADM, 'contacts')->withIsOutlined(true);
38 
39 
40  return [
41  $this->mainmenu->link($this->if->identifier('mm_pd_contacts'))
42  ->withTitle($title)
43  ->withAction($this->dic->ctrl()->getLinkTargetByClass([ilDashboardGUI::class, ilContactGUI::class]))
44  ->withParent(StandardTopItemsProvider::getInstance()->getCommunicationIdentification())
45  ->withPosition(20)
46  ->withSymbol($icon)
47  ->withNonAvailableReason($this->dic->ui()->factory()->legacy("{$this->dic->language()->txt('component_not_active')}"))
48  ->withAvailableCallable(
49  function () {
50  return (bool) (ilBuddySystem::getInstance()->isEnabled());
51  }
52  ),
53  ];
54  }
55 }
if(!file_exists(getcwd() . '/ilias.ini.php'))
registration confirmation script for ilias
Definition: confirmReg.php:12