integration.git
3 years agoMDL-74214 forms: re-calculate calendar panel zIndex each time. 29c00fc1000f6702ed26860868037976daeaf255
Paul Holden [Tue, 15 Mar 2022 13:41:06 +0000 (13:41 +0000)]
MDL-74214 forms: re-calculate calendar panel zIndex each time.

The previous iteration only calculated it's zIndex value on
initial load. This meant that any nodes added subsequent to this
would not be taken into account (e.g. modal forms).

3 years agoon-demand release 4.0beta+
Ilya Tregubov [Fri, 11 Mar 2022 10:20:26 +0000 (16:20 +0600)]
on-demand release 4.0beta+

3 years agoMerge branch 'MDL-73760-master-fix' of https://github.com/sarjona/moodle
Jun Pataleta [Fri, 11 Mar 2022 07:17:50 +0000 (15:17 +0800)]
Merge branch 'MDL-73760-master-fix' of https://github.com/sarjona/moodle

3 years agoMDL-73760 quiz: Fix behat failures with classic
Sara Arjona [Fri, 11 Mar 2022 06:39:59 +0000 (07:39 +0100)]
MDL-73760 quiz: Fix behat failures with classic

Author: Luca Bosch

3 years agoMerge branch 'MDL-71305-master' of git://github.com/rezaies/moodle
Jun Pataleta [Fri, 11 Mar 2022 03:51:00 +0000 (11:51 +0800)]
Merge branch 'MDL-71305-master' of git://github.com/rezaies/moodle

3 years agoMerge branch 'MDL-74032-master' of https://github.com/sammarshallou/moodle
Ilya Tregubov [Fri, 11 Mar 2022 03:23:17 +0000 (09:23 +0600)]
Merge branch 'MDL-74032-master' of https://github.com/sammarshallou/moodle

3 years agoMerge branch 'MDL-73895' of https://github.com/paulholden/moodle
Jun Pataleta [Fri, 11 Mar 2022 03:17:28 +0000 (11:17 +0800)]
Merge branch 'MDL-73895' of https://github.com/paulholden/moodle

3 years agoMerge branch 'MDL-74087-master-1' of git://github.com/mihailges/moodle
Jun Pataleta [Fri, 11 Mar 2022 01:28:46 +0000 (09:28 +0800)]
Merge branch 'MDL-74087-master-1' of git://github.com/mihailges/moodle

3 years agoMDL-54724 qtype_multianswer: fix version.php
Víctor Déniz [Fri, 11 Mar 2022 00:05:18 +0000 (00:05 +0000)]
MDL-54724 qtype_multianswer: fix version.php

3 years agoMerge branch 'MDL-54724-master' of https://github.com/cameron1729/moodle
Víctor Déniz [Thu, 10 Mar 2022 22:20:49 +0000 (22:20 +0000)]
Merge branch 'MDL-54724-master' of https://github.com/cameron1729/moodle

3 years agoMDL-74087 theme_boost: Add behat tests
Mihail Geshoski [Thu, 10 Mar 2022 14:30:00 +0000 (22:30 +0800)]
MDL-74087 theme_boost: Add behat tests

3 years agoMerge branch 'MDL-73760' of https://github.com/mkassaei/moodle
Sara Arjona [Thu, 10 Mar 2022 12:17:25 +0000 (13:17 +0100)]
Merge branch 'MDL-73760' of https://github.com/mkassaei/moodle

3 years agoMerge branch 'MDL-74142-master' of https://github.com/aanabit/moodle
Sara Arjona [Thu, 10 Mar 2022 10:58:21 +0000 (11:58 +0100)]
Merge branch 'MDL-74142-master' of https://github.com/aanabit/moodle

3 years agoMerge branch 'MDL-73908-master' of https://github.com/bmbrands/moodle
Jun Pataleta [Thu, 10 Mar 2022 09:15:34 +0000 (17:15 +0800)]
Merge branch 'MDL-73908-master' of https://github.com/bmbrands/moodle

3 years agoMerge branch 'MDL-73073-master_assign_timing_web_services' of https://github.com...
Ilya Tregubov [Thu, 10 Mar 2022 09:01:06 +0000 (15:01 +0600)]
Merge branch 'MDL-73073-master_assign_timing_web_services' of https://github.com/andrewmadden/moodle

3 years agoMerge branch 'MDL-74123_h5p_duplicate_file' of https://github.com/davosmith/moodle
Sara Arjona [Thu, 10 Mar 2022 07:40:55 +0000 (08:40 +0100)]
Merge branch 'MDL-74123_h5p_duplicate_file' of https://github.com/davosmith/moodle

3 years agoMerge branch 'MDL-73899-master' of https://github.com/andrewnicols/moodle
Jake Dallimore [Thu, 10 Mar 2022 07:34:21 +0000 (15:34 +0800)]
Merge branch 'MDL-73899-master' of https://github.com/andrewnicols/moodle

3 years agoMDL-73073 mod_assign: Add new time limit fields to external functions
Andrew Madden [Sun, 6 Feb 2022 13:24:13 +0000 (00:24 +1100)]
MDL-73073 mod_assign: Add new time limit fields to external functions

* Add activity, activityformat, timelimit and submissionattachments to mod_assign_get_assignments
* Add timestarted to mod_assign_get_submissions and mod_assign_get_submission_status
* Add assignmentdata to mod_assign_get_submission_status
* Move mod_assign external helper methods to an external_api child class to be used with modern external classes
* Add start_submission external function
* Create mod_assign child class of externallib_advanced_testcase for shared helper functions
* Add extra logic to get_assignments on whether to provide intro
attachments.

3 years agoMerge branch 'MDL-73520_replace-deprecated-php_errormsg-with-error_get_last' of https...
Jun Pataleta [Thu, 10 Mar 2022 04:28:28 +0000 (12:28 +0800)]
Merge branch 'MDL-73520_replace-deprecated-php_errormsg-with-error_get_last' of https://github.com/ziegenberg/moodle

3 years agoMerge branch 'MDL-74136-master' of https://github.com/junpataleta/moodle
Ilya Tregubov [Thu, 10 Mar 2022 03:25:11 +0000 (09:25 +0600)]
Merge branch 'MDL-74136-master' of https://github.com/junpataleta/moodle

3 years agoMerge branch 'MDL-67428-filter-context' of https://github.com/Peterburnett/moodle
Ilya Tregubov [Thu, 10 Mar 2022 03:04:05 +0000 (09:04 +0600)]
Merge branch 'MDL-67428-filter-context' of https://github.com/Peterburnett/moodle

3 years agoMerge branch 'master_MDL-67802_2' of https://github.com/mattporritt/moodle
Shamim Rezaie [Wed, 9 Mar 2022 21:57:16 +0000 (08:57 +1100)]
Merge branch 'master_MDL-67802_2' of https://github.com/mattporritt/moodle

3 years agoMerge branch 'MDL-74007' of https://github.com/timhunt/moodle
Eloy Lafuente (stronk7) [Wed, 9 Mar 2022 19:59:57 +0000 (20:59 +0100)]
Merge branch 'MDL-74007' of https://github.com/timhunt/moodle

3 years agoMerge branch 'MDL-74104-master' of https://github.com/ferranrecio/moodle
Sara Arjona [Wed, 9 Mar 2022 17:23:12 +0000 (18:23 +0100)]
Merge branch 'MDL-74104-master' of https://github.com/ferranrecio/moodle

3 years agoMerge branch 'MDL-73737' of https://github.com/paulholden/moodle
Eloy Lafuente (stronk7) [Wed, 9 Mar 2022 15:43:20 +0000 (16:43 +0100)]
Merge branch 'MDL-73737' of https://github.com/paulholden/moodle

3 years agoMerge branch 'MDL-73586' of https://github.com/stronk7/moodle
Sara Arjona [Wed, 9 Mar 2022 15:26:13 +0000 (16:26 +0100)]
Merge branch 'MDL-73586' of https://github.com/stronk7/moodle

3 years agoMerge branch 'MDL-71807' of https://github.com/stronk7/moodle
Sara Arjona [Wed, 9 Mar 2022 15:22:02 +0000 (16:22 +0100)]
Merge branch 'MDL-71807' of https://github.com/stronk7/moodle

3 years agoMerge branch 'MDL-74085-master' of https://github.com/sharidas/moodle
Jun Pataleta [Wed, 9 Mar 2022 14:45:59 +0000 (22:45 +0800)]
Merge branch 'MDL-74085-master' of https://github.com/sharidas/moodle

3 years agoMerge branch 'MDL-73923_tool_task_cronrunning-has-very-tight-limits-on-checking-cron...
Sara Arjona [Wed, 9 Mar 2022 12:52:51 +0000 (13:52 +0100)]
Merge branch 'MDL-73923_tool_task_cronrunning-has-very-tight-limits-on-checking-cron-interval-and-expected-frequency' of https://github.com/ziegenberg/moodle

3 years agoMDL-74085 data: Add entry button should follow max allowed entries
Sujith Haridasan [Mon, 7 Mar 2022 07:04:27 +0000 (12:34 +0530)]
MDL-74085 data: Add entry button should follow max allowed entries

When max entries is set in the database activity, the students
should not see the 'Add entry' button if they have reached the
maximum allowed entries.

3 years agoMerge branch 'MDL-73993-master' of https://github.com/golenkovm/moodle
Sara Arjona [Wed, 9 Mar 2022 12:24:29 +0000 (13:24 +0100)]
Merge branch 'MDL-73993-master' of https://github.com/golenkovm/moodle

3 years agoMDL-74032 core_cache: Coding error before upgrade with versioned cache
sam marshall [Tue, 8 Mar 2022 12:08:26 +0000 (12:08 +0000)]
MDL-74032 core_cache: Coding error before upgrade with versioned cache

In certain cases where it doesn't already redirect to run the upgrade,
users could see an exception 'Unexpectedly found non-versioned cache
entry'. This change ensures the upgrade happens instead.

3 years agoMerge branch 'MDL-73779_dynreg_sup_msgs' of https://github.com/cengage/moodle
Sara Arjona [Wed, 9 Mar 2022 12:11:12 +0000 (13:11 +0100)]
Merge branch 'MDL-73779_dynreg_sup_msgs' of https://github.com/cengage/moodle

3 years agoMDL-74104 mod_folder: fix recent activity with forcedownload links
Ferran Recio [Mon, 7 Mar 2022 13:31:45 +0000 (14:31 +0100)]
MDL-74104 mod_folder: fix recent activity with forcedownload links

The folder module has a setting to force the download links. However,
the recent activity block ignored this setting until now.

3 years agoMDL-74075 core_badges: Check accepted criterias
Amaia Anabitarte [Mon, 7 Mar 2022 12:27:39 +0000 (13:27 +0100)]
MDL-74075 core_badges: Check accepted criterias

3 years agoMerge branch 'MDL-73549-master-2' of https://github.com/HuongNV13/moodle
Ilya Tregubov [Wed, 9 Mar 2022 10:41:02 +0000 (16:41 +0600)]
Merge branch 'MDL-73549-master-2' of https://github.com/HuongNV13/moodle

3 years agoMDL-74142 mod_assign: Show time limit information to teachers
Amaia Anabitarte [Wed, 9 Mar 2022 10:08:14 +0000 (11:08 +0100)]
MDL-74142 mod_assign: Show time limit information to teachers

3 years agoMerge branch 'MDL-74097' of https://github.com/stronk7/moodle
Jun Pataleta [Wed, 9 Mar 2022 09:59:04 +0000 (17:59 +0800)]
Merge branch 'MDL-74097' of https://github.com/stronk7/moodle

3 years agoMerge branch 'MDL-72504-master' of https://github.com/aanabit/moodle
Ilya Tregubov [Wed, 9 Mar 2022 04:05:41 +0000 (10:05 +0600)]
Merge branch 'MDL-72504-master' of https://github.com/aanabit/moodle

3 years agoMerge branch 'MDL-74118-master' of https://github.com/aanabit/moodle
Ilya Tregubov [Wed, 9 Mar 2022 03:50:21 +0000 (09:50 +0600)]
Merge branch 'MDL-74118-master' of https://github.com/aanabit/moodle

3 years agoMDL-74136 theme_boost: Display blocks drawer icon properly on RTL
Jun Pataleta [Wed, 9 Mar 2022 02:07:11 +0000 (10:07 +0800)]
MDL-74136 theme_boost: Display blocks drawer icon properly on RTL

3 years agoMDL-67802 Authentication: Allow disabling email verification for OAuth
Matt Porritt [Tue, 8 Mar 2022 05:37:40 +0000 (05:37 +0000)]
MDL-67802 Authentication: Allow disabling email verification for OAuth

Allow email account verification to be disabled for any Oauth2 provider.
Also add clear indications to administrators of the danger of doing do,
this is done by an additional form checkbox.
This patch also reverts MDL-66598

3 years agoMDL-74087 theme_boost: Remove breadcrumb nodes that exist in primary nav
Mihail Geshoski [Tue, 8 Mar 2022 09:23:24 +0000 (17:23 +0800)]
MDL-74087 theme_boost: Remove breadcrumb nodes that exist in primary nav

Generally, we want to avoid displaying any breadcrumb nodes which are
already present in the primary navigation menu. Currently, this is done
by manually specifying which breadcrumb node (by its identification key)
should be removed. This change provides more reliable, automatic removal
of these breadcrum nodes by utilizing the exising method
remove_items_that_exist_in_navigation().

3 years agoMerge branch 'MDL-73846-master' of https://github.com/golenkovm/moodle
Sara Arjona [Tue, 8 Mar 2022 15:34:40 +0000 (16:34 +0100)]
Merge branch 'MDL-73846-master' of https://github.com/golenkovm/moodle

3 years agoMDL-73586 phpunit: Simply, remove the setting
Eloy Lafuente (stronk7) [Tue, 8 Mar 2022 13:11:26 +0000 (14:11 +0100)]
MDL-73586 phpunit: Simply, remove the setting

It's not available since PHP 7.0, so no use at all.

3 years agoMDL-73586 mod_wiki: Removed php init param for php80 and up
Eloy Lafuente (stronk7) [Tue, 8 Mar 2022 11:59:02 +0000 (12:59 +0100)]
MDL-73586 mod_wiki: Removed php init param for php80 and up

For PHP 8 and up, the 'mbstring.func_overload' doesn't exist
anymore, so skip any check/condition based on it.

The patch has been done that way, so it's easier to remove
the whole block of code once PHP 8.0 becomes our min supported
PHP version.

The change is self-coveres (changes the external and its own tests).

3 years agoMDL-74123 h5p: delete any existing files when downloading new files
Davo Smith [Tue, 8 Mar 2022 09:55:56 +0000 (09:55 +0000)]
MDL-74123 h5p: delete any existing files when downloading new files

3 years agoMDL-72504 block_myoverview: Show starred course changes
Amaia Anabitarte [Tue, 8 Mar 2022 12:40:43 +0000 (13:40 +0100)]
MDL-72504 block_myoverview: Show starred course changes

3 years agoMDL-74074 badges: Ensure profile criteria exists before completion check
Michael Hawkins [Thu, 3 Mar 2022 18:02:15 +0000 (02:02 +0800)]
MDL-74074 badges: Ensure profile criteria exists before completion check

3 years agoMDL-73586 mustache.php: Removed php init param for php80 and up
Eloy Lafuente (stronk7) [Tue, 8 Mar 2022 11:31:20 +0000 (12:31 +0100)]
MDL-73586 mustache.php: Removed php init param for php80 and up

The 'mbstring.func_overload' php init setting was removed for
php80 (it was deprecated since php72). So it won't evaluate to
true ever, so the whole block can be put under php version condition.

Note that this is already fixed upsteam, for commit:
https://github.com/bobthecow/mustache.php/commit/e7165a33b282ab4d20b3863825caadb46313d62b

And it has been released with version 2.14.1 of the library, so, once
we upgrade to it, the fix will be incorporated.

3 years agoMDL-73908 block_calendar_upcoming: new mod icons
Bas Brands [Tue, 22 Feb 2022 11:00:26 +0000 (12:00 +0100)]
MDL-73908 block_calendar_upcoming: new mod icons

3 years agoMDL-73908 block_recentlyaccassitems: new mod icons
Bas Brands [Wed, 16 Feb 2022 15:10:27 +0000 (16:10 +0100)]
MDL-73908 block_recentlyaccassitems: new mod icons

3 years agoMDL-71807 cleanup: Replace deprecated codingStandardsIgnore annotations a5c91474ee711f1ec9a18867ad7f00cc5b3b2969
Eloy Lafuente (stronk7) [Sat, 29 Jan 2022 22:52:19 +0000 (23:52 +0100)]
MDL-71807 cleanup: Replace deprecated codingStandardsIgnore annotations

The PHP_CodeSniffer @codingStandardsIgnore annotations are deprecated
and, since version 3.x, the new // phpcs:ignore comments should be used
instead.

This commits just reviews all the uses in core, replacing them for
the better new candidate, or removing when no longer needed.

3 years agoMDL-74097 core_text: Add some tests to cover all the logic
Eloy Lafuente (stronk7) [Sun, 6 Mar 2022 15:48:46 +0000 (16:48 +0100)]
MDL-74097 core_text: Add some tests to cover all the logic

3 years agoMDL-74097 core_text: Add coverage info to better see what's missing
Eloy Lafuente (stronk7) [Sun, 6 Mar 2022 15:33:49 +0000 (16:33 +0100)]
MDL-74097 core_text: Add coverage info to better see what's missing

3 years agoMDL-74097 core_text: Ensure that transliteration always happens
Eloy Lafuente (stronk7) [Sun, 6 Mar 2022 15:30:20 +0000 (16:30 +0100)]
MDL-74097 core_text: Ensure that transliteration always happens

Before the patch, transliteration was only happening when the
encoding of the string was utf-8. For other encodings only a
simpler conversion (iconv) to ascii was done. For some reason
iconv() own transliteration abilities are not consistent
between systems (depends of libraries installed, locales and
other bits).

So now we always convert the string to utf-8, in order to
transliterate it. And finally, also perform an iconv to
cover some characters that transliterate doesn't handle ok.

Also, remove a block of code that does nothing (previously
it was executing some code, but now it just sets and restores
the error level for nothing).

3 years agoMDL-72972 tool_uploaduser: observe capability to delete users.
Paul Holden [Thu, 13 Jan 2022 23:00:57 +0000 (23:00 +0000)]
MDL-72972 tool_uploaduser: observe capability to delete users.

3 years agoMDL-71722 h5plib_v124: Add required changes after lib upgrade
cescobedo [Fri, 11 Feb 2022 11:16:17 +0000 (12:16 +0100)]
MDL-71722 h5plib_v124: Add required changes after lib upgrade

3 years agoMDL-71722 h5plib_v124: Upgrade ckeditor to 4.17.1
cescobedo [Fri, 11 Feb 2022 10:04:38 +0000 (11:04 +0100)]
MDL-71722 h5plib_v124: Upgrade ckeditor to 4.17.1

3 years agoMDL-71703 lib: update phpmailer to 6.5.3
Ilya Tregubov [Mon, 10 Jan 2022 11:52:03 +0000 (13:52 +0200)]
MDL-71703 lib: update phpmailer to 6.5.3

3 years agoon-demand release 4.0beta+
Eloy Lafuente (stronk7) [Tue, 8 Mar 2022 09:02:22 +0000 (10:02 +0100)]
on-demand release 4.0beta+

3 years agoMDL-74118 themes: Last section style when one section per page
Amaia Anabitarte [Tue, 8 Mar 2022 08:40:07 +0000 (09:40 +0100)]
MDL-74118 themes: Last section style when one section per page

3 years agoMDL-73549 Course: My course page menu improvement
Huong Nguyen [Wed, 2 Mar 2022 06:16:18 +0000 (13:16 +0700)]
MDL-73549 Course: My course page menu improvement

 - Introduce core_course_category::get_nearest_editable_subcategory()
 - This function will return the first creatable/manageable category
for current user
 - With this new function, we can fix the issue that the users with
course management or creation permision at category level cannot see
the manage menu on My courses page

3 years agoMerge branch 'MDL-72646-font-mimetype' of https://github.com/doctorlard/moodle
Jun Pataleta [Tue, 8 Mar 2022 04:18:41 +0000 (12:18 +0800)]
Merge branch 'MDL-72646-font-mimetype' of https://github.com/doctorlard/moodle

3 years agoMerge branch 'MDL-66940-master' of https://github.com/sarjona/moodle
Ilya Tregubov [Tue, 8 Mar 2022 03:01:47 +0000 (05:01 +0200)]
Merge branch 'MDL-66940-master' of https://github.com/sarjona/moodle

3 years agoMDL-71305 core_question: Deprecate notflagged language string
Shamim Rezaie [Mon, 7 Mar 2022 00:32:14 +0000 (11:32 +1100)]
MDL-71305 core_question: Deprecate notflagged language string

3 years agoMDL-71305 core_question: Use toggle button for flag question element
Shamim Rezaie [Mon, 7 Mar 2022 00:31:56 +0000 (11:31 +1100)]
MDL-71305 core_question: Use toggle button for flag question element

3 years agoMerge branch 'MDL-74106' of https://github.com/paulholden/moodle
Jun Pataleta [Tue, 8 Mar 2022 01:46:29 +0000 (09:46 +0800)]
Merge branch 'MDL-74106' of https://github.com/paulholden/moodle

3 years agoMDL-73846 assignfeedback_editpdf: Add limit for convert_submissions task
Mikhail Golenkov [Tue, 8 Mar 2022 01:36:13 +0000 (12:36 +1100)]
MDL-73846 assignfeedback_editpdf: Add limit for convert_submissions task

3 years agoMerge branch 'MDL-74090-master' of https://github.com/junpataleta/moodle
Víctor Déniz [Tue, 8 Mar 2022 00:00:19 +0000 (00:00 +0000)]
Merge branch 'MDL-74090-master' of https://github.com/junpataleta/moodle

3 years agoMDL-74106 reportbuilder: handle non-recurring schedules properly.
Paul Holden [Mon, 7 Mar 2022 12:46:53 +0000 (12:46 +0000)]
MDL-74106 reportbuilder: handle non-recurring schedules properly.

When a schedule is created with "No recurrence", it should only be
sent when both conditions are true: it's start time is after the
current time; and the time it was last sent is before it's start
time (either 0/never sent; or a time it was manually sent).

3 years agoMDL-71305 core_question: Remove duplicate strings
Shamim Rezaie [Mon, 28 Feb 2022 02:30:54 +0000 (13:30 +1100)]
MDL-71305 core_question: Remove duplicate strings

3 years agoMDL-73760 Quiz: Manual grading report does not handle separate groups
Mahmoud Kassaei [Thu, 3 Mar 2022 21:24:43 +0000 (21:24 +0000)]
MDL-73760 Quiz: Manual grading report does not handle separate groups

when the user is not in any group

3 years agoMDL-73520 adodb: Remove usage of $php_errormsg from DB2 driver
Daniel Ziegenberg [Sun, 16 Jan 2022 20:28:01 +0000 (21:28 +0100)]
MDL-73520 adodb: Remove usage of $php_errormsg from DB2 driver

This applies #791 from upstream libraries: https://github.com/ADOdb/ADOdb/issues/791

Signed-off-by: Daniel Ziegenberg <daniel@ziegenberg.at>
3 years agoMDL-73520 general: replace deprecated php_errormsg with error_get_last()
Daniel Ziegenberg [Sun, 9 Jan 2022 14:39:49 +0000 (15:39 +0100)]
MDL-73520 general: replace deprecated php_errormsg with error_get_last()

For a better PHP8 compatibility this commit replaces the deprecated $php_errormsg
with error_get_last().

The PHP 8.0 migration guide (https://www.php.net/manual/de/migration80.incompatible.php) says:
    The track_errors ini directive has been removed.
    This means that php_errormsg is no longer available.
    The error_get_last() function may be used instead.
Also the documentation on $php_errormsg (https://www.php.net/manual/en/reserved.variables.phperrormsg.php) says:
    This feature has been DEPRECATED as of PHP 7.2.0.
    Relying on this feature is highly discouraged.
    Use error_get_last() instead.

Signed-off-by: Daniel Ziegenberg <daniel@ziegenberg.at>
3 years agoMDL-74090 core: Proper RTL/LTR display of collapsed icons
Jun Pataleta [Fri, 4 Mar 2022 16:35:30 +0000 (00:35 +0800)]
MDL-74090 core: Proper RTL/LTR display of collapsed icons

3 years agoMerge branch 'MDL-74020' of https://github.com/paulholden/moodle
Eloy Lafuente (stronk7) [Fri, 4 Mar 2022 15:52:21 +0000 (16:52 +0100)]
Merge branch 'MDL-74020' of https://github.com/paulholden/moodle

3 years agoMerge branch 'MDL-73824' of https://github.com/stronk7/moodle
Shamim Rezaie [Fri, 4 Mar 2022 13:39:29 +0000 (00:39 +1100)]
Merge branch 'MDL-73824' of https://github.com/stronk7/moodle

3 years agoMerge branch 'MDL-73954' of https://github.com/timhunt/moodle
Eloy Lafuente (stronk7) [Fri, 4 Mar 2022 13:20:27 +0000 (14:20 +0100)]
Merge branch 'MDL-73954' of https://github.com/timhunt/moodle

3 years agoMDL-73954 quiz: fix decimal places for the percentage on review page
Tim Hunt [Thu, 24 Feb 2022 17:06:51 +0000 (17:06 +0000)]
MDL-73954 quiz: fix decimal places for the percentage on review page

3 years agoMerge branch 'MDL-74042-master' of https://github.com/jleyva/moodle
Eloy Lafuente (stronk7) [Fri, 4 Mar 2022 11:19:22 +0000 (12:19 +0100)]
Merge branch 'MDL-74042-master' of https://github.com/jleyva/moodle

3 years agoMDL-66940 badges: Create page to display badges info
Sara Arjona [Mon, 14 Feb 2022 15:33:26 +0000 (16:33 +0100)]
MDL-66940 badges: Create page to display badges info

The OBv2.0 specification includes a field "Criteria" for
BadgeClass. Until now, this field was filled using the
URL of the badge assertion, but that is causing some issues
in Badgr because it linked to the badge assertion of the
first user sending this badge to the Badgr backpack (so then,
the following users linked to the first user assertion page
too).

This patch adds a new page, badgeclass.php which will be
used from now to display any badge information which is
not related to any assertion (like happens with the criteria
in BadgeClass).

3 years agoMDL-74007 quiz: questions should start as 'Always latest' version
Tim Hunt [Tue, 1 Mar 2022 15:50:53 +0000 (15:50 +0000)]
MDL-74007 quiz: questions should start as 'Always latest' version

Thanks to Safat Shahin <safatshahin@catalyst-au.net> for help with
the Behat scenarios.

3 years agoMerge branch 'MDL-73902-master' of https://github.com/bmbrands/moodle
Jun Pataleta [Fri, 4 Mar 2022 10:28:18 +0000 (18:28 +0800)]
Merge branch 'MDL-73902-master' of https://github.com/bmbrands/moodle

3 years agoMDL-73824 test: Cover all the changed code with special decsep tests
Eloy Lafuente (stronk7) [Mon, 21 Feb 2022 14:42:38 +0000 (15:42 +0100)]
MDL-73824 test: Cover all the changed code with special decsep tests

Various tests have been added to cover the points fixed in the previous
commit, using a localised decimal separator (#). Using the same
numbering, here there are the details:

A. grade/report/singleview/tests/behat/singleview.feature
   grade/tests/behat/grade_category_validation.feature

B. grade/tests/behat/grade_override_letter.feature

C. (done within various scenarios)

D. grade/report/singleview/tests/behat/singleview.feature

E. admin/tool/behat/tests/behat_form_text_test.php

F. grade/tests/behat/grade_to_pass.feature
   mod/lesson/tests/behat/lesson_informations_at_end.feature

G. quiz/tests/behat/preview.feature

H. mod/quiz/tests/behat/info_page.feature

I. question/type/ddimageortext/tests/behat/edit.feature

3 years agoMDL-73824 gradebook: Add support for localised floats where missing
Eloy Lafuente (stronk7) [Tue, 15 Feb 2022 15:38:13 +0000 (16:38 +0100)]
MDL-73824 gradebook: Add support for localised floats where missing

It has been detected, thanks to php80 specially, that there are
various places in core where support for localised floats is
missing. Before php80, some locale-dependent conversions were
performed by PHP, allowing things to work. But with php80 all
those comparisons are now locale-independent. See:

https://wiki.php.net/rfc/locale_independent_float_to_string

That implies that we now need to, always, unformat floats to
be internally the correct (decimal point as separator) in
order to compare it.

While this was visited in the php80 epic (MDL-70745), nothing
was found, all automated tests were passing ok. Problem is that
we run behat tests with en-AU laguage that has the decimal point
separator.

So, in this issue we are fixing all the problems detected by
running those Behat tests using localised (comma) decimal
separator.

Note that there may be other places still causing problems, but
it's really hard to find them programmatically, so we'll have to
wait for real use reports / issues and go fixing them while they
happen.

Back to this commit, this is the list of changes performed (note that
in the next commit, we'll be adding scenarios explicitly using
a localised decimal separator to ensure that they work ok).

A. Changes to various grade forms to ensure that, on their validation
  floats are unformatted properly. Also, changed the corresponding
  form element from current text/PARAM_RAW to proper float ones that
  take care of the conversion in a number of places (but when disabled,
  that's the reason we still have to unformat in validation.
  This includes the following forms:
    - edit_category_form
    - edit_item_form
  (this is the original problem reported that cause all the research
  to be performed against full behat runs)

B. Changes to edit_letter_form, so it uses a proper PARAM_LOCALISEDFLOAT
  (note this is the type of change that surely should be used for all
  the rest of /grade/edit/tree form, including those in the previous
  point).

C. Changes to the grade_item behat generator, so it's able to work with
  localised floats, un-formatting them when needed.
  At lib/behat/classes/behat_core_generator.php

D. Fix problem passing localised floats to scales, not displaying
  properly. At grade/report/singleview/classes/local/ui/finalgrade.php

E. Change the behat text matcher in order to allow comparison of
  localised floats when they are the current ones. Before this change
  the matches was using soft/lazy comparison, so '50' and '50.0000'
  match. Now, when the comma (for example) is used (and only then),
  '50' and '50,000' will also match. This comparison is in use in a
  bunch of tests and makes sense to make it localisation-aware.
  At grade/report/singleview/classes/local/ui/finalgrade.php

F. Fix a couple of number_format() uses in lesson, because they are
  not localised-aware. Switched to format_float(). At mod/lesson/locallib.php

G. Change the quiz_contains_the_following_questions() step to accept
  localised maxmark expectations. At mod/quiz/tests/behat/behat_mod_quiz.php

H. Change the quiz generator so it accepts localised gradepass.
  At mod/quiz/tests/generator/lib.php

I. Change the edit question form to show proper localised penalties,
  previously it was always showing point-decimal ones. Of course,
  leaving the values of the select element unmodified (internal floats).
  Related, also change a couple of tests to, instead of try to match the
  value (always internal floats), match the description (now localised),
  so we can test them with different separators. At:
    - question/type/ddimageortext/tests/behat/backup_and_restore.feature
    - question/type/ddmarker/tests/behat/backup_and_restore.feature
    - question/type/edit_question_form.php

3 years agoMerge branch 'MDL-74048-master' of https://github.com/bmbrands/moodle
Jake Dallimore [Fri, 4 Mar 2022 08:18:31 +0000 (16:18 +0800)]
Merge branch 'MDL-74048-master' of https://github.com/bmbrands/moodle

3 years agoMerge branch 'MDL-73796-master' of https://github.com/bmbrands/moodle
Jake Dallimore [Fri, 4 Mar 2022 06:56:09 +0000 (14:56 +0800)]
Merge branch 'MDL-73796-master' of https://github.com/bmbrands/moodle

3 years agoMerge branch 'MDL-73799' of https://github.com/stronk7/moodle
Jun Pataleta [Fri, 4 Mar 2022 06:47:39 +0000 (14:47 +0800)]
Merge branch 'MDL-73799' of https://github.com/stronk7/moodle

3 years agoMerge branch 'MDL-73785' of https://github.com/stronk7/moodle
Jun Pataleta [Fri, 4 Mar 2022 06:36:47 +0000 (14:36 +0800)]
Merge branch 'MDL-73785' of https://github.com/stronk7/moodle

3 years agoMerge branch 'MDL-73906-master' of https://github.com/bmbrands/moodle
Jun Pataleta [Fri, 4 Mar 2022 05:06:43 +0000 (13:06 +0800)]
Merge branch 'MDL-73906-master' of https://github.com/bmbrands/moodle

3 years agoMDL-67428 navigation: Apply navigation text filters at system context
Peter Spicer [Tue, 10 Dec 2019 15:31:37 +0000 (15:31 +0000)]
MDL-67428 navigation: Apply navigation text filters at system context

On some larger sites, processing the navigation with format_string will
habitually load all the contexts for navigation which can take 400+ DB
queries. Explicitly tying all those format_string calls to the system
context reduces this overhead to a single DB query that probably has
already been run on the page previously.

Co-authored-by: Peter Burnett <peterburnett@catalyst-au.net>
3 years agoMerge branch 'MDL-73457-master-2' of https://github.com/HuongNV13/moodle
Jake Dallimore [Fri, 4 Mar 2022 03:59:26 +0000 (11:59 +0800)]
Merge branch 'MDL-73457-master-2' of https://github.com/HuongNV13/moodle

3 years agoMerge branch 'MDL-74002' of https://github.com/Chocolate-lightning/moodle
Jake Dallimore [Fri, 4 Mar 2022 02:24:48 +0000 (10:24 +0800)]
Merge branch 'MDL-74002' of https://github.com/Chocolate-lightning/moodle

3 years agoMerge branch 'MDL-74045-master' of https://github.com/bmbrands/moodle
Shamim Rezaie [Thu, 3 Mar 2022 23:13:05 +0000 (10:13 +1100)]
Merge branch 'MDL-74045-master' of https://github.com/bmbrands/moodle

3 years agoMerge branch 'MDL-64770' of https://github.com/paulholden/moodle
Eloy Lafuente (stronk7) [Thu, 3 Mar 2022 22:20:26 +0000 (23:20 +0100)]
Merge branch 'MDL-64770' of https://github.com/paulholden/moodle

3 years agoMerge branch 'MDL-72915-master' of https://github.com/HuongNV13/moodle
Sara Arjona [Thu, 3 Mar 2022 16:30:54 +0000 (17:30 +0100)]
Merge branch 'MDL-72915-master' of https://github.com/HuongNV13/moodle

3 years agoMerge branch 'MDL-73841-master' of https://github.com/bmbrands/moodle
Sara Arjona [Thu, 3 Mar 2022 15:31:15 +0000 (16:31 +0100)]
Merge branch 'MDL-73841-master' of https://github.com/bmbrands/moodle

3 years agoMDL-73737 report_loglive: ensure action link popups work post-AJAX.
Paul Holden [Thu, 3 Feb 2022 20:23:30 +0000 (20:23 +0000)]
MDL-73737 report_loglive: ensure action link popups work post-AJAX.

3 years agoMDL-73923 tool_task: make a more relaxed check on cron run interval
Daniel Ziegenberg [Thu, 17 Feb 2022 18:54:41 +0000 (19:54 +0100)]
MDL-73923 tool_task: make a more relaxed check on cron run interval

Prior to this change, the tool_task_cronrunning check had very tight
limits for checking the last cron interval and comparing it to the
expected frequency. When a cron job should take 1:00 min and the last
run was 1:02 min it complained that there was 1:02 between the last two
runs of the cron maintenance script and it should run every 1:00.

This change makes the check a bit more relaxed and adds an additional
minute on top of the expectedfrequency to give the cron job some time.

Signed-off-by: Daniel Ziegenberg <daniel@ziegenberg.at>