ILIAS
release_6 Revision v6.24-5-g0c8bfefb3b8
◀ ilDoc Overview
class.ilCalendarAppointmentBaseFactory.php
Go to the documentation of this file.
1
<?
php
10
class
ilCalendarAppointmentBaseFactory
11
{
12
public
static
function
getClassBaseName
($a_appointment)
13
{
14
include_once(
'./Services/Calendar/classes/class.ilCalendarCategoryAssignments.php'
);
15
$cat_id =
ilCalendarCategoryAssignments::_lookupCategory
($a_appointment[
'event'
]->getEntryId());
16
$cat =
ilCalendarCategory::getInstanceByCategoryId
($cat_id);
17
$cat_info[
"type"
] = $cat->getType();
18
$cat_info[
"obj_id"
] = $cat->getObjId();
19
20
if
($a_appointment[
'event'
]->isMilestone()) {
21
return
"Milestone"
;
22
}
23
24
switch
($cat_info[
'type'
]) {
25
case
ilCalendarCategory::TYPE_OBJ
:
26
$type
=
ilObject::_lookupType
($cat_info[
'obj_id'
]);
27
switch
(
$type
) {
28
case
"crs"
:
29
return
"Course"
;
30
31
case
"grp"
:
32
return
"Group"
;
33
34
case
"sess"
:
35
return
"Session"
;
36
37
case
"exc"
:
38
return
"Exercise"
;
39
40
default
:
41
return
""
;
42
}
43
break
;
44
case
ilCalendarCategory::TYPE_USR
:
45
return
"User"
;
46
47
case
ilCalendarCategory::TYPE_GLOBAL
:
48
return
"Public"
;
49
50
case
ilCalendarCategory::TYPE_CH
:
51
return
"ConsultationHours"
;
52
53
case
ilCalendarCategory::TYPE_BOOK
:
54
return
"BookingPool"
;
55
56
default
:
57
return
""
;
58
}
59
}
60
}
php
An exception for terminatinating execution or to throw for unit testing.
ilCalendarAppointmentBaseFactory
Definition:
class.ilCalendarAppointmentBaseFactory.php:11
ilCalendarAppointmentBaseFactory\getClassBaseName
static getClassBaseName($a_appointment)
Definition:
class.ilCalendarAppointmentBaseFactory.php:12
ilCalendarCategoryAssignments\_lookupCategory
static _lookupCategory($a_cal_id)
Lookup category id.
Definition:
class.ilCalendarCategoryAssignments.php:88
ilCalendarCategory\getInstanceByCategoryId
static getInstanceByCategoryId($a_cat_id)
Get instance by category id.
Definition:
class.ilCalendarCategory.php:118
ilCalendarCategory\TYPE_BOOK
const TYPE_BOOK
Definition:
class.ilCalendarCategory.php:46
ilCalendarCategory\TYPE_USR
const TYPE_USR
Definition:
class.ilCalendarCategory.php:42
ilCalendarCategory\TYPE_GLOBAL
const TYPE_GLOBAL
Definition:
class.ilCalendarCategory.php:44
ilCalendarCategory\TYPE_CH
const TYPE_CH
Definition:
class.ilCalendarCategory.php:45
ilCalendarCategory\TYPE_OBJ
const TYPE_OBJ
Definition:
class.ilCalendarCategory.php:43
ilObject\_lookupType
static _lookupType($a_id, $a_reference=false)
lookup object type
Definition:
class.ilObject.php:1278
$type
$type
Definition:
proxy_ylocal.php:10
Services
Calendar
classes
Appointment
class.ilCalendarAppointmentBaseFactory.php
Generated on Sat Oct 4 2025 20:00:56 for ILIAS by
1.9.4 (using
Doxyfile
)