ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
class.ilMembershipOverviewGUI.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
28{
30 protected ilLanguage $lng;
32
33 public function __construct()
34 {
35 global $DIC;
36
37 $this->ctrl = $DIC->ctrl();
38 $this->lng = $DIC->language();
39 $this->main_tpl = $DIC->ui()->mainTemplate();
40 }
41
42 public function executeCommand(): void
43 {
45 $next_class = $ctrl->getNextClass($this);
46 $cmd = $ctrl->getCmd("show");
47 $this->main_tpl->setTitle($this->lng->txt("my_courses_groups"));
48 switch ($next_class) {
49 case strtolower(ilMembershipBlockGUI::class):
50 $ctrl->setReturn($this, "show");
51 $block = new ilMembershipBlockGUI();
52 $ret = $this->ctrl->forwardCommand($block);
53 if ($ret != "") {
54 $this->main_tpl->setContent($ret);
55 }
56 break;
57
58 default:
59 if ($cmd === "show") {
60 $this->$cmd();
61 }
62 }
63 $this->main_tpl->printToStdout();
64 }
65
66 protected function show(): void
67 {
70
71 $main_tpl->setTitle($lng->txt("my_courses_groups"));
72 $main_tpl->setTitleIcon(\ilUtil::getImagePath("standard/icon_crgr.svg"));
73
74 $block = new ilMembershipBlockGUI();
75 $main_tpl->setContent($block->getHTML());
76 }
77}
language handling
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
Membership overview @ilCtrl_Calls ilMembershipOverviewGUI: ilMembershipBlockGUI @ilCtrl_Calls ilMembe...
ilGlobalTemplateInterface $main_tpl
static getImagePath(string $image_name, string $module_path="", string $mode="output", bool $offline=false)
get image path (for images located in a template directory)
setTitle(string $a_title, bool $hidden=false)
Sets title in standard template.
setTitleIcon(string $a_icon_path, string $a_icon_desc="")
set title icon
setContent(string $a_html)
Sets content for standard template.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
getNextClass($a_gui_class=null)
Returns the fully-qualified classname of the next class in the control flow.
setReturn(object $a_gui_obj, ?string $a_cmd=null)
Sets the return command of a given GUI object.
getCmd(?string $fallback_command=null)
Returns the command passed with the current POST or GET request and fires an according ilCtrlEvent.
global $DIC
Definition: shib_login.php:26