324 Commits

Author SHA1 Message Date
Jun Pataleta
9095bb0ef9 MDL-78000 upgrade: add the 4.2.0 separation line to all upgrade scripts 2023-04-22 23:17:50 +08:00
Eloy Lafuente (stronk7)
061c9d7ba0 MDL-77940 versions: bump all versions and requires near release
version = 2023042400 release version
requires= 2023041800 current rc1 version
2023-04-18 18:08:09 +02:00
Helen Foster
ee8408c4d5 MDL-77878 lang: Import fixed English strings (en_fix) 2023-04-14 13:08:38 +01:00
Ferran Recio
ae799fad7d MDL-76905 core_courseformat: match prototype visual style 2023-03-22 14:08:51 +01:00
Jun Pataleta
109d902105 Merge branch 'MDL-76894-master' of https://github.com/ferranrecio/moodle 2023-03-20 10:43:04 +08:00
Jun Pataleta
12237e6a8c Merge branch 'MDL-76851-master' of https://github.com/ferranrecio/moodle 2023-03-20 10:39:31 +08:00
Ferran Recio
6ac6100f1c MDL-76894 core_courseformat: bulk move section 2023-03-17 16:18:19 +01:00
Ferran Recio
856b295569 MDL-76851 core_courseformat: plugin custom editor strings
Most section related actions require the frontend to use alternative
strings depending on the format plugin lang file. This patch adds
overridden strings to the current setViewFormat course editor setup
object.
2023-03-17 11:07:13 +01:00
Amaia Anabitarte
1c491de8e8 MDL-76997 admin: Option to reset course indentation 2023-03-16 17:22:02 +01:00
Amaia Anabitarte
6d2c321d7c MDL-76991 tool_mobile: Return course format indentation setting 2023-03-13 11:47:13 +01:00
Amaia Anabitarte
a7c64595c8 MDL-76991 core_course: New course format setting to enable/disable indentation in weeks and topics 2023-03-13 11:47:13 +01:00
Amaia Anabitarte
b37fe9a088 MDL-76990 core_course: Recover move right/left functionality 2023-02-27 18:27:57 +01:00
Angelia Dela Cruz
710607ce5f MDL-75830 behat: Book behat tests optimised
Replace steps that manually add Book instances via the UI and use
Behat generators. This improves the speed of the Behat test runs.
Additionally, performed Behat cleanup and optimisation to affected
files.
2023-02-02 09:08:09 +08:00
Andrew Nicols
a3cc26f8bb MDL-76583 core: Update uses of external_* classes 2023-01-19 07:34:09 +08:00
Jun Pataleta
c6ab792ddf MDL-76497 upgrade: add the 4.1.0 separation line to all upgrade scripts 2022-11-28 14:43:04 +08:00
Jun Pataleta
00bae8b8a4 MDL-76403 versions: bump all versions and requires near release 2022-11-23 09:45:23 +08:00
Eloy Lafuente (stronk7)
58b56e2395 MDL-71747 upgrade: remove all the < 3.9.0 upgrade steps
This just deletes all the upgrade steps previous to 3.9.0. Some
small adjustments, like tweaking globals can also be applied
when needed.

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

The next commits will proceed to deprecate / remove functions
that were exclusively (usually belonging to upgradelib) being
used by those, now removed, upgrade steps. This is the list
of code to remove and document in upgrade.txt files:

  - upgrade_analytics_fix_contextids_defaults()
  - upgrade_convert_hub_config_site_param_names()
  - upgrade_rename_prediction_actions_useful_incorrectly_flagged()
  - \mod_forum\task\refresh_forum_post_counts adhoc task.

And these is the code that has NOT been removed
because it may be needed later (no matter there aren't uses now):

  - \core_search\manager::clean_up_non_existing_area(), used by
  - \core\task\clean_up_deleted_search_area_task adhoc task
2022-07-07 19:16:37 +02:00
Eloy Lafuente (stronk7)
9f53b0e965 MDL-73971 phpunit: Move more tests to use correct names and namespaces
Applied the following changes to various testcase classes:

- Namespaced with component[\level2-API]
- Moved to level2-API subdirectory when required.
- Fixed incorrect use statements with leading backslash.
- Remove file phpdoc block
- Remove MOODLE_INTERNAL if not needed.
- Changed code to point to global scope when needed.
- Fix some relative paths and comments here and there.
- All them passing individually.
- Complete runs passing too.

Special mention to:

- Some fixtures, initially defined in the test files have been
  moved to new files in fixtures subdirectory, leaving the unit
  test files clearer:
  - moodle2_course_format_test.php
- Rename wrong named test:
  - baseoptiogroup_test = baseoptigroup_test
2022-05-06 18:29:11 +02:00
Eloy Lafuente (stronk7)
76f5445451 MDL-74510 upgrade: add the 4.0.0 separation line to all upgrade scripts 2022-04-22 18:45:10 +02:00
Jun Pataleta
70f6b1605b MDL-74471 versions: bump all versions and requires near release 2022-04-13 10:37:36 +08:00
Eloy Lafuente (stronk7)
4003e31983 MDL-73785 phpunit: Move more tests to use correct names and namespaces
Applied the following changes to various testcase classes:

- Namespaced with component[\level2-API]
- Moved to level2-API subdirectory when required.
- Fixed incorrect use statements with leading backslash.
- Remove file phpdoc block
- Remove MOODLE_INTERNAL if not needed.
- Changed code to point to global scope when needed.
- Fix some relative paths and comments here and there.
- All them passing individually.
- Complete runs passing too.

Special mention to:

- When belonging to other components and being valid api:
  - analytics related tests have been moved to tests/analytics subdir.
  - backup & restore related tests have been moved to tests/backup subdir.
  - events related tests have been moved to tests/event subdir.
  - privacy related tests have been moved to tests/privacy.
  - task related tests have been moved to tests/task subdir.
- Some simple renames, not including the component part anymore (not
  needed now that they are namespaced):
  - some xxxlib_test.php have been renamed lib_test.php
    (when they where testing the corresponding lib.php).
  - cache stores tests have been all renamed store_test, originally
    each one had its own name (file_test, apcu_test, redis_test...)
  - assign feedback tests have been all renamed feedback_test, originally
    each one had its own name (file_test, editpdf_test...)
2022-03-03 12:19:30 +01:00
Ferran Recio
479faca428 MDL-73762 core_courseformat: fix coursedisplay dependency
For legacy reasons, the course renderings uses a format setting to know
if the page is multiple sections per page or a single section per page.
This format specific dependency is not solved using a get_course_display
format method any plugin can extend.
2022-02-25 13:35:23 +01:00
Sara Arjona
9096a1e1ac MDL-73859 behat: Fix random error highlighting week
The first week is only highlighted if course starts today or
later. So, the course will be created with startdate on
yesterday to guarantee it always passes.
2022-02-15 17:43:12 +01:00
Ferran Recio
d7df919a2c MDL-73697 core_courseformat: fix weeks format this week badge 2022-02-02 09:25:37 +01:00
Bas Brands
cdb651d46a MDL-71691 core_course: section styling 2021-12-08 13:14:05 +01:00
Ferran Recio
3d2a6eacae MDL-71779 core_courseformat: reactive add and delete sections 2021-10-28 16:41:17 +02:00
Ferran Recio
da0c19982d MDL-72725 courseformat: indentation pot-out 2021-10-18 10:18:37 +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
Andrew Nicols
fa72197258 MDL-72463 courseformat: Add missing docs 2021-10-05 23:20:41 +02:00
Ferran Recio
96c6dc53cd MDL-72463 courseformat: course index highlight section badge 2021-09-29 11:32:03 +02:00
Ferran Recio
7f750dc01c MDL-71228 course: course index drag and drop 2021-09-09 11:16:10 +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
Ferran Recio
21d93554d4 MDL-71863 courseformat: create courseformat subsystem 2021-06-28 13:50:18 +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
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
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
Bas Brands
64de4deced MDL-68301 theme_boost: move course format css
this reduces duplication of css in format_topic
and format_weeks
2020-04-15 09:52:10 +02:00
Sara Arjona
dad7f2ba1d Merge branch 'MDL-65539' of https://github.com/NeillM/moodle 2020-04-06 16:40:52 +02:00
Neill Magill
dc489dffe6 MDL-65539 formats: Section labels not updated during move
Before this change when moving a section via drag and drop the
aria-label for the section was not being updated neither was the
title on the drag handle.

The result was the the drop menu on keyboard drag and drop displayed
the wrong information after a section was moved.
2020-04-03 08:36:36 +01:00
Jake Dallimore
b3f19d3547 MDL-68231 core_formats: conditionally swap controls on section drop
When using section drag and drop, the topics and weeks formats expected
the '.section_add_menus' element to be present so it could update it on
section drop. Due to MDL-68056, this control is only sometimes present.
This has been updated to conditionally swap to address this.
2020-03-24 16:43:51 +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
Sara Arjona
3f224a1a41 MDL-65809 upgrade: remove format_xxx_upgrade_remove_numsections
These functions were used only by deleted upgrade steps
so it's safe to proceed with straight deletion, considering
them internal. Deletion has been documented in corresponding
upgrade.txt files:

    - format_topics_upgrade_remove_numsections()
    - format_topics_upgrade_hide_extra_sections()
    - format_topics_upgrade_add_empty_sections()
    - format_weeks_upgrade_remove_numsections()
    - format_weeks_upgrade_hide_extra_sections()
    - format_weeks_upgrade_add_empty_sections()
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