Commit Graph

705 Commits

Author SHA1 Message Date
Andrew Nicols 551371c710 Merge branch 'MDL-71834-master-v02' of git://github.com/ferranrecio/moodle 2021-10-11 14:06:23 +08:00
Ferran Recio d4bebe639f MDL-72578 core_courseformat: fix renderers deprecation messages 2021-10-07 17:17:29 +02:00
Ferran Recio fb753618a8 MDL-72578 course: fix format backward compatibility
The existing course format plugins are not adapted tu use the new
courseformat subsystem. This means they don't provide a valid renderer,
or hardcode the inclusion of the topics renderer.php file, or do not
extend the format renderer but the core one (missing some methods). This
commit provides some quick fixes to prevent exceptions.
2021-10-07 17:17:29 +02:00
Ferran Recio 41b4625693 MDL-72578 course: activity render to output classes 2021-10-07 17:17:29 +02:00
Andrew Nicols fa72197258 MDL-72463 courseformat: Add missing docs 2021-10-05 23:20:41 +02:00
Andrew Nicols b7687bfef8 Merge branch 'MDL-72463-master' of git://github.com/ferranrecio/moodle 2021-10-05 23:20:41 +02:00
Andrew Nicols 8b7fb0f7ab Merge branch 'MDL-71795-master' of git://github.com/ferranrecio/moodle 2021-10-05 23:18:46 +02:00
Ferran Recio 7ad939c592 MDL-71795 courseformat: course index in activity page 2021-10-01 09:03:56 +02:00
Ferran Recio 5a165c86a2 MDL-71795 courseformat: add cache to course index 2021-10-01 09:03:56 +02:00
Andrew Nicols d46ff2929e Merge branch 'MDL-71727-master-v03' of git://github.com/ferranrecio/moodle 2021-09-30 09:52:56 +08:00
Ferran Recio 639a99014d MDL-71834 course: lock elements
Now components has a new property lock to disable all user interactions.
This is applied directly into the course index and course content to
freeze an element if some action is performed over it. To set this
locked value there are 2 new mutations cmLock and sectionLock.
2021-09-29 11:34:43 +02:00
Ferran Recio 96c6dc53cd MDL-72463 courseformat: course index highlight section badge 2021-09-29 11:32:03 +02:00
Ferran Recio 9abf7e1a72 MDL-71727 course: sync dragged elements
Two new mutations are added to indicate that a section
or a cm is being dragged. The logic related to refresh
a section or a cm has been moved to components to
simplify the code.
2021-09-29 10:01:25 +02:00
Ferran Recio a0b4cacc8c MDL-71828 courseformat: course index section link toggler 2021-09-29 09:57:24 +02:00
Ilya Tregubov 6cc0d5dfbd Merge branch 'MDL-71828-master' of git://github.com/ferranrecio/moodle 2021-09-24 08:49:32 +02:00
Ferran Recio 05b6f68f65 MDL-71828 courseformat: course index section link toggler 2021-09-22 20:10:04 +02:00
Jun Pataleta ed0d7efa2f Merge branch 'MDL-71664-master-v04' of git://github.com/ferranrecio/moodle 2021-09-22 21:17:32 +08:00
Ferran Recio 23499e6447 MDL-71664 course: add browser native drag and drop 2021-09-22 11:08:06 +02:00
Jun Pataleta 99cb8a7303 Merge branch 'MDL-71037-master-8' of git://github.com/ilyatregubov/moodle 2021-09-22 14:44:17 +08:00
Ilya Tregubov f2e28c0561 MDL-71037 course: Make sections collapsible for Topics/Weeks format. 2021-09-21 18:41:59 +02:00
Amaia Anabitarte 5c54b1a608 MDL-72387 core_course: section navigation visiblity for students 2021-09-20 21:49:19 +02:00
Eloy Lafuente (stronk7) 433212a33e Merge branch 'MDL-72093-master' of git://github.com/mihailges/moodle 2021-09-16 00:32:47 +02:00
Ilya Tregubov de814baafe Merge branch 'MDL-72310-master' of git://github.com/aanabit/moodle 2021-09-15 14:06:17 +02:00
Mihail Geshoski 7d821080f0 MDL-72093 navigation: Update behat tests 2021-09-14 12:02:35 +08:00
Ferran Recio 7659a18993 MDL-71228 course: sorting course on section state change 2021-09-09 11:16:10 +02:00
Ferran Recio 7f750dc01c MDL-71228 course: course index drag and drop 2021-09-09 11:16:10 +02:00
Amaia Anabitarte c5578db866 MDL-72310 core_course: Expand course index sections by default 2021-09-03 12:25:33 +02:00
Eloy Lafuente (stronk7) a65c0bbc0a MDL-71847 course: small tests fixes.
1) Namespace must match the one being covered.
2) the @covers annotation was wrong, missing class name(s). At the
   end I've used the coversDefaultClass annotation that allows to
   specify a whole namespace, useful in this case to get the 3
   existing (course, section, cm) classes covered.
2021-08-23 20:14:51 +02:00
Eloy Lafuente (stronk7) 101355638b Merge branch 'MDL-71847-master' of git://github.com/ilyatregubov/moodle 2021-08-23 18:48:25 +02:00
Ferran Recio 0b18d478a2 MDL-71209 courseformat: disable course index in mod 2021-08-23 12:49:22 +02:00
Ferran Recio ef745009ed MDL-71209 courseformat: add state suport to legacy action
Adapt the current course editing libraries to modify also
the course state data. This way, any UI component that
watches the course structure can react to the changes.
2021-08-20 16:49:06 +02:00
Ferran Recio 830c3eb907 MDL-71209 courseformat: add course index modules
The course index is the first UI component that implements the new
drawers and the reactive components. The course index uses the course
state to present the current course structure and changes whenever
that structure change.
2021-08-20 16:49:06 +02:00
Ilya Tregubov 7226a0fe5f MDL-71847 course: Cover state classes with direct unit tests. 2021-07-09 13:43:17 +02:00
Ferran Recio 1c0abade3e MDL-71863 core_courseformat: mode site renderer to autoload 2021-06-29 11:52:48 +02:00
Ferran Recio 176bf81cb1 MDL-71863 courseformat: new course editor methods in courseeditor AMD
The module now exports a getCourseEditor and a getCurrentCourseEditor
methods. The module is more consistent as it can be used to get
other course than the current one.
2021-06-28 13:50:18 +02:00
Ferran Recio 21d93554d4 MDL-71863 courseformat: create courseformat subsystem 2021-06-28 13:50:18 +02:00
Luca Bösch 9fc6c45b10 MDL-71634 course: Do not show "Your progress" info any more. 2021-06-17 19:22:13 +02: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
Ferran Recio 6ae566c55d MDL-71141 course: fix frontpage section warning 2021-04-12 12:41:10 +02:00
Ferran Recio 8e7dc42440 MDL-65974 course: move format renderers to outputs 2021-03-11 17:36:34 +01:00
Ferran Recio 1c839f9072 MDL-65974 course: move format_base to core_course\course_format 2021-03-11 17:36:34 +01: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
Andrew Nicols 0d580d2b3e MDL-67668 behat: Update tests for inplace editable field type 2020-11-23 09:01:19 +08:00
Andrew Nicols ba34d6e225 MDL-70148 behat: Update steps for keyboard 2020-11-17 15:14:43 +08: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
Stephen Bourget 1a453e4d8d MDL-69630 format_social: Add ajax support 2020-09-10 19:04:34 -04:00
Eloy Lafuente (stronk7) b7100ae5b1 MDL-69475 backup: Proper handling of backup::RELEASE versions
1) Remove any floatval() casting. They are breaking / killing
   .10 versions (converting them to .1). Since Moodle 2.0 all the
   backup::RELEASE have been 100% numerical values.
2) Use version_compare() always to compare backup::RELEASE values.
   They are always versions and the function is aware of versions
   > .9, able to clean/ignore alpha chars... and everything else.

Note that I've also changed a couple of cases in formats (topics and
weeks) that were correct, but just added the same comment and used
the same version_compare() comparison parameters style, so all uses
in core are consistent (and safe to be copied out there).
2020-08-18 12:48:10 +02:00
Eloy Lafuente (stronk7) 45ce46f202 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 mater, 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-17 00:11:41 +02:00
Martin Drlík ca864e09b1 MDL-68586 format_topics: code prechecks 2020-07-06 13:26:09 +02:00
Jake Dallimore c7d5af7d6e Merge branch 'MDL-69065-master' of git://github.com/peterRd/moodle 2020-06-24 10:11:08 +08:00