Commit graph

100997 commits

Author SHA1 Message Date
Sara Arjona
7ccfb2410a Merge branch 'MDL-71136_311' of https://github.com/TomoTsuyuki/moodle into MOODLE_311_STABLE 2021-04-22 13:56:43 +02:00
Shamim Rezaie
7f03204486 MDL-71144 mod_scorm: Deprecate scorm_get_completion_state() 2021-04-22 21:28:10 +10:00
Shamim Rezaie
ba90a6462d MDL-71144 mod_quiz: custom_completion should not use deprecated function
This commit also removes an unnecessary DB query.
2021-04-22 21:28:10 +10:00
Shamim Rezaie
7bdff82066 MDL-71144 mod_quiz: Deprecate quiz_get_completion_state() 2021-04-22 21:28:09 +10:00
Shamim Rezaie
e88a9462d1 MDL-71144 mod_lesson: Deprecate lesson_get_completion_state() 2021-04-22 21:28:09 +10:00
Shamim Rezaie
0780c6a7bd MDL-71144 mod_survey: Deprecate survey_get_completion_state() 2021-04-22 21:28:09 +10:00
Shamim Rezaie
223bee6bd0 MDL-71144 mod_glossary: Deprecate glossary_get_completion_state() 2021-04-22 21:28:09 +10:00
Jun Pataleta
81ddb3c13d MDL-71144 mod_forum: Deprecate forum_get_completion_state() 2021-04-22 21:28:09 +10:00
Jun Pataleta
c008814ca4 MDL-71144 mod_feedback: Deprecate feedback_get_completion_state() 2021-04-22 21:28:09 +10:00
Jun Pataleta
8e79ddef3b MDL-71144 mod_data: Deprecate data_get_completion_state() 2021-04-22 21:28:09 +10:00
Jun Pataleta
9dfc27cc33 MDL-71144 mod_choice: Deprecate choice_get_completion_state() 2021-04-22 21:28:09 +10:00
Jun Pataleta
bbe3a4882d MDL-71144 mod_assign: Deprecate assign_get_completion_state() 2021-04-22 21:28:09 +10:00
Jun Pataleta
e774335f16 MDL-71144 completion: Deprecate get_completion_state callbacks
* *_get_completion_state() callback functions have been deprecated and
should no  longer be used. Plugins that define custom completion rules
must implement the mod_[modname]\completion\custom_completion class that
extends the \core_completion\activity_custom_completion base class.
2021-04-22 21:28:09 +10:00
Sara Arjona
6abbca9754 Merge branch 'MDL-71400-311' of git://github.com/mihailges/moodle into MOODLE_311_STABLE 2021-04-22 13:16:29 +02:00
Ferran Recio
150280bafa MDL-70909 core: add cannotmatchanyrows to capabilities join 2021-04-22 13:09:47 +02:00
Jun Pataleta
672bbb6cd6 Merge branch 'MDL-71170_311' of git://github.com/mdjnelson/moodle into MOODLE_311_STABLE 2021-04-22 18:55:21 +08:00
Noel De Martin
5c1cf60ae4 MDL-71386 behat: Support for 3.9.5+ mobile app 2021-04-22 12:15:37 +02:00
Paul Holden
50fe1b9885 MDL-71200 mod_folder: ensure "Download folder" option is backed up. 2021-04-22 10:29:18 +01:00
Paul Holden
f0db656002 MDL-70979 search: validate external user search parameters.
Clean return value in unit test for same.
2021-04-22 10:22:42 +01:00
Paul Holden
1c00938de9 MDL-71392 mod_quiz: don't display grade to pass if not set. 2021-04-22 09:53:21 +01:00
Mihail Geshoski
3b1c29d233 MDL-71400 assignfeedback_offline: Fix message after worksheet upload 2021-04-22 13:08:44 +08:00
Jun Pataleta
78672323e6 Merge branch 'MDL-71156-311' of git://github.com/lameze/moodle into MOODLE_311_STABLE 2021-04-22 11:53:27 +08:00
Andrew Nicols
67f4a51f68 Merge branch 'MDL-69460-311' of https://github.com/paulholden/moodle into MOODLE_311_STABLE 2021-04-22 11:10:32 +08:00
Simey Lameze
10018bbc39 MDL-71156 core: machinery to recover orphaned calendar events
The machinery to fix orphaned calendar events that were broken by MDL-67494.

The solution consists of:

1) Upgrade step that checks if this site has executed the problematic upgrade steps and
   if positive, it will schedule a new run for calendar_fix_orphaned_events adhoc task.

2) Adhoc task that will self-spawn calling the recovery machinery, running until
   all the orphaned calendar events are fixed. It also sets the maximum runtime of
   60 seconds. It is also possible to override that number by specifing the desired
   number setting the ->calendareventsmaxseconds in your config.php

3) CLI script that will look for all the calendar events which userids
   where broken by a wrong upgrade step, affecting to Moodle 3.9.5
   and up.

   It performs checks to both:
     a) Detect if the site was affected (ran the wrong upgrade step).
     b) Look for orphaned calendar events, categorising them as:
       - standard: site / category / course / group / user events
       - subscription: events created via subscriptions.
       - action: normal action events, created to show common important dates.
       - override: user and group override events, particular, that some activities support.
       - custom: other events, not being any of the above, common or particular.

   By specifying it (--fix) try to recover as many broken events (missing userid) as
   possible. Standard, subscription, action, override events in core are fully supported but
   override or custom events should be fixed by each plugin as far as there isn't any standard
   API (plugin-wise) to launch a rebuild of the calendar events.

4) Unit tests and helper functions to generate calendar events. We have decided to
   keep the tests simple, testing only true and false and not using data generators because
   the code is purely to recover the calendar events and won't turn into an API or something
   and also due to the urgency of this issue.
   The helpers have been created in calendar/tests/helpers.php since there are no data generators
   for calendar.
2021-04-22 10:39:46 +08:00
Jun Pataleta
1ebb8d0264 Merge branch 'MDL-71288-311' of git://github.com/lameze/moodle into MOODLE_311_STABLE 2021-04-22 10:29:16 +08:00
Andrew Nicols
2fb5cb74e9 Merge branch 'MDL-70412-311' of git://github.com/aanabit/moodle into MOODLE_311_STABLE 2021-04-22 10:08:22 +08:00
abgreeve
bdd7f0a77c MDL-28452 profilefield_social: Setting the version number to today. 2021-04-22 10:05:04 +08:00
Simey Lameze
068f965a0a MDL-71288 completion: add fallback for plugins
This commits adds a fallback for plugins which does not have
custom_completion implementation.

For those cases, it will search for {modulename}_get_completion_state
callback in the plugin and call get_overall_completion() method in
cm_completion_details class to get the overall completion state for
a course module and user.
2021-04-22 09:46:19 +08:00
abgreeve
3f1727adcf Merge branch 'MDL-28452-311' of git://github.com/bmbrands/moodle into MOODLE_311_STABLE 2021-04-22 09:35:18 +08:00
Paul Holden
a760a65c5e MDL-57831 theme_boost: accessibility update for message preferences.
The preferences table did not meet accessibility guidelines regarding
colour contrast between hovered rows and the disabled switch
elements.

Ensure white background is used for all table cells, and replace the
highlighted columns used to differentiate processors with borders.
2021-04-21 21:50:51 +01:00
Sara Arjona
4070ef538b Merge branch 'MDL-64336-m311' of https://github.com/NeillM/moodle into MOODLE_311_STABLE 2021-04-21 17:14:08 +02:00
Marina Glancy
855d6249dc MDL-71394 core_blog: fix incorrect default setting in form
the keys of the options are strings, in PHP8 strings are compared with 0 differently
2021-04-21 16:24:11 +02:00
Neill Magill
e0da18119b MDL-64336 assign: Add missing PHP doc 2021-04-21 15:15:00 +01:00
Neill Magill
cffc41c27c MDL-64336 assign: Teachers should be able to see all submissions
Before this change a teacher would be able to see users listed if:

* They have an active enrolment and can submit
* They have an an inactive enrolment for a role that can submit

After this change they will additonally be able to see users listed:

* That have an active enrolment and have submitted
* That have an inactive enrolment and have submitted

This means that if an assignment has it's context frozen all users
that have made some form of submission will still be listed.

It will also apply if the submission capability is removed from a
user.

If a user's enrolment is deleted they will not be listed.

The submission and grading counts have also been updated so
they will reflect the new rules.
2021-04-21 15:15:00 +01:00
Neill Magill
be1c2eded5 MDL-64336 assign: Submissions should be visible while frozen
Before this change if a student visited an assignment that is
frozen they would only see the title and description even if
they had made a submission to it.

After the change they will be able to see the status of their
submission and any feedback and grades they have recived.

It will also make the Moodle app recognise that submission
should not happen because the assignment is frozen.

Tests based on ones created by Andrew Nicols
2021-04-21 15:14:59 +01:00
Marina Glancy
6d107d48c9 MDL-71389 various: changes to unittests due to php8 changes:
- some engine error messages changed
- some warning levels changed
- the carriage return symbol randomly appears
- one phpunit assertion fails and not really representative of anything
2021-04-21 12:39:02 +02:00
Bas Brands
698c57dc3a MDL-28452 core_user: add custom profilefield capability
Add a setting to show custom profilefields to self or others
with capability moodle/sit:viewuseridentity in the course context only
2021-04-21 11:24:36 +02:00
Bas Brands
6191a34c0f MDL-28452 core_user: add behat test for duplicate shortname warning 2021-04-21 11:24:36 +02:00
Bas Brands
37f26f211f MDL-28452 core_user: migrate social profile fields
Create a new profile field type, move all existing content of the fields
'icq', 'skype', 'aim', 'yahoo', 'msn' and 'url' in the mdl_user table to
theses new profile fields if needed.

AMOS BEGIN
MOV [aimid,core],[aimid,courseimage,profilefield_social]
MOV [yahooid,core],[yahooid,profilefield_social]
MOV [skypeid,core],[skypeid,profilefield_social]
MOV [icqnumber,core],[icqnumber,profilefield_social]
MOV [msnid,core],[msnid,profilefield_social]
MOV [webpage,core],[webpage,profilefield_social]
AMOS END
2021-04-21 11:24:34 +02:00
Sara Arjona
d68a8df7ea Merge branch 'dynreg-upgrade-squash-311' of https://github.com/cengage/moodle into MOODLE_311_STABLE 2021-04-21 09:58:38 +02:00
Jun Pataleta
bcc9028f20 Merge branch 'MDL-71017-311-2' of git://github.com/marinaglancy/moodle into MOODLE_311_STABLE 2021-04-21 14:56:54 +08:00
abgreeve
f0b4559bfe Merge branch 'MDL-71205_311' of https://github.com/mkassaei/moodle into MOODLE_311_STABLE 2021-04-21 13:31:44 +08:00
Jake Dallimore
25716402c1 Merge branch 'MDL-71030-311' of https://github.com/NashTechOpenUniversity/moodle into MOODLE_311_STABLE 2021-04-21 12:07:07 +08:00
abgreeve
dfda661753 Merge branch '311_MDL-71174' of git://github.com/danmarsden/moodle into MOODLE_311_STABLE 2021-04-21 11:02:13 +08:00
Eloy Lafuente (stronk7)
52dff48650 Merge branch 'MDL-63381_311_v3' of https://github.com/TomoTsuyuki/moodle into MOODLE_311_STABLE 2021-04-20 23:58:48 +02:00
Claude Vervoort
2eaf60e01b MDL-70500 lti: dyn reg can be used to update tools 2021-04-20 17:13:18 -04:00
Sara Arjona
3c71c49d28 Merge branch 'MDL-62244_311_label_view' of https://github.com/sheesania/moodle into MOODLE_311_STABLE 2021-04-20 17:45:01 +02:00
Marina Glancy
79949dc508 MDL-70897 various: uasort callback can not return bool
Co-authored-by: Ruslan Kabalin <ruslan.kabalin@gmail.com>
2021-04-20 14:59:44 +01:00
Sara Arjona
003dadc64d on-demand release 3.11dev+ 2021-04-20 15:52:10 +02:00
Sara Arjona
bfa5ef0ea0 Merge branch 'install_311_STABLE' of https://git.in.moodle.com/amosbot/moodle-install into MOODLE_311_STABLE 2021-04-20 15:52:07 +02:00