ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
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 11 of file class.ilMyStaffGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilMyStaffGUI::__construct ( )

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

25 {
26 global $DIC;
27
28 $DIC->language()->loadLanguageModule('mst');
29 $DIC->language()->loadLanguageModule('trac');
30
31 // get the standard template
32 $DIC->ui()->mainTemplate()->loadStandardTemplate();
33 $DIC->ui()->mainTemplate()->setTitle($DIC->language()->txt('mst_my_staff'));
34 }
$DIC
Definition: xapitoken.php:46

References $DIC.

Member Function Documentation

◆ executeCommand()

ilMyStaffGUI::executeCommand ( )

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

41 {
42 global $DIC;
43
44 // determine next class in the call structure
45 $next_class = $DIC->ctrl()->getNextClass($this);
46
47 switch ($next_class) {
48 case strtolower(ilMStListCoursesGUI::class):
49 $list_gui = new ilMStListCoursesGUI();
50 $DIC->ctrl()->forwardCommand($list_gui);
51 break;
52 case strtolower(ilMStListCertificatesGUI::class):
53 $list_gui = new ilMStListCertificatesGUI();
54 $DIC->ctrl()->forwardCommand($list_gui);
55 break;
56 case strtolower(ilMStListCompetencesGUI::class):
57 $list_gui = new ilMStListCompetencesGUI($DIC);
58 $DIC->ctrl()->forwardCommand($list_gui);
59 break;
60// case strtolower(ilMStListStudyProgrammesGUI::class):
61// $list_gui = new ilMStListStudyProgrammesGUI();
62// $DIC->ctrl()->forwardCommand($list_gui);
63// break;
64 case strtolower(ilMStShowUserGUI::class):
65 $user_gui = new ilMStShowUserGUI();
66 $DIC->ctrl()->forwardCommand($user_gui);
67 break;
68 default:
69 $list_gui = new ilMStListUsersGUI();
70 $DIC->ctrl()->forwardCommand($list_gui);
71 break;
72 }
73
74 $DIC->ui()->mainTemplate()->printToStdout();
75 }
Class ilMStListCertificatesGUI.
Class ilMStListCompetencesGUI.
Class ilMStListCoursesGUI.
Class ilMStListUsersGUI.
Class ilMStShowUserGUI.

References $DIC.

◆ getUserLpStatusAsHtml()

static ilMyStaffGUI::getUserLpStatusAsHtml ( ilMStListCourse  $my_staff_course)
static
Parameters
ilMStListCourse$my_staff_course
Returns
string

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

125 {
126 global $DIC;
127
128 if (ilMyStaffAccess::getInstance()->hasCurrentUserAccessToLearningProgressInObject($my_staff_course->getCrsRefId())) {
129 $lp_icon = $DIC->ui()->factory()->image()
131
132 return $DIC->ui()->renderer()->render($lp_icon) . ' '
133 . ilLearningProgressBaseGUI::_getStatusText(intval($my_staff_course->getUsrLpStatus()));
134 }
135
136 return '&nbsp';
137 }
static _getStatusText($a_status, $a_lng=null)
Get status alt text.
static _getImagePathForStatus($a_status)
Get image path for status.

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

Referenced by ILIAS\MyStaff\ListCourses\ilMStListCoursesTableGUI\fillRow(), and ILIAS\MyStaff\Courses\ShowUser\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)
static
Parameters
ilMStListCourse$my_staff_course
Returns
string

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

146 {
147 if (ilMyStaffAccess::getInstance()->hasCurrentUserAccessToLearningProgressInObject($my_staff_course->getCrsRefId())) {
148 return ilLearningProgressBaseGUI::_getStatusText(intval($my_staff_course->getUsrLpStatus()));
149 }
150
151 return '';
152 }

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

Referenced by ILIAS\MyStaff\ListCourses\ilMStListCoursesTableGUI\getFieldValuesForExport(), and ILIAS\MyStaff\Courses\ShowUser\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 16 of file class.ilMyStaffGUI.php.

◆ TAB_LIST_COMPETENCES

const ilMyStaffGUI::TAB_LIST_COMPETENCES = 'list_competences'

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

◆ TAB_LIST_COURSES

const ilMyStaffGUI::TAB_LIST_COURSES = 'list_courses'

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

◆ TAB_LIST_STUDY_PROGRAMME

const ilMyStaffGUI::TAB_LIST_STUDY_PROGRAMME = 'list_study_programme'

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

◆ TAB_LIST_USERS

const ilMyStaffGUI::TAB_LIST_USERS = 'list_users'

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


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