Moodle APIs 3.9
Moodle 3.9.13+ (Build: 20220325)
|
Calendar extension. More...
Classes | |
class | calendar_event |
class | calendar_information |
Functions | |
calendar_add_event_allowed ($event) | |
Check wether the current user is permitted to add events. More... | |
calendar_add_event_metadata ($event) | |
Add calendar event metadata. More... | |
calendar_add_icalendar_event ($event, $unused=null, $subscriptionid, $timezone='UTC') | |
Add an iCalendar event to the Moodle calendar. More... | |
calendar_add_month ($month, $year) | |
Get the next following month. More... | |
calendar_add_subscription ($sub) | |
Add an iCalendar subscription to the database. More... | |
calendar_can_edit_subscription ($subscriptionorid) | |
Checks to see if the user can edit a given subscription feed. More... | |
calendar_can_manage_non_user_event_in_system ($event) | |
Can current user manage a non user event in system context. More... | |
calendar_can_manage_user_event ($event) | |
Can current user edit/delete/add an user event? More... | |
calendar_day_representation ($tstamp, $now=false, $usecommonwords=true) | |
Return the representation day. More... | |
calendar_days_in_month ($month, $year) | |
Return the number of days in month. More... | |
calendar_delete_event_allowed ($event) | |
Return the capability for deleting a calendar event. More... | |
calendar_delete_subscription ($subscription) | |
Delete subscription and all related events. More... | |
calendar_edit_event_allowed ($event, $manualedit=false) | |
Return the capability for editing calendar event. More... | |
calendar_events_by_day ($events, $month, $year, &$eventsbyday, &$durationbyday, &$typesbyday, &$courses) | |
Get per-day basis events. More... | |
calendar_format_event_time ($event, $now, $linkparams=null, $usecommonwords=true, $showtime=0) | |
Get event format time. More... | |
calendar_get_allowed_event_types (int $courseid=null) | |
Get event types the user can create event based on categories, courses and groups the logged in user belongs to. More... | |
calendar_get_allowed_types (&$allowed, $course=null, $groups=null, $category=null) | |
Get calendar's allowed types. More... | |
calendar_get_calendar_context ($subscription) | |
Helper function to determine the context of a calendar subscription. More... | |
calendar_get_course_cached (&$coursecache, $courseid) | |
Get current course cache. More... | |
calendar_get_courselink ($course) | |
Get a HTML link to a course. More... | |
calendar_get_days () | |
Return the days of the week. More... | |
calendar_get_default_courses ($courseid=null, $fields=' *', $canmanage=false, int $userid=null) | |
Returns the default courses to display on the calendar when there isn't a specific course to display. More... | |
calendar_get_events ($tstart, $tend, $users, $groups, $courses, $withduration=true, $ignorehidden=true, $categories=[]) | |
Get calendar events. More... | |
calendar_get_events_by_id ($eventids) | |
Get calendar events by id. More... | |
calendar_get_eventtype_choices ($courseid) | |
Returns option list of available options for the calendar event type, given the current user and course. More... | |
calendar_get_filter_types () | |
Get the list of potential calendar filter types as a type => name combination. More... | |
calendar_get_footer_options ($calendar) | |
Get the calendar footer options. More... | |
calendar_get_group_cached ($groupid) | |
Get group from groupid for calendar display. More... | |
calendar_get_icalendar ($url) | |
From a URL, fetch the calendar and return an iCalendar object. More... | |
calendar_get_legacy_events ($tstart, $tend, $users, $groups, $courses, $withduration=true, $ignorehidden=true, $categories=[], $limitnum=0) | |
Get legacy calendar events. More... | |
calendar_get_link_href ($linkbase, $d, $m, $y, $time=0) | |
Adds day, month, year arguments to a URL and returns a moodle_url object. More... | |
calendar_get_link_next ($text, $linkbase, $d, $m, $y, $accesshide=false, $time=0) | |
Build and return a next month HTML link, with an arrow. More... | |
calendar_get_link_previous ($text, $linkbase, $d, $m, $y, $accesshide=false, $time=0) | |
Build and return a previous month HTML link, with an arrow. More... | |
calendar_get_module_cached (&$modulecache, $modulename, $instance) | |
Get current module cache. More... | |
calendar_get_pollinterval_choices () | |
Returns option list for the poll interval setting. More... | |
calendar_get_starting_weekday () | |
Gets the first day of the week. More... | |
calendar_get_subscription ($id) | |
Get the subscription from a given id. More... | |
calendar_get_timestamp ($d, $m, $y, $time=0) | |
Calculate the timestamp from the supplied Gregorian Year, Month, and Day. More... | |
calendar_get_view (\calendar_information $calendar, $view, $includenavigation=true, bool $skipevents=false, ?int $lookahead=null) | |
Get the calendar view output. More... | |
calendar_import_icalendar_events ($ical, $unused=null, $subscriptionid=null) | |
Import events from an iCalendar object into a course calendar. More... | |
calendar_internal_update_course_and_group_permission (int $courseid, context $context, array &$types) | |
Given a course id, and context, updates the permission types array to add the 'course' or 'group' permission if it is relevant for that course. More... | |
calendar_is_valid_eventtype ($type) | |
Check whether the specified event type is valid. More... | |
calendar_output_fragment_event_form ($args) | |
Request and render event form fragment. More... | |
calendar_process_subscription_row ($subscriptionid, $pollinterval, $action) | |
Update a subscription from the form data in one of the rows in the existing subscriptions table. More... | |
calendar_set_event_type_display ($type, $display=null, $user=null) | |
Sets the display of the event type given $display. More... | |
calendar_set_filters (array $courseeventsfrom, $ignorefilters=false, stdClass $user=null) | |
Returns the courses to load events for. More... | |
calendar_show_event_type ($type, $user=null) | |
Checks to see if the requested type of event should be shown for the given user. More... | |
calendar_sub_month ($month, $year) | |
Get the previous month. More... | |
calendar_time_representation ($time) | |
return the formatted representation time. More... | |
calendar_top_controls ($type, $data) | |
Get control options for calendar. More... | |
calendar_update_subscription ($subscription) | |
Update a calendar subscription. More... | |
calendar_update_subscription_events ($subscriptionid) | |
Fetch a calendar subscription and update the events in the calendar. More... | |
calendar_user_can_add_event ($course) | |
See if user can add calendar entries at all used to print the "New Event" button. More... | |
calendar_view_event_allowed (calendar_event $event) | |
Return the capability for viewing a calendar event. More... | |
core_calendar_user_preferences () | |
Implements callback user_preferences, whitelists preferences that users are allowed to update directly. More... | |
Variables | |
const | CALENDAR_DEFAULT_STARTING_WEEKDAY 1 |
CALENDAR_DEFAULT_STARTING_WEEKDAY - default value to display the starting weekday. | |
const | CALENDAR_DEFAULT_UPCOMING_LOOKAHEAD (!defined('MOODLE_INTERNAL')) 21 |
These are read by the administration component to provide default values. More... | |
const | CALENDAR_DEFAULT_UPCOMING_MAXEVENTS 10 |
CALENDAR_DEFAULT_UPCOMING_MAXEVENTS - default value to display the maximum number of upcoming event. | |
const | CALENDAR_DEFAULT_WEEKEND 65 |
CALENDAR_DEFAULT_WEEKEND - default value for weekend (Saturday & Sunday) | |
const | CALENDAR_EVENT_COURSE 2 |
CALENDAR_EVENT_COURSE - Course calendar event types. | |
const | CALENDAR_EVENT_COURSECAT 16 |
CALENDAR_EVENT_COURSECAT - Course category calendar event types. | |
const | CALENDAR_EVENT_GLOBAL 1 |
CALENDAR_EVENT_GLOBAL - Site calendar event types. More... | |
const | CALENDAR_EVENT_GROUP 4 |
CALENDAR_EVENT_GROUP - group calendar event types. | |
const | CALENDAR_EVENT_SITE 1 |
CALENDAR_EVENT_SITE - Site calendar event types. | |
const | CALENDAR_EVENT_TYPE_ACTION 1 |
CALENDAR_EVENT_TYPE_ACTION - Action events. | |
const | CALENDAR_EVENT_TYPE_STANDARD 0 |
CALENDAR_EVENT_TYPE_STANDARD - Standard events. | |
const | CALENDAR_EVENT_USER 8 |
CALENDAR_EVENT_USER - user calendar event types. | |
const | CALENDAR_EVENT_USER_OVERRIDE_PRIORITY 0 |
CALENDAR_EVENT_USER_OVERRIDE_PRIORITY - Constant for the user override priority. | |
const | CALENDAR_IMPORT_EVENT_INSERTED 2 |
CALENDAR_IMPORT_EVENT_INSERTED - imported event was added by insert. | |
const | CALENDAR_IMPORT_EVENT_SKIPPED -1 |
CALENDAR_IMPORT_EVENT_UPDATED_SKIPPED - imported event was skipped. | |
const | CALENDAR_IMPORT_EVENT_UPDATED 1 |
CALENDAR_IMPORT_EVENT_UPDATED - imported event was updated. | |
const | CALENDAR_IMPORT_FROM_FILE 0 |
CALENDAR_IMPORT_FROM_FILE - import the calendar from a file. | |
const | CALENDAR_IMPORT_FROM_URL 1 |
CALENDAR_IMPORT_FROM_URL - import the calendar from a URL. | |
const | CALENDAR_SUBSCRIPTION_REMOVE 2 |
CALENDAR_SUBSCRIPTION_REMOVE - Used to represent remove action for subscriptions in various forms. | |
const | CALENDAR_SUBSCRIPTION_UPDATE 1 |
CALENDAR_SUBSCRIPTION_UPDATE - Used to represent update action for subscriptions in various forms. | |
const | CALENDAR_TF_12 '%I:%M %p' |
CALENDAR_TF_12 - Calendar time in 12 hours format. | |
const | CALENDAR_TF_24 '%H:%M' |
CALENDAR_TF_24 - Calendar time in 24 hours format. | |
const | CALENDAR_URL $CFG->wwwroot.'/calendar/' |
CALENDAR_URL - path to calendar's folder. | |
Calendar extension.