ILIAS  release_8 Revision v8.24
ilMyStaffGUI Class Reference

Class ilMyStaffGUI. More...

+ Collaboration diagram for ilMyStaffGUI:

Public Member Functions

 __construct ()
 
 executeCommand ()
 

Static Public Member Functions

static getUserLpStatusAsHtml (ilMStListCourse $my_staff_course)
 
static getUserLpStatusAsText (ilMStListCourse $my_staff_course)
 

Data Fields

const CMD_INDEX = 'index'
 
const TAB_LIST_USERS = 'list_users'
 
const TAB_LIST_COURSES = 'list_courses'
 
const TAB_LIST_CERTIFICATES = 'list_certificates'
 
const TAB_LIST_COMPETENCES = 'list_competences'
 
const TAB_LIST_STUDY_PROGRAMME = 'list_study_programme'
 

Detailed Description

Class ilMyStaffGUI.

Author
Martin Studer ms@st.nosp@m.uder.nosp@m.-raim.nosp@m.ann..nosp@m.ch

Definition at line 26 of file class.ilMyStaffGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilMyStaffGUI::__construct ( )

Definition at line 35 of file class.ilMyStaffGUI.php.

36 {
37 global $DIC;
38
39 $DIC->language()->loadLanguageModule('mst');
40 $DIC->language()->loadLanguageModule('trac');
41
42 // get the standard template
43 $DIC->ui()->mainTemplate()->loadStandardTemplate();
44 }
global $DIC
Definition: feed.php:28

References $DIC.

Member Function Documentation

◆ executeCommand()

ilMyStaffGUI::executeCommand ( )
final

Definition at line 46 of file class.ilMyStaffGUI.php.

46 : void
47 {
48 global $DIC;
49
50 // determine next class in the call structure
51 $next_class = $DIC->ctrl()->getNextClass($this);
52 switch ($next_class) {
53 case "ilmstlistcoursesgui":
54 $list_gui = new \ilMStListCoursesGUI();
55 $DIC->ctrl()->forwardCommand($list_gui);
56 break;
57 case strtolower(ilMStListCertificatesGUI::class):
58 $list_gui = new ilMStListCertificatesGUI();
59 $DIC->ctrl()->forwardCommand($list_gui);
60 break;
61 case strtolower(ilMStListCompetencesGUI::class):
62 $list_gui = new ilMStListCompetencesGUI($DIC);
63 $DIC->ctrl()->forwardCommand($list_gui);
64 break;
65 // case strtolower(ilMStListStudyProgrammesGUI::class):
66 // $list_gui = new ilMStListStudyProgrammesGUI();
67 // $DIC->ctrl()->forwardCommand($list_gui);
68 // break;
69 case strtolower(ilMStShowUserGUI::class):
70 $user_gui = new ilMStShowUserGUI();
71 $DIC->ctrl()->forwardCommand($user_gui);
72 break;
73 case strtolower(ilEmployeeTalkMyStaffListGUI::class):
74 $user_gui = new ilEmployeeTalkMyStaffListGUI();
75 $DIC->ctrl()->forwardCommand($user_gui);
76 break;
77 default:
78 $list_gui = new ilMStListUsersGUI();
79 $DIC->ctrl()->forwardCommand($list_gui);
80 break;
81 }
82
83 $DIC->ui()->mainTemplate()->printToStdout();
84 }
Class ilEmployeeTalkMyStaffListGUI.
Class ilMStListCertificatesGUI.
Class ilMStListCompetencesGUI.
Class ilMStListUsersGUI.
Class ilMStShowUserGUI.

References $DIC.

◆ getUserLpStatusAsHtml()

static ilMyStaffGUI::getUserLpStatusAsHtml ( ilMStListCourse  $my_staff_course)
staticfinal

Definition at line 155 of file class.ilMyStaffGUI.php.

155 : string
156 {
157 global $DIC;
158
159 if (ilMyStaffAccess::getInstance()->hasCurrentUserAccessToLearningProgressInObject($my_staff_course->getCrsRefId())) {
161 $lp_icon = $DIC->ui()->factory()->symbol()->icon()
162 ->custom(
163 $lp_icons->getImagePathForStatus($my_staff_course->getUsrLpStatus()),
165 );
166
167 return $DIC->ui()->renderer()->render($lp_icon) . ' '
168 . ilLearningProgressBaseGUI::_getStatusText(intval($my_staff_course->getUsrLpStatus()));
169 }
170
171 return '&nbsp';
172 }
static getInstance(int $variant=ilLPStatusIcons::ICON_VARIANT_DEFAULT, ?\ILIAS\UI\Renderer $renderer=null, ?\ILIAS\UI\Factory $factory=null)
static _getStatusText(int $a_status, ?ilLanguage $a_lng=null)
Get status alt text.

References $DIC, ilLearningProgressBaseGUI\_getStatusText(), ILIAS\MyStaff\ListCourses\ilMStListCourse\getCrsRefId(), ilLPStatusIcons\getInstance(), ILIAS\MyStaff\ListCourses\ilMStListCourse\getUsrLpStatus(), and ilLPStatusIcons\ICON_VARIANT_LONG.

Referenced by ilMStListCoursesTableGUI\fillRow(), and ilMStShowUserCoursesTableGUI\fillRow().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getUserLpStatusAsText()

static ilMyStaffGUI::getUserLpStatusAsText ( ilMStListCourse  $my_staff_course)
staticfinal

Definition at line 174 of file class.ilMyStaffGUI.php.

174 : string
175 {
176 if (ilMyStaffAccess::getInstance()->hasCurrentUserAccessToLearningProgressInObject($my_staff_course->getCrsRefId())) {
177 return ilLearningProgressBaseGUI::_getStatusText(intval($my_staff_course->getUsrLpStatus()));
178 }
179
180 return '';
181 }

References ilLearningProgressBaseGUI\_getStatusText(), ILIAS\MyStaff\ListCourses\ilMStListCourse\getCrsRefId(), and ILIAS\MyStaff\ListCourses\ilMStListCourse\getUsrLpStatus().

Referenced by ilMStListCoursesTableGUI\getFieldValuesForExport(), and ilMStShowUserCoursesTableGUI\getFieldValuesForExport().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ CMD_INDEX

const ilMyStaffGUI::CMD_INDEX = 'index'

◆ TAB_LIST_CERTIFICATES

const ilMyStaffGUI::TAB_LIST_CERTIFICATES = 'list_certificates'

Definition at line 31 of file class.ilMyStaffGUI.php.

◆ TAB_LIST_COMPETENCES

const ilMyStaffGUI::TAB_LIST_COMPETENCES = 'list_competences'

Definition at line 32 of file class.ilMyStaffGUI.php.

◆ TAB_LIST_COURSES

const ilMyStaffGUI::TAB_LIST_COURSES = 'list_courses'

Definition at line 30 of file class.ilMyStaffGUI.php.

◆ TAB_LIST_STUDY_PROGRAMME

const ilMyStaffGUI::TAB_LIST_STUDY_PROGRAMME = 'list_study_programme'

Definition at line 33 of file class.ilMyStaffGUI.php.

◆ TAB_LIST_USERS

const ilMyStaffGUI::TAB_LIST_USERS = 'list_users'

Definition at line 29 of file class.ilMyStaffGUI.php.


The documentation for this class was generated from the following file: