411 Commits

Author SHA1 Message Date
Andrew Nicols
92179b7057 MDL-71113 js: Fix all jsdoc warnings 2021-06-18 09:38:05 +08:00
Eloy Lafuente (stronk7)
9d6aa39985 MDL-71583 versions: Add all the missing full-stops to version/requires
It seems that the new phpcs3 checker is now controlling those
line comments that previously were ignored.

This commit just looks for all the cases and bulk-add
them when needed. The bash script (mac) used to add all them is:

while read -r line; do
    arr=(${line//:/ })
    if [[ -n ${arr[0]} ]] && [[ -n ${arr[1]} ]]; then
        echo "  file ${arr[0]}, line ${arr[1]}"
        sed -i "${arr[1]}s/\$/\./" ${arr[0]}
    fi
done < <(find . -name version.php | xargs ag --nomultiline '>(version|requires) *=.*//.*[^;\.]$')
2021-05-11 20:11:07 +02:00
Juan Leyva
47a142704d MDL-65983 airnotifier: Configuration check report 2021-04-12 11:23:06 +02:00
sam marshall
5e72715e4f MDL-71099 Lib: Move new user_fields class from core to core_user
This class would belong more appropriately within the 'user' API
(core_user) instead of within the 'core' API, since it is
directly related to user data.

Since the class has only just been added to Moodle, now is a good
time to move it.
2021-03-25 13:47:23 +00:00
Eloy Lafuente (stronk7)
ba5b6089d5 MDL-71036 phpunit: Renamed various regexp-related assertions
In PHPUnit 9.1, the following regexp-related assertions
have been deprecated and there are new alternatives for
all them:
    - assertRegExp()     -> assertMatchesRegularExpression()
    - assertNotRegExp()  -> assertDoesNotMatchRegularExpression()

This is about to, simply, move all cases to the new alternatives.

Source: https://github.com/sebastianbergmann/phpunit/blob/9.1.0/ChangeLog-9.1.md

Regexp to find all them:

    ag 'assertRegExp|assertNotRegExp' -li
2021-03-11 19:22:24 +01:00
sam marshall
558cc1b85e MDL-45242 Lib: Replace calls to deprecated functions
In all cases changes have been kept to a minimum while not making
the code completely horrible. For example, there are many instances
where it would probably be better to rewrite a query entirely, but
I have not done that (in order to reduce the risk of changes).
2021-03-10 10:57:10 +00:00
Eloy Lafuente (stronk7)
a72ea10b84 Merge branch 'MDL-70552-master' of git://github.com/ilyatregubov/moodle 2021-02-17 10:26:20 +01:00
Ilya Tregubov
729688b379 MDL-70552 core_message: Show popup for teachers when anonymous
user completed feedback.
2021-02-17 08:42:52 +02:00
Jun Pataleta
32ed88ad07 MDL-48269 messageoutput_email: Remove occurrences of hidepicture 2021-02-16 12:48:44 +08:00
Eloy Lafuente (stronk7)
77342b96fc MDL-69308 upgrade: remove all the < 3.6.0 upgrade steps
This just deletes all the upgrade steps previous to 3.6.0. Some
small adjustments, like tweaking globals can also be applied
when needed.

Also includes an upgrade step to prevent upgrading from any
version < 2018120300 (v3.6.0) as anti-cheating measure.

Note that in this case, there wasn't any case of upgradelib
functions being used, hence we haven't to deprecate/remove
anything in codebase. When there is such a need, that is done
in separate commits (one for each function) and documented here.

See MDL-65809 commits for an example removing/deprecating a
good number of functions.
2021-01-13 19:11:19 +01:00
Eloy Lafuente (stronk7)
cb163538bb Merge branch 'MDL-70081-master' of git://github.com/jleyva/moodle into master 2020-11-03 01:24:45 +01:00
Juan Leyva
4bc5333b05 MDL-70081 airnotifier: Add missing device type in token registration 2020-10-31 13:07:30 +01:00
Matteo Scaramuccia
6e97e31423 MDL-70042 message_popup: Trivial savepoint comment cleanup 2020-10-28 22:44:07 +01:00
Matteo Scaramuccia
fad0a943b2 MDL-70042 message_popup: progress bar on upgrade only when necessary 2020-10-28 22:41:48 +01:00
Eloy Lafuente (stronk7)
40de097e65 MDL-67673 phpunit: Remove deprecated assertContains() uses on strings
Both assertContains() and assertNotContains() are deprecated in PHPUnit 8
for operations on strings. Also the optional case parameter is. All uses
must be changed to one of:

- assertStringContainsString()
- assertStringContainsStringIgnoringCase()
- assertStringNotContainsString()
- assertStringNotContainsStringIgnoringCase()

More info: https://github.com/sebastianbergmann/phpunit/issues/3422

Regexp to find all uses:

ag 'assert(Not)?Contains\('
2020-10-21 12:46:00 +02:00
Eloy Lafuente (stronk7)
f6711bb394 MDL-67673 phpunit: Fix the return type of template methods
All the setup/teardown/pre/post/conditions template methods
now are required to return void. This was warned with phpunit 7
and now is enforced.

At the same time, fix a few wrong function names,
provider data and param types, return statements...
2020-10-21 12:45:59 +02:00
Jake Dallimore
b5b9bbc7fe Merge branch 'master_MDL-69848' of https://github.com/golenkovm/moodle 2020-10-14 09:41:39 +08:00
Simey Lameze
1c0baed969 MDL-65743 lib: add XMPPHP namespace and update calls 2020-10-05 13:37:51 +08:00
Mikhail Golenkov
6edd064414 MDL-69848 upgrade: Delete notifications in chunks 2020-10-05 12:11:28 +11:00
Eloy Lafuente (stronk7)
fbb0767536 MDL-69475 versions: bump all versions and requires in master
version = 2021052500 release version
requires= 2021052500 same than version

Why 20210525? (25th May 2021) ?

Because master is going to be Moodle 4.0, to be released
on November 2021. And, until then, we are going to have
a couple of "intermediate" releases:

- Moodle 3.10 to be released 9th November 2020. (2020110900)

  This version will be using versions from today to 2020110900
  (once it's released the YYYYMMDD part stops advancing).

- Moodle 3.11 to be released 10th May 2021. (2021051000)

  This version will be using versions from 3.10 release to 2021051000
  (once it's released the YYYYMMDD part stops advancing).

That means that all versions from today to 2021051000 are going
to be used by those 2 "intermediate" releases (3.10 and 3.11).

And we cannot use them in master, because it's forbidden to have
any overlapping of versions between branches (or different upgrade
paths will fail).

So, get that 2021051000, let's add it a couple of weeks to cover
the on-sync period (or a 2 weeks delay max!) and, the first version
that master can "own" in exclusive (without any overlap) is, exactly,
25th May 2021, hence our 20210525.
2020-08-18 00:47:15 +02:00
Andrew Nicols
e6ff582e1a Merge branch 'MDL-69150' of https://github.com/paulholden/moodle 2020-07-01 08:34:30 +08:00
Paul Holden
9071b2314f MDL-69151 message_airnotifier: start output before accesskey request.
This allows debugging generated by the request to be shown on the
page.
2020-06-26 17:34:02 +01:00
Paul Holden
54393e223a MDL-69150 message_airnotifier: correct apps portal link. 2020-06-26 17:13:56 +01:00
Eloy Lafuente (stronk7)
b764343e5a MDL-69044 upgrade: add 3.9.0 separation line to all upgrade scripts 2020-06-14 13:08:09 +02:00
Eloy Lafuente (stronk7)
115cc0214f MDL-68973 versions: bump all versions and requires near release
version = 2020061500 release version
requires= 2020060900 current rc1 (week7roll1) version
2020-06-09 16:23:09 +02:00
Shamim Rezaie
21d1a03b51 MDL-68312 output: Fix empty links
If a link contains no text, the function or purpose of the link will not
be presented to the user. This can introduce confusion for keyboard and
screen reader users.
2020-05-28 19:18:38 +10:00
Andrew Nicols
29c5fafff5 MDL-66109 js: Fix Shifter linting issues 2020-05-11 11:07:49 +08:00
Andrew Nicols
f879cc518e MDL-66109 js: Build changes for NodeJS upgrade
This change includes a build to fix all minified file changes in Moodle
as a result of upgrades to our build process.
2020-05-11 10:55:54 +08:00
Eloy Lafuente (stronk7)
7bf6fd4528 Merge branch 'MDL-67753-master' of git://github.com/jleyva/moodle 2020-05-07 18:44:45 +02:00
Juan Leyva
37bd67f54b MDL-67753 registration: Enable Push Notifications when site register
There are some changes to make this possible:
- Enable by default the Mobile notifications plugin
- Implement a new callback for core -> plugins communication
- Generate an Airnotifier access key in the callback when needed
2020-05-06 23:20:13 +02:00
Jake Dallimore
3e5c3cf8d9 Merge branch 'MDL-68293-master' of git://github.com/jleyva/moodle 2020-05-06 12:53:16 +08:00
Andrew Nicols
1174dcb184 Merge branch 'MDL-68465-master' of git://github.com/junpataleta/moodle 2020-05-05 11:29:10 +08:00
Eloy Lafuente (stronk7)
9b2b1f3fa5 Merge branch 'MDL-68434-master-enfix' of git://github.com/mudrd8mz/moodle 2020-04-29 22:52:40 +02:00
Eloy Lafuente (stronk7)
368dd60877 Merge branch 'MDL-64417' of https://github.com/paulholden/moodle 2020-04-28 23:55:22 +02:00
Helen Foster
1fce3f52ac MDL-68434 lang: Import fixed English strings (en_fix)
Significant string changes:

* pluginnamesummary,qtype_ddimageortext and
  pluginnamesummary,qtype_ddmarker - Note about the question type not
  being accessible to visually impaired users

* addresourceoractivity,core - Removing 'resource' as the new activity
  chooser doesn't have resource types separated
2020-04-28 14:01:20 +02:00
Juan Leyva
e624a2c8a1 MDL-68293 mobile: Update language strings to mention new app plans
We need to update different language strings to let our site admins know about the new app restrictions
(for both features and user devices able to receive notifications)
2020-04-27 18:26:30 +02:00
Jun Pataleta
f6f1014761 MDL-68465 message_email: Deprecate emaildigestsubject lang string 2020-04-24 11:42:40 +08:00
Jun Pataleta
1f7e9a698a MDL-68465 message_email: Add site name to digest email 2020-04-24 11:41:41 +08:00
Mark Nelson
4400ed3e1c MDL-58018 core: finish dev to support open sessions without a lock 2020-04-21 19:29:12 +02:00
Paul Holden
54cb5666c1 MDL-64417 message_popup: remove old notifications during cleanup task.
Add upgrade step to remove existing orphaned records.
2020-04-21 14:48:22 +01:00
Paul Holden
db8bda61a3 MDL-64417 message: allow processors to run their own cleanup tasks. 2020-04-21 14:48:22 +01:00
Adam Eijdenberg
82da35fd51 MDL-58018 core: Enable read-only sessions for key pages
These pages are often loaded in parallel.
2020-04-20 14:13:35 +02:00
Dani Palou
fbe3178a55 MDL-67907 airnotifier: Warn if some settings disabled after get key 2020-03-05 11:58:56 +01:00
Dani Palou
f95afbaf48 MDL-67758 airnotifier: Send wwwroot to airnotifier 2020-02-10 11:46:40 +01:00
Eloy Lafuente (stronk7)
dae0a8c405 Merge branch 'MDL-56389' of https://github.com/paulholden/moodle 2020-01-28 11:04:05 +01:00
Bas Brands
77e5b4462e MDL-67577 core_message: navbar_output order
* moved the logic from core_message_popup_render_navbar_output to
message_popup_render_navbar_output in message/output/popup/lib.php

* using float: left instead of float: right in theme
2020-01-27 12:14:16 +01:00
Paul Holden
b486073a9a MDL-56389 message_popup: less greedy marking of notifications as read.
Only mark those notifications that were returned in the last query as
read, based on the time they were requested.
2020-01-23 22:16:35 +00:00
Paul Holden
8725ac5f42 MDL-66237 message_popup: Get redirecturl from notification contexturl 2020-01-07 11:16:13 +08:00
Sara Arjona
a26cfe71d3 MDL-65809 upgrade: clean < 3.5.0 upgrade steps
This just deletes all the upgrade steps previous to 3.5.0. Some
small adjustments, like tweaking globals can also be applied
when needed.

Also includes an upgrade step to prevent upgrading from any
version < 2018051700 (v3.5.0) as anti-cheating measure.

Previous commits have removed/deprecated all the upgradelib functions
not used anymore in codebase. Deletion has been documented in corresponding
upgrade.txt files:

- upgrade_fix_block_instance_configuration()
- upgrade_theme_is_from_family(), upgrade_find_theme_location()
and linkcoursesectionsupgradescriptwasrun setting
- upgrade_block_positions
- upgrade_fix_config_auth_plugin_names()
 and upgrade_fix_config_auth_plugin_defaults()
- format_xxx_upgrade_remove_numsections(), format_xxx_upgrade_hide_extra_sections()
and format_xxx_upgrade_add_empty_sections()
- filter_mathjaxloader_upgrade_cdn_cloudflare()
and filter_mathjaxloader_upgrade_mathjaxconfig_equal()
- get_assignments_with_rescaled_null_grades()

These have been kept because continue being used by restore:

- \core\task\refresh_mod_calendar_events_task
2019-12-20 12:20:43 +01:00
Eloy Lafuente (stronk7)
492d047d11 MDL-67284 upgrade: add 3.8.0 separation line to all upgrade scripts 2019-11-17 11:40:19 +01:00