Commit graph

100613 commits

Author SHA1 Message Date
Sara Arjona
52fd43f54d MDL-70911 core_badges: Remove $CFG->badges_site_backpack
The $CFG->badges_site_backpack setting has been completely removed
because it's not required anymore. From now, the primary site
backpack will be the first one in the "Manage backpacks" list (so,
the one with lower sortorder value).
2021-03-10 09:10:32 +01:00
Sara Arjona
3de96274ff MDL-70911 core_badges: Add support to backpacks sortorder
Before removing $CFG->badges_site_backpack setting, admins should be
able to re-order the existing site-backpacks (because then, the first
one will be treated as the default one).
This patch adds the sort order feature to the backpack list.
2021-03-10 08:31:22 +01:00
Sara Arjona
1a2db1297b MDL-70911 core_badges: Move "External backpack" to badges settings
Setting "External backpack connection" has been moved from "Backpack
settings" to "Badges settings" in order to make easier to find and
configure it.
Some extra tests have been added to cover existing behaviour and
confirm is still working as expected.
2021-03-10 08:31:22 +01:00
AMOS bot
d6d83cead2 Automatically generated installer lang files 2021-03-10 00:07:24 +00:00
Eloy Lafuente (stronk7)
b7b508c5d2 Merge branch 'MDL-63961-311' of git://github.com/sarjona/moodle into MOODLE_311_STABLE 2021-03-10 00:19:58 +01:00
Paul Holden
1fc653d7e0 MDL-69036 theme_boost: consistent table row hovering for links.
When hovering over table rows with the `dimmed_text` class we
should consistently set the text/link colour.

Co-Authored-By: Mikel Martín <mikel@moodle.com>
2021-03-09 16:22:33 +00:00
Sara Arjona
6e2a35733d Merge branch 'MDL-70608-311-langimportasync' of git://github.com/mudrd8mz/moodle into MOODLE_311_STABLE 2021-03-09 16:43:01 +01:00
Sara Arjona
b8f38fc98b Merge branch 'MDL-70815-311-6' of git://github.com/junpataleta/moodle into MOODLE_311_STABLE 2021-03-09 15:18:33 +01:00
Sara Arjona
3d10e6fd7f Merge branch 'MDL-70855-MOODLE_311_STABLE' of https://github.com/dmitriim/moodle into MOODLE_311_STABLE 2021-03-09 14:57:04 +01:00
Jun Pataleta
1292b31ac5 MDL-70815 completion: Test internal_get_state() with custom completion
Use the custom completion implementation for mod_choice to test
completion_info::get_state() to cover the case where the completion
state is being determined from the custom completion condition.
2021-03-09 20:19:00 +08:00
Jun Pataleta
f2599eb895 MDL-70815 mod_choice: Unit tests for the custom completion class 2021-03-09 20:19:00 +08:00
Jun Pataleta
4a9aeeca59 MDL-70815 mod_choice: Custom completion implementation 2021-03-09 20:19:00 +08:00
Jun Pataleta
ad5b613c86 MDL-70815 core_completion: Update completion_info
* Update completion_info::get_data() to add other completion
information from a new method called get_other_cm_completion_data().
This allows the storage of the completion statuses of the following
completion rules to completion_info objects:
  - 'Students must receive a grade' completion rule.
  - Any custom completion rule defined by an activity.
This allows detailed completion information to be fetched for course
modules.
It also allows custom completion statuses to be cached which will help
reduce DB queries when fetching completion statuses.
* Update update_state() to fetch overall completion state from the
module's activity_custom_completion implementation. Falls back to the
*_get_completion_state() callback function.
* Update internal_set_data() to include the other cm completion data
in the updated cache data for the module instance.
2021-03-09 20:18:59 +08:00
Jun Pataleta
31fcbfc2e2 MDL-70815 core_completion: completion_info::get_grade_completion()
Move the current logic for determining the completion status for the
"Student must receive grade" completion rule to a function so it cann
be reused.
Unit test included.
2021-03-09 20:18:59 +08:00
Jun Pataleta
baa0001037 MDL-70815 core_completion: Fix unit tests
* Unit tests for completion_info::get_data() and
completion_info::internal_get_state are mocked which causes failures
with the new implementation. It's more straightforward and realistic
to generate real course and modules to test these methods.
2021-03-09 20:18:59 +08:00
Jun Pataleta
e789f013b4 MDL-70815 core_completion: Unit tests for activity_custom_completion
Tests cover
 - get_overall_completion_state()
 - is_available()
 - validate_rule()
Tests don't cover
 - methods that rely on static methods such as:
   - is_defined()
 - static methods in the class because they can't be mocked
 - abstract methods that can be tested better by the plugins
   that extend activity_custom_completion such as:
   - get_state()
   - get_defined_custom_rules()
   - get_custom_rule_descriptions()
2021-03-09 20:18:59 +08:00
Jun Pataleta
6d2e36aa37 MDL-70815 core_completion: Activity custom completion details base class
* Base class for defining an activity module's custom completion details
2021-03-09 20:18:59 +08:00
Andrew Nicols
5a492fd886 MDL-70780 customfield: Rewrite management JS as ES6 2021-03-09 07:56:04 +08:00
Andrew Nicols
c6f1ee2977 MDL-70780 customfield: Address random behat fails
A number of behat fails have been creeping in with the customfield code
as behat is moving onto the next step before the current step finishes.

This change introduces some additional pending JS tracking to prevent
this.
2021-03-09 07:52:24 +08:00
Sara Arjona
217377d30f Merge branch 'MDL-70766-auth-config-log-MOODLE_311_STABLE' of https://github.com/brendanheywood/moodle into MOODLE_311_STABLE 2021-03-08 11:39:19 +01:00
sam marshall
5b7b1b9a06 MDL-45242 Lib: Replace direct references to ->showuseridentity 2021-03-08 09:17:04 +00:00
sam marshall
947d8c7806 MDL-45242 Lib: Deprecate field-related library functions 2021-03-08 09:17:04 +00:00
sam marshall
68e576b0ed MDL-45242 Lib: Allow custom profile fields in showuseridentity 2021-03-08 09:17:03 +00:00
sam marshall
f21cf5bc86 MDL-45242 Testing: Generators for user profile fields 2021-03-08 09:17:03 +00:00
sam marshall
23c20dc23f MDL-45242 Admin: Added lazy-loading callback to multicheckbox
Currently admin_setting_configselect has lazy-loading support via a
callback function (so you don't have to make pointless single-use
classes for each unusual setting), but this is not present in other
similar types.

This commit adds identical support to
admin_setting_configmulticheckbox.
2021-03-08 09:17:03 +00:00
Mikhail Golenkov
68588a8f47 MDL-71044 backup: backup_cleanup_task task to remove old files 2021-03-07 21:48:47 +11:00
AMOS bot
2e4ed73845 Automatically generated installer lang files 2021-03-07 00:07:24 +00:00
AMOS bot
f0b5d067bf Automatically generated installer lang files 2021-03-06 00:07:24 +00:00
Sara Arjona
f23ffe6645 weekly release 3.11dev 2021-03-05 16:01:36 +01:00
Sara Arjona
c644d61c34 Merge branch 'install_311_STABLE' of https://git.in.moodle.com/amosbot/moodle-install into MOODLE_311_STABLE 2021-03-05 16:01:34 +01:00
Amaia Anabitarte
291ff443a5 MDL-70726 behat: Fixing existing fail tests
Some of the current behat tests were wrong but not failing because of the bug in 'should not exist' step.
Once the bug is fixed, we must fix also wrong behats.
2021-03-05 14:06:43 +07:00
Ilya Tregubov
02af750568 MDL-69680 lib: Fix behat test backup_and_restore.feature 2021-03-04 22:51:18 +01:00
Paul Holden
99e1de9756 MDL-71048 lang: fix null equality check of lang string args. 2021-03-04 19:43:44 +00:00
Marina Glancy
8274935cb1 MDL-71039 core_form: support valuehtmlcallback in autocomplete inline 2021-03-04 13:39:45 +01:00
Thinh Pham
99a0d0e411 MDL-70727 Behat: function scrollIntoView not working in the app 2021-03-04 13:35:46 +07:00
Brendan Heywood
f8fe2fabfe MDL-71007 grade_report: Add course idnumber to grade report api
The gradereport_user_get_grade_items now includes the idnumber
2021-03-04 16:20:52 +11:00
Ilya Tregubov
4bc3faf193 MDL-69680 lib: Replace deprecated jQuery functions 2021-03-04 12:48:06 +08:00
Ilya Tregubov
f2e6985049 MDL-69680 lib: Update jQuery version in Moodle files 2021-03-04 12:48:06 +08:00
Ilya Tregubov
a5712a54fa MDL-69680 lib: Upgrade jQuery lib to 3.5.1 2021-03-04 12:48:06 +08:00
Eloy Lafuente (stronk7)
67c851ff81 Merge branch 'MDL-70424-auth-avoid-changes-MOODLE_311_STABLE' of https://github.com/brendanheywood/moodle into MOODLE_311_STABLE 2021-03-04 00:29:07 +01:00
Ilya Tregubov
6c399500e3 MDL-70767 feedback: Prevent xss in feedback answer text. 2021-03-03 23:08:50 +01:00
Sara Arjona
6c9e7f16f3 Merge branch 'MDL-68721-311' of git://github.com/ferranrecio/moodle into MOODLE_311_STABLE 2021-03-03 17:51:23 +01:00
Ferran Recio
f4a7aaf1f8 MDL-68721 mod_h5pactivity: report acceptance tests 2021-03-03 17:23:21 +01:00
Paul Holden
567529f722 MDL-65552 block_activity_results: correct Behat tests for idnumbers.
Teachers can see user idnumber fields only when they are configured
identity fields. Students cannot.
2021-03-03 23:14:54 +08:00
Marina Glancy
7ab4eafc02 MDL-65552 user: escape idnumber and email in table_sql 2021-03-03 23:14:54 +08:00
Paul Holden
2474bc765f MDL-65552 user: escape idnumber field on output.
This commit also corrects parameter definition of the field to
match core_user.
2021-03-03 23:14:54 +08:00
Sara Arjona
3fa69248c0 Merge branch 'MDL-70125_311-3' of git://github.com/mdjnelson/moodle into MOODLE_311_STABLE 2021-03-03 15:47:30 +01:00
Sara Arjona
b4dcde4dc2 Merge branch 'MDL-70921-311' of git://github.com/marinaglancy/moodle into MOODLE_311_STABLE 2021-03-03 15:24:51 +01:00
Sara Arjona
9f5794834e Merge branch 'MDL-67494-311' of git://github.com/lameze/moodle into MOODLE_311_STABLE 2021-03-03 11:47:00 +01:00
Sara Arjona
d30b045210 Merge branch 'MDL-67119-311' of git://github.com/aanabit/moodle into MOODLE_311_STABLE 2021-03-03 11:11:35 +01:00