Commit graph

2300 commits

Author SHA1 Message Date
Sara Arjona
c4dad5b5e6 Merge branch 'MDL-71244-39' of git://github.com/lucaboesch/moodle into MOODLE_39_STABLE 2021-04-28 09:17:46 +02:00
Andrew Nicols
c7e65064b1 Merge branch 'MDL-70909-39' of git://github.com/ferranrecio/moodle into MOODLE_39_STABLE 2021-04-28 10:33:54 +08:00
Luca Bösch
2e7cc5e17c MDL-71244 enrol_manual: Add bootstrap classes to buttons 2021-04-27 17:24:51 +02:00
Ferran Recio
79071cdd87 MDL-70909 core: add cannotmatchanyrows to capabilities join 2021-04-27 15:44:25 +02:00
Paul Holden
c4fb2a2141 MDL-70099 enrol: increase accuracy of current enrolments by date.
By rounding the current time it was possible that the most recently
created user enrolments (e.g. self enrolments) were being excluded.

This would manifest itself in a user being enrolled on a course,
but it not appearing under "My courses" navigation or on their own
Dashboard until the rounded time had caught up with the current
time.
2021-04-05 19:32:07 +01:00
Eloy Lafuente (stronk7)
05c66fcebd Merge branch 'MDL-70967-39' of git://github.com/marinaglancy/moodle into MOODLE_39_STABLE 2021-03-10 23:35:33 +01:00
Eloy Lafuente (stronk7)
8d748b3401 Merge branch 'MDL-70424-auth-avoid-changes-MOODLE_39_STABLE' of https://github.com/brendanheywood/moodle into MOODLE_39_STABLE 2021-03-04 00:32:34 +01:00
Brendan Heywood
6feb10dd53 MDL-70424 auth: Avoid random changes to $CFG->auth 2021-03-04 09:31:51 +11:00
Paul Holden
787485d9eb MDL-70822 enrol: respect capability to view other users profile.
When retrieving courses of another user via web services, we should
respect the capability to view that users profile in a given course.
2021-03-02 23:37:35 +01:00
David Mudrák
d6adfa6446 MDL-70964 lang: Use the fixed strings in tests 2021-02-25 19:28:14 +01:00
Marina Glancy
31b1a9601f MDL-70967 enrol_meta: fix error in unittest 2021-02-22 18:06:49 +01:00
Andrew Nicols
34ba550138 MDL-66979 behat: Use tab to blur current focus
The focus should be on something, rather than removed.

The way in which focus removal works can lead to side effects.
2021-01-22 14:52:21 +08:00
Andrew Nicols
8c3091e5f3 MDL-69107 user: Fix autocomplete usages 2020-12-16 07:50:56 +08:00
David Matamoros
9e597d3658 MDL-63683 enrol: Fix plugin settings when no role has student archetype 2020-12-04 09:27:20 +01:00
Adrian Greeve
662d20869a Merge branch 'MDL-56653-39' of git://github.com/lameze/moodle into MOODLE_39_STABLE 2020-11-19 11:02:18 +08:00
Vitaly
12d4c82f98 MDL-56653 enrol_meta: a single DB query in edit_instance_validation
The 'edit_instance_validation()' method checks for existing meta enrolment instances.
The fix replaces DB queries in a loop for each course with a single query for all courses.
Also, a new testing method 'test_edit_instance_validation_with_existing_courses()'
was added to /enrol/meta/tests/plugin_test.php to test if the new implementation
returns an error in case of trying to save the already linked courses in the 'customint1' field.
2020-11-18 15:05:31 +08:00
Andrew Nicols
61d0134488 MDL-70148 behat: Update steps for keyboard 2020-11-17 15:14:43 +08:00
Mihail Geshoski
21cfc35074 MDL-67837 backup: Add unit tests 2020-11-03 12:27:34 +01:00
Helen Foster
9417cedd78 MDL-69998 lang: Import fixed English strings (en_fix) 2020-10-27 11:29:12 +01:00
Dani Palou
7aca3ebb3c MDL-68098 ws: Add unit tests to test mathjax in WS 2020-10-01 12:50:00 +02:00
Dani Palou
fba96f096b MDL-68098 ws: Fix WebServices broken by filters HTML 2020-09-23 16:23:19 +02:00
Víctor Déniz Falcón
6e5b0b5c20 MDL-69093 enrol_manual: added check for allowed roles a user can assign 2020-07-07 08:33:08 +02:00
Helen Foster
dc0241306b MDL-69130 lang: Import fixed English strings (en_fix)
Significant string change:

- presentationoraltrequired,atto_image - wording changed to mention
  'decorative only' checkbox
2020-06-25 21:52:35 +02:00
Eloy Lafuente (stronk7)
a30eb7d16c MDL-69044 upgrade: add 3.9.0 separation line to all upgrade scripts 2020-06-14 13:09:13 +02:00
Jake Dallimore
337e2e2b23 Merge branch 'MDL-68973' of https://github.com/stronk7/moodle 2020-06-10 16:13:57 +08:00
Andrew Nicols
a9075379d8 MDL-68977 enrol_manual: Add pending promises to enrol modal 2020-06-10 08:16:03 +08: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
Andrew Nicols
eb087fc5de MDL-68951 user: Add appropriate exceptions for table/participants 2020-06-08 09:35:39 +08:00
Bas Brands
6a4ce7b0a3 MDL-67386 theme_boost: upgrade bootstrap to version 4.5.0 2020-05-25 15:48:17 +02:00
Adrian Greeve
1c1fd15b18 Merge branch 'MDL-68333-master' of git://github.com/marinaglancy/moodle 2020-05-20 13:17:58 +08:00
Marina Glancy
5b529aca15 MDL-68333 testing: trigger user_created event in user generator 2020-05-19 19:11:54 +02:00
Andrew Nicols
abc83c40b5 MDL-68464 enrol_manual: Comment out buggy behat line
This is commented out because auto-hidden toasts currently call `hide()`
and trigger the `bs.toast.hide` event immediately, and _then_ apply the
autohide delay.

Since we automatically add M.util.pending_js calls when we _start_ to
hide, and resolve them when the hide _finishes_, this means that we do:
- addToast called
- trigger `bs.toast.show` event
- add to pending_js
- [pending_js queue not empty - behat waits]
- message is shown in UI
- `hide()` called
- trigger `bs.toast.hide` event
- add to pending_js
- [pending_js queue not empty - behat waits]
- start autohide delay
- [pending_js queue not empty - behat waits]
- [pending_js queue not empty - behat waits]
- [pending_js queue not empty - behat waits]
- [pending_js queue not empty - behat waits]
- end autohide delay
- remove message (no longer present in DOM)
- trigger `bs.toast.hidden` event
- resolve pending_js
- [pending_js queue empty - behat stops waiting]
- Behat runs next step: And I should see "1 enrolled users"
-- Step fails beacuse the message has been shown, and has then been removed

The conversation should have been:
- addToast called
- trigger `bs.toast.show` event
- add to pending_js
- [pending_js queue not empty - behat waits]
- message is shown in UI
- start autohide delay
- trigger `bs.toast.shown` event
- resolve pending_js
- [pending_js queue empty - behat stops waiting]
- Behat runs next step: And I should see "1 enrolled users"
-- Step passes
- autohide delay ends and calls `hide()`
- trigger bs.toast.hide event
- add to pending_js
- [behat waits]
- end autohide delay
- remove message (no longer present in DOM)
- trigger `bs.toast.hidden` event
- resolve pending_js
- [pending_js queue empty - behat stops waiting]
- Behat run continues

See MDL-67386 for futher information.
2020-05-19 12:37:21 +08:00
Andrew Nicols
e0e7b19f9c MDL-68464 enrol_manual: Reload participants table after enroling 2020-05-19 12:37:21 +08:00
Andrew Nicols
c50f5af248 MDL-68464 enrol_manual: Rewrite quickenrolment to use ES6 2020-05-19 12:33:40 +08:00
Andrew Nicols
7afd16ad84 MDL-66109 behat: Require newline at EOF
This change enables the gherkinlint rule to require a new line at the
end of the file. This change is in keeping with existing Moodle coding
style guidelines.
2020-05-11 11:07:49 +08:00
Mihail Geshoski
9fa46e8a8c MDL-67845 enrol_database: Remove enrol_database_admin_setting_category
This class was only used by the database enrolment plugin settings and
was replaced by admin_settings_coursecat_select. Also, this class is in
a plugin which we do not expect to be extended and therefore it can be
simply removed without going through the deprecation process.
2020-05-06 10:50:05 +08:00
Mihail Geshoski
b16f5398a5 MDL-67845 enrol_database: Use course category selection setting
We should use admin_settings_coursecat_select instead of
enrol_database_admin_setting_category as the second class is only
being used by the database enrolment plugin settings and can be
removed after this change.
2020-05-06 10:50:05 +08:00
Shamim Rezaie
3dec4c6ce3 MDL-68148 core_user: avoid multiple enrol buttons with the same id 2020-04-08 11:22:34 +10:00
Eloy Lafuente (stronk7)
9dc5d5ce0b Merge branch 'MDL-67827-master' of git://github.com/andrewnicols/moodle 2020-03-09 20:36:09 +01:00
Sara Arjona
6185f1ce24 Merge branch 'MDL-66671-master' of https://github.com/dthies/moodle 2020-03-09 18:49:02 +01:00
Andrew Nicols
604887ce8f MDL-67827 behat: Pending JS improvements for dialogues 2020-03-06 12:59:38 +08:00
Daniel Thies
158898254c MDL-66671 enrol_lti: Skip grade sync when cm deleted 2020-02-28 09:32:24 -06:00
Anthony Forth
bcc3a463f6 MDL-67945 enrol: missing $DB in edit_instance_form 2020-02-26 16:22:36 +01:00
Jun Pataleta
a762f048b8 Merge branch 'MDL-67118' of https://github.com/stronk7/moodle 2020-01-23 15:12:58 +08:00
Eloy Lafuente (stronk7)
011d55dd62 MDL-67118 enrol_ldap: add pagesize/subcontexts provider
With that provider we'll be explicitly checking that any
pagesize and subcontexts search is returning results consistently
so the internal paging/servercontrols work as expected.
2020-01-16 19:16:14 +01:00
Eloy Lafuente (stronk7)
ba62f54ef2 MDL-67118 enrol_ldap: paged results functions deprecated php74 and up
Starting with php74 the following functions are deprecated:
- ldap_control_paged_result()
- ldap_control_paged_result_response()

Starting with php73, ldap servercontrols were included. One of those
servercontrols, LDAP_CONTROL_PAGEDRESULTS, is the one in charge of
controlling paged results.

So, we are going to add some conditional code here:

1) if php < 7.3, use old paged result functions.
2) if php >= 7.3, switch to LDAP_CONTROL_PAGEDRESULTS servercontrol.

With a TODO about removing 1) in Moodle 4.1, once php73 becomes required.
2020-01-16 19:16:14 +01:00
David Mudrák
0845825659 MDL-66712 enrol: Fix the reported days of inactivity on unenrolment
There were two problems here. Firstly, the $days was not correctly
calculated due to missing parentheses. Secondly, the sentence had
grammar issues.
2020-01-16 13:35:01 +01:00
Eloy Lafuente (stronk7)
4621917c62 MDL-67114 core: php74 fix. Fix use of scalar as array in core
There are various places where it's not guaranteed that the
variable being used is array, and instead, can be null, bool, int...

We need to check that because php74 warns about it.

Where possible we have used the coalesce operator as
replacement for isset() ternary operations.
2020-01-03 11:33:15 +01:00
Adrian Greeve
42d7f7f9e4 Merge branch 'MDL-65809-master' of git://github.com/sarjona/moodle 2019-12-24 14:53:03 +08:00
Adrian Greeve
f00542c485 Merge branch 'MDL-66999-master' of git://github.com/bmbrands/moodle 2019-12-23 14:26:39 +08:00