ILIAS
eassessment Revision 61809
|
Class ilCalendarUtil. More...
Static Public Member Functions | |
static | _isToday ($date) |
check if a date is today | |
static | _numericMonthToString ($a_month, $a_long=true) |
numeric month to string | |
static | _numericDayToString ($a_day, $a_long=true) |
get | |
static | _buildWeekDayList ($a_day, $a_weekstart) |
build week day list | |
static | _buildMonthDayList ($a_month, $a_year, $weekstart) |
Build a month day list. | |
static | initJSCalendar () |
Init Javascript Calendar. | |
static | _getShortTimeZoneList () |
get short timezone list | |
static | _isLeapYear ($a_year) |
check if a given year is a leap year | |
static | _getMaxDayOfMonth ($a_year, $a_month) |
get max day of month 2008,2 => 29 | |
static | calculateFontColor ($a_html_color_code) |
Calculate best font color from html hex color code. | |
static | getHourSelection ($a_format) |
Get hour selectio depending on user specific hour format. | |
static | initDefaultCalendarByType ($a_type_id, $a_usr_id, $a_title, $a_create=false) |
Init the default calendar for given type and user. |
Static Public Attributes | |
static | $init_done |
Static Private Attributes | |
static | $today = null |
static | $default_calendar = array() |
|
static |
Build a month day list.
public
int | month |
int | year |
int | weekstart (0 => Sunday,1 => Monday) |
Definition at line 135 of file class.ilCalendarUtil.php.
References _getMaxDayOfMonth(), IL_CAL_FKT_DATE, IL_CAL_FKT_GETDATE, IL_CAL_UNIX, and ilDateList\TYPE_DATE.
Referenced by ilMiniCalendarGUI\addMiniMonth(), ilCalendarBlockGUI\addMiniMonth(), and ilCalendarMonthGUI\show().
|
static |
build week day list
public
ilDate | a day in a week |
int | weekstart |
Definition at line 103 of file class.ilCalendarUtil.php.
References IL_CAL_DAY, IL_CAL_FKT_GETDATE, and ilDateList\TYPE_DATE.
Referenced by ilObjBookingPoolGUI\buildDatesBySchedule(), ilObjBookingPoolGUI\renderList(), and ilCalendarWeekGUI\show().
|
static |
get max day of month 2008,2 => 29
public
int | year |
int | month |
Definition at line 396 of file class.ilCalendarUtil.php.
Referenced by _buildMonthDayList(), ilCalendarRecurrenceCalculator\applyBYMONTHDAYRules(), ilCalendarRecurrenceCalculator\getMonthWeekDays(), and ilCalendarSchedule\initPeriod().
|
static |
get short timezone list
public
Definition at line 287 of file class.ilCalendarUtil.php.
Referenced by ilOpenIdAttributeToUser\create(), ilSetupGUI\initBasicSettingsForm(), ilObjCalendarSettingsGUI\initFormSettings(), ilPersonalProfileGUI\initGeneralSettingsForm(), and ilCalendarUserSettingsGUI\initSettingsForm().
|
static |
check if a given year is a leap year
public
int | year |
Definition at line 368 of file class.ilCalendarUtil.php.
Referenced by ilCalendarRecurrenceCalculator\getYearWeekDays().
|
static |
check if a date is today
ilDateTime | $date | date to check |
Definition at line 45 of file class.ilCalendarUtil.php.
References ilDateTime\_equals(), IL_CAL_DAY, and IL_CAL_UNIX.
Referenced by ilMiniCalendarGUI\addMiniMonth(), ilCalendarBlockGUI\addMiniMonth(), and ilCalendarMonthGUI\show().
|
static |
get
public
int | day of week (0 for sunday, 1 for monday) |
bool | short or long day translation |
Definition at line 84 of file class.ilCalendarUtil.php.
References $lng.
Referenced by ilMiniCalendarGUI\addMiniMonth(), ilCalendarBlockGUI\addMiniMonth(), ilRecurrenceInputGUI\buildMonthlyByDaySelection(), ilRecurrenceInputGUI\buildWeekDaySelection(), ilRecurrenceInputGUI\buildYearlyByDaySelection(), ilCalendarHeaderNavigationGUI\getHTML(), ilAdvancedMDSubstitution\parseValue(), ilObjBookingPoolGUI\renderList(), ilCalendarDayGUI\show(), ilCalendarMonthGUI\show(), and ilCalendarWeekGUI\show().
|
static |
numeric month to string
public
int | month (1-12) |
bool | short or long month translation |
Definition at line 66 of file class.ilCalendarUtil.php.
References $lng.
Referenced by ilRecurrenceInputGUI\buildYearlyByDaySelection(), ilRecurrenceInputGUI\buildYearlyByMonthDaySelection(), ilDatePresentation\formatDate(), ilObjBookingPoolGUI\renderList(), ilCalendarDayGUI\show(), and ilCalendarWeekGUI\show().
|
static |
Calculate best font color from html hex color code.
public
string | hex value of color |
Definition at line 416 of file class.ilCalendarUtil.php.
Referenced by ilObjBookingPoolGUI\renderList(), ilCalendarDayGUI\showAppointment(), ilCalendarMonthGUI\showEvents(), ilCalendarDayGUI\showFulldayAppointment(), and ilCalendarWeekGUI\showFulldayAppointment().
|
static |
Get hour selectio depending on user specific hour format.
int | $a_format |
Definition at line 432 of file class.ilCalendarUtil.php.
References ilCalendarSettings\TIME_FORMAT_12, and ilCalendarSettings\TIME_FORMAT_24.
Referenced by ilObjCalendarSettingsGUI\initFormSettings(), and ilCalendarUserSettingsGUI\initSettingsForm().
|
static |
Init the default calendar for given type and user.
int | $a_type_id | |
int | $a_usr_id | |
string | $a_title | |
bool | $create |
Definition at line 462 of file class.ilCalendarUtil.php.
References $ilDB, $lng, $query, $res, $row, DB_FETCHMODE_OBJECT, and ilCalendarCategory\DEFAULT_COLOR.
Referenced by ilCalendarAppointmentGUI\bookconfirmed(), ilObjBookingPoolGUI\confirmedBookingObject(), and ilConsultationHoursGUI\createAppointments().
|
static |
Init Javascript Calendar.
Definition at line 200 of file class.ilCalendarUtil.php.
Referenced by ilBirthdayInputGUI\render(), ilDateTimeInputGUI\render(), and ilDateDurationInputGUI\render().
|
staticprivate |
Definition at line 36 of file class.ilCalendarUtil.php.
|
static |
Definition at line 37 of file class.ilCalendarUtil.php.
|
staticprivate |
Definition at line 35 of file class.ilCalendarUtil.php.