28 Commits

Author SHA1 Message Date
Andrew Nicols
0964cd5b69
MDL-81125 core: Update upgrade.txt files to document new upgrade notes 2024-05-20 22:26:45 +08:00
Paul Holden
0ac237d542
MDL-74500 user: method to determine whether to show profile fields.
The new API replaces identical behaviour in existing calling code, but
allows for profile field types to override/separate the logic used to
show the field and determine whether it's empty
2024-01-30 11:33:52 +00:00
hieuvu
a3da58a9cb MDL-78312 core_user: add an 'exact match only' option 2023-09-13 20:22:22 +07:00
Paul Holden
d096c60e0c
MDL-76974 user: deprecate old method of setting user preferences.
The `M.util.set_user_preference` method (plus accompanying helpers)
are now deprecated, in favour of the `core_user/repository` module
to achieve the same.

Update current implementation to proxy calls to the new API ensuring
backwards compatibility, while emitting copious developer debugging.
2023-08-22 14:42:58 +01:00
Paul Holden
c88d6ad8c3
MDL-70187 user: final removal of deprecated 39/311 methods. 2023-06-09 12:02:45 +01:00
Ilya Tregubov
59cd47c02f
Merge branch 'MDL-62859' of https://github.com/paulholden/moodle 2023-06-01 10:12:14 +08:00
Nathan Nguyen
f897ecd627 MDL-77353 core_user: new functions
New functions:
    * `core_user::get_profile_picture` for retrieving user picture.
    * `core_user::get_profile_url` for retrieving profile url.
    * `core_user::get_fullname` for retrieving user full name.

Note: the context is not used as this stage. It will be used by "User Disguises" plugin, which will be implemented later.
2023-05-24 13:05:02 +10:00
Paul Holden
10b6f979c5
MDL-62859 user: export methods for manipulating user preferences in JS. 2023-05-22 13:51:37 +01:00
Paul Holden
2b6d7d300a
MDL-71413 user: final removal of deprecated profile field methods. 2023-05-04 14:16:05 +01:00
Alex Morris
9bc236d48d MDL-76722 user: Add new update_user_device_public_key webservice 2023-04-11 08:58:27 +08:00
Sara Arjona
09171a3c3a Merge branch 'MDL-77726-master' of https://github.com/jleyva/moodle 2023-03-30 16:56:56 +02:00
Juan Leyva
fc97f32010 MDL-73226 files: Add quota checks to core_user_add_user_private_files 2023-03-27 13:11:46 +02:00
Juan Leyva
76807203a3 MDL-77726 user: Fix custom user profiles supporting filtering in WS 2023-03-23 18:08:03 +01:00
Paul Holden
25e8971b3a MDL-76873 user: method for returning profile field instance of type.
Re-factor implementation of profile field access within user fields
class to use that already provided by the fields themselves.
2023-02-20 09:24:05 +00:00
Paul Holden
75ab52d902 MDL-76878 user: amend permission callbacks for preference definitions.
Ensure those preferences that are used for storing state can always be
updated via web service requests for the current user.
2023-01-20 10:05:21 +00:00
Meirza
b79231361b MDL-61789 auth_oauth2: Update profile fields based on data mapping.
After the user creation, the system must call an update function to update profile_fields_*.
We also provided two functions into user/profile/lib.php to get available from other areas.
We added PHP unit testing for new public functions and
the Behat tests for custom profile fields with locked and unlocked statuses.

Co-authored-by: Matt Porritt <matt.porritt@moodle.com>
2023-01-07 20:59:26 +07:00
Meirza
7760f1bf34 MDL-72019 user: Allows data to be formatted when exporting. 2022-11-17 16:28:09 +07:00
David Woloszyn
7a9de2cb24 MDL-68868 core_user: Final deprecation of participants unified filter 2022-10-04 16:09:35 +11:00
Tomo Tsuyuki
68a5034b67 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
2022-09-27 12:07:36 +08:00
Neill Magill
6fb4a3b56e MDL-72948 messaging: Minimise fields used in query
Most of the fields in the query are not needed and are discarded
soon after visibility checks are made.
2022-06-22 10:11:18 +01:00
Paul Holden
9e6bbb4fb8 MDL-73086 user: account for mixed casing of profile field shortname.
Custom profile fields allow for shortnames containing mixed character
casing, which should also be supported within the user fields API
when retrieving said custom fields.

Given that the DML libs convert all selected columns to lowercased
equivalent, we need to do the same when requesting custom fields to
ensure calling code doesn't try to access `->profile_field_Foo`
property when the DB returns `->profile_field_foo` instead.
2021-12-29 15:09:30 +00:00
Paul Holden
4098af1c52 MDL-26171 user: implement method for retrieving fullname via SQL. 2021-06-29 16:35:35 +01:00
Matt Porritt
8281261b5a MDL-69194 user: make core_user_update_users return warnings
Add unit test coverage for the new warning scenarios.
2021-06-08 01:24:48 +00:00
David Mudrák
b389393dc5 MDL-67748 user: Add new core_user/form_user_selector JS module
The module provides AJAX support for the autocomplete form element.
2021-03-15 21:24:05 +01:00
David Mudrák
f51d3a81d6 MDL-67748 user: Add a new core_user_search_identity external function
The 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.
2021-03-15 21:24:05 +01:00
Michael Hawkins
03cb6064ea MDL-68612 user: Unified filter deprecations - renderer and renderable 2020-05-29 12:18:39 +08:00
Juan Leyva
2979ca1175 MDL-63929 user: Support unsetting prefs in update_user_preferences WS 2018-11-09 09:28:23 +01:00
Mihail Geshoski
f6094cd9f7 MDL-54858 user: Final deprecation of useredit_update_picture
Credit to Ankit Agarwal.
2018-07-30 09:13:20 +08:00