ILIAS  release_7 Revision v7.30-3-g800a261c036
class.ilMembershipOverviewGUI.php
Go to the documentation of this file.
1<?php
2
3/* Copyright (c) 1998-2019 ILIAS open source, Extended GPL, see docs/LICENSE */
4
13{
17 protected $ctrl;
18
22 protected $lng;
23
27 protected $main_tpl;
28
32 public function __construct()
33 {
34 global $DIC;
35
36 $this->ctrl = $DIC->ctrl();
37 $this->lng = $DIC->language();
38 $this->main_tpl = $DIC->ui()->mainTemplate();
39 }
40
44 public function executeCommand()
45 {
47
48 $next_class = $ctrl->getNextClass($this);
49 $cmd = $ctrl->getCmd("show");
50 $this->main_tpl->setTitle($this->lng->txt("my_courses_groups"));
51
52 switch ($next_class) {
53 case "ilpdmembershipblockgui":
54 $ctrl->setReturn($this, "show");
55 $block = new ilPDMembershipBlockGUI(true);
56 $ret = $this->ctrl->forwardCommand($block);
57 if ($ret != "") {
58 $this->main_tpl->setContent($ret);
59 }
60 break;
61
62 default:
63 if (in_array($cmd, array("show"))) {
64 $this->$cmd();
65 }
66 }
67 $this->main_tpl->printToStdout();
68 }
69
73 protected function show()
74 {
77
78 $main_tpl->setTitle($lng->txt("my_courses_groups"));
79
80 $block = new ilPDMembershipBlockGUI(true);
81 $main_tpl->setContent($block->getHTML());
82 }
83}
An exception for terminatinating execution or to throw for unit testing.
global $DIC
Definition: goto.php:24
$ret
Definition: parser.php:6