2018-07-19 10:34:44 +08:00
|
|
|
This files describes API changes for code that uses the user API.
|
|
|
|
|
2023-04-21 11:38:19 +01:00
|
|
|
=== 4.3 ===
|
|
|
|
|
|
|
|
* The following previously deprecated methods have been removed and can no longer be used:
|
|
|
|
- `profile_display_fields`
|
|
|
|
- `profile_edit_category`
|
|
|
|
- `profile_edit_field`
|
|
|
|
|
2022-11-25 22:22:44 +07:00
|
|
|
=== 4.2 ===
|
|
|
|
|
|
|
|
* Added get_internalfield_list() and get_internalfields() in the user_field_mapping class.
|
|
|
|
The get_internalfield_list() returns data in an array by grouping profile fields based on field categories,
|
|
|
|
used for internal field name dropdown in the user field mapping of Oauth2 services
|
|
|
|
The get_internalfields() converts the result from get_internalfield_list() into flat array,
|
|
|
|
used to save/update the profile data when a user uses OAuth2 services.
|
|
|
|
* Added get_profile_field_names() and get_profile_field_list() in the profile_field_base class.
|
|
|
|
The get_profile_field_names() returns the list of valid custom profile user fields.
|
|
|
|
The get_profile_field_list() returns the profile fields
|
|
|
|
in a format that can be used for choices in a group select menu.
|
2023-01-11 23:50:02 +00:00
|
|
|
* New method `core_user::is_current_user`, useful for components implementing permission callbacks for their preferences
|
2023-01-12 10:52:16 +00:00
|
|
|
* New `profile_get_user_field` method for returning profile field instance of given type
|
|
|
|
* The `profile_field_base::is_visible` method now accepts an optional `$context` argument
|
2023-03-16 16:56:07 +01:00
|
|
|
* External function core_user_external::add_user_private_files() now returns moodle_exception when the user quota is exceeded
|
2023-03-23 18:00:46 +01:00
|
|
|
* The `customfields` structure used for returning user profile fields information has been updated to:
|
|
|
|
* Return in the field `value` the value of the custom field (as stored in the database)
|
|
|
|
* Return in the field `displayvalue` the value of the custom field for display
|
2023-03-30 16:56:56 +02:00
|
|
|
External systems displaying user information should always use `displayvalue`.
|
2023-03-01 11:24:57 +13:00
|
|
|
* New method `user_update_device_public_key()`` and accompanying external function core_user_external::update_device_public_key to
|
|
|
|
update a user's app generated public key by device uuid and app id.
|
2022-11-25 22:22:44 +07:00
|
|
|
|
2021-10-28 15:58:43 +01:00
|
|
|
=== 4.1 ===
|
2022-11-11 09:45:39 +07:00
|
|
|
|
|
|
|
* Added a new method is_transform_supported() in the profile_field_base class.
|
|
|
|
The purpose is to allow the field to be transformed during the export process.
|
|
|
|
It has been implemented in the Date/Time data type (Applied in 4.1, 4.0.6).
|
|
|
|
|
2021-10-28 15:58:43 +01:00
|
|
|
* user_get_user_details_courses() now accepts an optional second parameter, an array of userfields that should be
|
|
|
|
returned. The values passed into the $userfields parameter must all be included in the return from
|
|
|
|
user_get_default_fields().
|
|
|
|
It also allows you to reduce how much of a user record is required by the method. The minimum user record fields are:
|
|
|
|
* id
|
|
|
|
* deleted
|
|
|
|
* all potential fullname fields
|
|
|
|
|
MDL-72509 core: De-couple participants filter from core_user to core
This implementation will de-couple the participant filter from
core user to core so its easily usable to any api in core or any
community plugin. This removes the dependency from the core_user
and creates a nice api where it can produce filterable objects.
Co-Authored-By: Safat Shahin <safatshahin@catalyst-au.net>
Co-Authored-By: Tomo Tsuyuki <tomotsuyuki@catalyst-au.net>
AMOS BEGIN
MOV [addcondition,core_user], [addcondition,core]
MOV [adverbfor_and,core_user], [operator_and,core]
MOV [adverbfor_andnot,core_user], [operator_andnot,core]
MOV [adverbfor_or,core_user], [operator_or,core]
MOV [applyfilters,core_user], [applyfilters,core]
MOV [clearfilterrow,core_user], [clearfilterrow,core]
MOV [clearfilters,core_user], [clearfilters,core]
MOV [filtersetmatchdescription,core_user], [filtersetmatchdescription,core]
MOV [filterrowlegend,core_user], [filterrowlegend,core]
MOV [filtertype,core_user], [filtertype,core]
MOV [match,core_user], [match,core]
MOV [matchofthefollowing,core_user], [matchofthefollowing,core]
MOV [placeholdertypeorselect,core_user], [placeholdertypeorselect,core]
MOV [selectfiltertype,core_user], [selectfiltertype,core]
AMOS END
2021-10-26 16:08:27 +11:00
|
|
|
* Participant filter is moved to core as an API which can be used in different areas of core by implementing the API
|
|
|
|
and filterable objects. As a part of making the API mature as a core one, these are the js files moved from core
|
|
|
|
user to core library:
|
|
|
|
* user/amd/src/local/participantsfilter/filter.js → lib/amd/src/datafilter/filtertype.js
|
|
|
|
* user/amd/src/local/participantsfilter/filtertypes/country.js → lib/amd/src/datafilter/filtertypes/country.js
|
|
|
|
* user/amd/src/local/participantsfilter/filtertypes/courseid.js → lib/amd/src/datafilter/filtertypes/courseid.js
|
|
|
|
* user/amd/src/local/participantsfilter/filtertypes/keyword.js → lib/amd/src/datafilter/filtertypes/keyword.js
|
|
|
|
* user/amd/src/local/participantsfilter/selectors.js → lib/amd/src/datafilter/selectors.js
|
|
|
|
The following mustache have been moved from core user to core library:
|
|
|
|
* user/templates/local/participantsfilter/filterrow.mustache → lib/templates/datafilter/filter_row.mustache
|
|
|
|
* user/templates/local/participantsfilter/filtertype.mustache → lib/templates/datafilter/filter_type.mustache
|
|
|
|
* user/templates/local/participantsfilter/filtertypes.mustache → lib/templates/datafilter/filter_types.mustache
|
|
|
|
* user/templates/local/participantsfilter/autocomplete_layout.mustache → lib/templates/datafilter/autocomplete_layout.mustache
|
|
|
|
* user/templates/local/participantsfilter/autocomplete_selection.mustache → lib/templates/datafilter/autocomplete_selection.mustache
|
|
|
|
* user/templates/local/participantsfilter/autocomplete_selection_items.mustache → lib/templates/datafilter/autocomplete_selection_items.mustache
|
|
|
|
Class participant_filter now extends core filter api in core user.
|
|
|
|
|
2022-10-04 16:09:35 +11:00
|
|
|
* The unified_filter function has been finally deprecated and cannot be used anymore
|
|
|
|
* The class \core_user\output\unified_filter has been finally deprecated and removed
|
|
|
|
|
2021-04-08 00:44:17 +00:00
|
|
|
=== 4.0 ===
|
|
|
|
|
|
|
|
* External function core_user_external::update_users() will now fail on a per user basis. Previously if one user
|
|
|
|
update failed all users in the operation would fail.
|
|
|
|
* External function core_user_external::update_users() now returns an error code and message to why a user update
|
|
|
|
action failed.
|
2021-06-28 20:40:28 +01:00
|
|
|
* New method `core_user\fields::get_sql_fullname` for retrieving user fullname format in SQL statement
|
2021-12-20 21:16:43 +00:00
|
|
|
* The `profile_get_custom_field_data_by_shortname` method now accepts an optional parameter to determine whether
|
|
|
|
to use case-sensitive matching of the profile field shortname or not (default true)
|
2021-04-08 00:44:17 +00:00
|
|
|
|
2020-01-22 23:00:58 +01:00
|
|
|
=== 3.11 ===
|
|
|
|
|
2020-01-22 23:18:11 +01:00
|
|
|
* Added new core_user/form_user_selector JS module that can be used as the 'ajax' handler for the autocomplete form
|
|
|
|
element implementing the user selector.
|
2020-01-22 23:00:58 +01:00
|
|
|
* Added new external function core_user_external::search_identity(). The main purpose of this external function is to
|
|
|
|
provide data for asynchronous user selectors and similar widgets. It allows to search users matching the given query
|
|
|
|
in their name or other available identity fields.
|
|
|
|
|
2020-05-06 18:39:22 +08:00
|
|
|
=== 3.9 ===
|
|
|
|
|
|
|
|
* The unified filter has been replaced by the participants filter. The following have therefore been deprecated:
|
|
|
|
* Library functions:
|
|
|
|
* user_get_participants_sql
|
|
|
|
* user_get_total_participants
|
|
|
|
* user_get_participants
|
|
|
|
* Unified filter renderer (core_user_renderer::unified_filter)
|
|
|
|
* Unified filter renderable (\core_user\output\unified_filter)
|
|
|
|
* Unified filter JavaScript (core_user/unified_filter.js and core_user/unified_filter_datasource.js)
|
|
|
|
* Unified filter template (unified_filter.mustache)
|
|
|
|
|
2018-07-19 10:34:44 +08:00
|
|
|
=== 3.6 ===
|
|
|
|
|
|
|
|
* The following functions have been finally deprecated and can not be used anymore:
|
|
|
|
* useredit_update_picture()
|
2018-11-08 15:02:12 +01:00
|
|
|
* core_user_external::update_user_preferences() now allows to unset existing preferences values.
|
|
|
|
If the preference value field is not set, the preference will be unset.
|