ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilCalendarRecurrences Class Reference
+ Collaboration diagram for ilCalendarRecurrences:

Static Public Member Functions

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

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

◆ _getFirstRecurrence()

static ilCalendarRecurrences::_getFirstRecurrence (   $a_cal_id)
static

get first recurrence

public

Parameters
intcal id
Returns

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

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

66  {
67  if ($recs = self::_getRecurrences($a_cal_id)) {
68  return $recs[0];
69  }
70  $new_rec = new ilCalendarRecurrence();
71  $new_rec->setEntryId($a_cal_id);
72  return $new_rec;
73  }
+ Here is the caller graph for this function:

◆ _getRecurrences()

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 $ilDB, $query, $res, $row, array, and ilDBConstants\FETCHMODE_OBJECT.

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

45  {
46  global $ilDB;
47 
48  $query = "SELECT rule_id FROM cal_recurrence_rules " .
49  "WHERE cal_id = " . $ilDB->quote($a_cal_id, 'integer') . " ";
50  $res = $ilDB->query($query);
51  while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
52  $recurrences[] = new ilCalendarRecurrence($row->rule_id);
53  }
54  return $recurrences ? $recurrences : array();
55  }
foreach($_POST as $key=> $value) $res
$query
Create styles array
The data for the language used.
global $ilDB
+ Here is the caller graph for this function:

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