ILIAS  release_4-3 Revision
 All Data Structures Namespaces Files Functions Variables Groups Pages
ilCalendarRecurrences Class Reference
+ Collaboration diagram for ilCalendarRecurrences:

Static Public Member Functions

static _getRecurrences ($a_cal_id)
 get all recurrences of an appointment
static _getFirstRecurrence ($a_cal_id)
 get first recurrence

Detailed Description

Author
Stefan Meyer smeye.nosp@m.r.il.nosp@m.ias@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

Definition at line 34 of file class.ilCalendarRecurrences.php.

Member Function Documentation

static ilCalendarRecurrences::_getFirstRecurrence (   $a_cal_id)
static

get first recurrence

public

Parameters
intcal id
Returns

Definition at line 66 of file class.ilCalendarRecurrences.php.

Referenced by ilCalendarExport\createVEVENT(), ilCalendarAppointmentGUI\initAppointment(), ilCalendarAppointmentsTableGUI\setAppointments(), and ilCalendarChangedAppointmentsTableGUI\setAppointments().

{
if($recs = self::_getRecurrences($a_cal_id))
{
return $recs[0];
}
$new_rec = new ilCalendarRecurrence();
$new_rec->setEntryId($a_cal_id);
return $new_rec;
}

+ Here is the caller graph for this function:

static ilCalendarRecurrences::_getRecurrences (   $a_cal_id)
static

get all recurrences of an appointment

public

Parameters
intcal_id
Returns
array array of ilCalendarRecurrence

Definition at line 44 of file class.ilCalendarRecurrences.php.

References $query, $res, $row, and DB_FETCHMODE_OBJECT.

Referenced by ilCalendarAppointmentGUI\askDelete(), ilCalendarSchedule\calculate(), and ilCalendarExport\createRecurrences().

{
global $ilDB;
$query = "SELECT rule_id FROM cal_recurrence_rules ".
"WHERE cal_id = ".$ilDB->quote($a_cal_id ,'integer')." ";
$res = $ilDB->query($query);
while($row = $res->fetchRow(DB_FETCHMODE_OBJECT))
{
$recurrences[] = new ilCalendarRecurrence($row->rule_id);
}
return $recurrences ? $recurrences : array();
}

+ Here is the caller graph for this function:


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