[ Index ] |
PHP Cross Reference of Unnamed Project |
[Summary view] [Print] [Text view]
1 This files describes API changes in /enrol/* - plugins, 2 information provided here is intended especially for developers. 3 4 === 3.2 === 5 6 * External function core_enrol_external::get_users_courses now return the category id as an additional optional field. 7 8 === 3.1 === 9 10 * core_enrol_external::get_enrolled_users now supports two additional parameters for ordering: sortby and sortdirection. 11 * Enrolment plugins UI have been consolidated. Plugins can implement use_standard_editing_ui() function 12 and add edit_instance_form() and edit_instance_validation() methods instead of providing their own edit.php and form. 13 They can then rely on the default implementation of get_action_icons and get_course_navigation. In future this will 14 mean they can be called by webservices/user upload tools because they can validate their data. 15 16 === 3.0 === 17 18 * Added new events enrol_instance_created, enrol_instance_updated and 19 enrol_instance_deleted . Always trigger them when changing records in the 20 DB table 'enrol'. 21 * Constant CACHE_COURSE_CONTACTS_TTL was deleted. 22 * External function core_enrol_external::get_enrolled_users now returns only the viewable participants if the course has groups enabled and no groupid is passed. 23 24 === 2.9 === 25 26 * External function core_enrol_external::get_users_courses now returns additional optional fields: 27 - summary: Course summary. 28 - summaryformat: Course summary format. 29 - format: Course format. 30 - showgrades: True if grades are shown, otherwise false. 31 - lang: Forced course language. 32 - enablecompletion: Control or not via completion and activity settings. 33 34 === 2.8 === 35 36 * enrol_plugin::instance_deleteable() is deprecated and has been replaced by enrol_plugin::can_delete_instance() 37 * enrol_plugin::can_hide_show_instance() is a new function to control who can hide/show enrolment instances. 38 Returns true by default but plugins must implement their own logic. 39 40 === 2.6 === 41 42 * Enrolment plugin which supports self enrolment should implement can_self_enrol() 43 * Enrolment plugin should implement get_enrol_info() to expose instance information 44 with webservice or external interface. 45 * Webservice core_enrol_get_enrolled_users_with_capability was incorrectly specifing 46 float as the return type for user id. int is the actual returned type and is now 47 reported as such. 48 49 === 2.5 === 50 51 * plugins may use general enrol/editenrolment.php page to let users edit 52 enrolments manually 53 * new support for grade recovery in enrol_plugin::enrol_user() method 54 55 === 2.4 === 56 57 required changes in code: 58 * use role_get_name() or role_fix_names() if you need any role names, using role.name 59 directly from database is not correct any more 60 * new restore support: ENROL_RESTORE_EXACT, ENROL_RESTORE_NOUSERS 61 and ENROL_RESTORE_CLASS were removed, implement new restore_* plugin methods instead 62 63 other changes and new features: 64 * course enrolment manager now works with disabled plugins too 65 * new support for protected group membership linked to enrol instance 66 * new support for expiry notifications - see enrol_plugin::send_expiry_notifications() method 67 68 69 === 2.2 === 70 71 required changes in code: 72 * load_temp_role() is deprecated, use load_temp_course_role() instead, temp role not loaded 73 * remove_temp_role() is deprecated, use remove_temp_course_roles() instead 74 * 'user_unenrol_modified' event was renamed to 'user_enrol_modified' 75 76 77 === 2.0 === 78 79 required changes in code: 80 * enrolment plugins need to be rewritten to use new API - see inline phpdocs and official plugins
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Thu Aug 11 10:00:09 2016 | Cross-referenced by PHPXref 0.7.1 |