19 declare(strict_types=1);
35 $this->
ctrl = $DIC->ctrl();
37 $this->
lng = $DIC->language();
38 $this->
tabs = $DIC->tabs();
39 $this->main_tpl = $DIC->ui()->mainTemplate();
51 $cmd = $ctrl->
getCmd(
'show');
54 switch ($next_class) {
55 case strtolower(ilLearningProgressGUI::class):
56 $main_tpl->
setTitle($lng->
txt(
'learning_progress'));
62 case strtolower(ilLearningHistoryGUI::class):
63 $main_tpl->
setTitle($lng->
txt(
'lhist_learning_history'));
67 $this->main_tpl->printToStdout();
70 case strtolower(ilPersonalSkillsGUI::class):
75 $this->main_tpl->printToStdout();
78 case strtolower(ilBadgeProfileGUI::class):
83 $this->main_tpl->printToStdout();
86 case strtolower(ilUserCertificateGUI::class):
91 $this->main_tpl->printToStdout();
98 $this->main_tpl->printToStdout();
103 protected function show(): void
108 $first_service = current($this->achievements->getActiveServices());
109 if ($first_service) {
110 $ctrl->
redirectByClass([ilDashboardGUI::class, ilAchievementsGUI::class, $gui_classes[$first_service]]);
114 protected function setTabs(
string $activate): void
119 foreach ($this->achievements->getActiveServices() as $s) {
120 $tabs->
addTab(
'achieve_' . $s, $links[$s][
'txt'], $links[$s][
'link']);
138 'txt' => $lng->
txt(
'lhist_learning_history')
141 'txt' => $lng->
txt(
'skills')
144 'txt' => $lng->
txt(
'learning_progress')
147 'txt' => $lng->
txt(
'obj_bdga')
150 'txt' => $lng->
txt(
'obj_cert')
154 foreach ($links as $k => $v) {
155 $links[$k][
'link'] = $ctrl->
getLinkTargetByClass([ilDashboardGUI::class, ilAchievementsGUI::class, $gui_classes[$k]]);
ilUserCertificateGUI: ilAchievementsGUI
getLinkTargetByClass( $a_class, string $a_cmd=null, string $a_anchor=null, bool $is_async=false, bool $has_xml_style=false)
redirectByClass( $a_class, string $a_cmd=null, string $a_anchor=null, bool $is_async=false)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
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...
getCmd(string $fallback_command=null)
loadLanguageModule(string $a_module)
Load language module.
setTitleIcon(string $a_icon_path, string $a_icon_desc="")
set title icon
forwardCommand(object $a_gui_object)
Personal skills GUI class.
ilGlobalTemplateInterface $main_tpl
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
getNextClass($a_gui_class=null)
setTabs(string $activate)
static getImagePath(string $image_name, string $module_path="", string $mode="output", bool $offline=false)
get image path (for images located in a template directory)
const LP_CONTEXT_PERSONAL_DESKTOP
const SERV_LEARNING_HISTORY
setTitle(string $a_title, bool $hidden=false)
Sets title in standard template.
const SERV_LEARNING_PROGRESS
activateTab(string $a_id)
ilAchievements $achievements
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
addTab(string $a_id, string $a_text, string $a_link, string $a_frame="")
Add a Tab.