Commit graph

7208 commits

Author SHA1 Message Date
Sara Arjona
2b3ff1633f Merge branch 'MDL-82360' of https://github.com/paulholden/moodle 2024-07-10 09:17:59 +08:00
Sara Arjona
41b8cd3f73 Merge branch 'MDL-78388' of https://github.com/djarran/moodle 2024-07-10 09:16:57 +08:00
Paul Holden
1554c68933
MDL-82391 courseformat: correct selector element section URLs.
It's required by themes that don't use the course index component,
e.g. Classic theme.
2024-07-09 14:45:16 +01:00
ferranrecio
5ca968fea4 MDL-82324 course: fix empty section dropzone 2024-07-09 11:23:46 +02:00
ferranrecio
0766976b61 MDL-81798 course: limit number of subsections 2024-07-09 10:49:42 +02:00
ferranrecio
0ccafe76f6 MDL-81765 mod_subsection: disable mod subsection by default 2024-07-08 13:34:28 +02:00
ferranrecio
c7742b7a23 MDL-81765 course: fix double highlighted in subsections 2024-07-05 13:04:49 +02:00
ferranrecio
c13d579b5e MDL-81765 course: module delegated section logic
Having mod_subsection into core was a pre-requisite to incorporate some
phpunit and behat tests that are pending from previous issues. Also,
some new sectiondelegatemodule methods are added tu support the new
plugin.
2024-07-05 08:29:21 +02:00
Ilya Tregubov
d6d6f8466c Merge branch 'MDL-82024' of https://github.com/paulholden/moodle 2024-07-04 09:50:22 +08:00
Sara Arjona
89dcf5066b
Merge branch 'MDL-74251-main' of https://github.com/lucaboesch/moodle 2024-07-03 09:35:56 +02:00
Shamim Rezaie
1511c71a18 Merge branch 'MDL-81725-main' of https://github.com/laurentdavid/moodle 2024-07-03 13:45:45 +10:00
djarrancotleanu
38a6f3fcaf MDL-78388 course: Copy permissions when duplicating module 2024-07-03 13:39:00 +10:00
Shamim Rezaie
b174c16d4d Merge branch 'MDL-82329' of https://github.com/paulholden/moodle 2024-07-03 04:06:19 +10:00
Paul Holden
314fcb3cf8
MDL-82360 courseformat: remove console upload error string debugging. 2024-07-02 15:53:19 +01:00
Laurent David
39ccad14d1 MDL-81725 core_courseformat: Fix refreshCompletion on subsections
* If completion information on subsection is not present the
refreshCompletion action is raising an exception
2024-07-02 16:17:19 +02:00
Laurent David
e8c66a9815 MDL-81725 core_courseformat: Prevent drag and drop handling subsections
* Subsection are "modules" and should not be handled as "sections" in the
drag and drop process. Preventing delegated section from being dragged in
the dndsectionitems module fixes the drag and drop issues with subsections
in course index.
2024-07-02 16:17:19 +02:00
Laurent David
cdc3ec5a54 MDL-81725 core_courseformat: Display subsections in the course index
* Add subsection into section entry in course index
* Adjust padding
2024-07-02 11:58:45 +02:00
Sara Arjona
4fcea1f716
Merge branch 'MDL-80191-main-v06' of https://github.com/ferranrecio/moodle 2024-07-01 12:26:46 +02:00
Sara Arjona
576e63cb0f
Merge branch 'MDL-63753' of https://github.com/larsbonczek/moodle 2024-07-01 12:18:50 +02:00
Paul Holden
c03234b5a6
MDL-82329 course: consistent section permalink on view/section pages. 2024-06-28 08:59:51 +01:00
Adrian Perez
e1353c7649 MDL-74251 core: Remove old icon helper classes 2024-06-27 18:28:05 +02:00
ferranrecio
b4f0332388 MDL-80191 backup: delegate section backup and restore
This commit adds all the logic to allow delegate sections backup and
restore. The backup and restore process is quite complex and it is not
designed to have task hierarchy. To solve the subsection problem, the
backup/restore planners do not include delegated sections at a course
level, but they are included when the activity with delegated section is
processed.

To allow restoing, the activity is responsible to store the
component/itemid mapping in the backup_structure_dbops. This way, when
the delegated section is restored (delegated sections are always
processed right after the parent activity) it can use the itemid
mapping.
2024-06-27 10:21:07 +02:00
Lars Bonczek
a48d11dd7d MDL-63753 course: Show stealth activity links to non-editing teachers 2024-06-26 12:57:36 +02:00
Sara Arjona
9e1eec783c
Merge branch 'MDL-82207' of https://github.com/stronk7/moodle 2024-06-26 12:27:19 +02:00
Ilya Tregubov
435619ac90 Merge branch 'MDL-81866-main' of https://github.com/sarjona/moodle 2024-06-26 10:16:36 +08:00
Sara Arjona
cf7cc40f4b
MDL-81866 course: Fix behat errors after improving reset 2024-06-25 12:59:26 +02:00
Sara Arjona
7402706c59
MDL-81866 course: Improve workflow for reset course
The following changes have been done to improve the reset course:
- Reset course button moved to sticky footer. Select default and
deselect all buttons set as secondary and left at the end of the form
- Adjusted page layout to a standardized format, centering the form for
improving presentation and recolocating the Reset course button away
from the bottom-right corner
- Changed page layout to standard, to display the form centered and
avoid having the Reset course button in the right bottom corner
- Modal added before resetting a course, asking user for confirmation
- Reset course buttons displayed with danger styling, because they
remove information
- All sections are expanded by default
- Default options are selected by default
2024-06-25 12:59:25 +02:00
Paul Holden
e8ae5222d6
MDL-82024 format_topics: toggle un/highlight section icon correctly. 2024-06-24 19:40:22 +01:00
Eloy Lafuente (stronk7)
ad5fe71868
MDL-82207 phpunit: fix various @covers annotations (take#1)
This fixes various (not all) wrong @covers annotations that
are reported as warnings by PHPUnit when it's run with
code-coverage enabled.

When possible, the preferred solution is to change to
@covers at class level, that is the recommended way.

If multiple classes are involved, then a mix of @coversDefaultClass
and @covers at method level are used (always trying to use the
minimum needed patch).

This is the first of a series of issues created as sub-tasks
of MDL-82142.
2024-06-24 12:07:39 +02:00
ferranrecio
f166b15b28 MDL-81769 core_courseformat: prevent delegated section modules actions 2024-06-21 12:41:09 +02:00
Huong Nguyen
c53b23e47e
Merge branch 'MDL-82202' of https://github.com/paulholden/moodle 2024-06-20 10:20:48 +07:00
Sara Arjona
72f0d10e11
Merge branch 'MDL-80745-main' of https://github.com/rezaies/moodle 2024-06-19 08:48:40 +02:00
Huong Nguyen
ebae7fbae4
Merge branch 'MDL-81523' of https://github.com/stronk7/moodle 2024-06-19 09:52:10 +07:00
Shamim Rezaie
37eae68cdb MDL-80745 core_course: group selector renderer for actionbar in course 2024-06-19 00:41:05 +10:00
Paul Holden
7ab967202c
MDL-82202 course: correct last access report entity column callback.
Ensure it works when being aggregated.
2024-06-17 14:27:01 +01:00
James C
7dca6d0e3b MDL-78080 course: Duplicate section: Duplicate by section id, not num 2024-06-17 12:51:33 +12:00
James C
7cde0e9984 MDL-78080 course: Duplicate section: No duplicate option for section 0 2024-06-17 12:51:33 +12:00
James C
f00a6caaaf MDL-78080 course: Duplicate section: Don't copy deleted activities 2024-06-17 12:51:33 +12:00
James C
ef02908013 MDL-78080 course: Duplicate section: Copy section summary files 2024-06-17 12:51:13 +12:00
James C
23567ce725 MDL-78080 course: Duplicate section: Copy custom section options 2024-06-17 12:48:22 +12:00
James C
acf5e44fde MDL-78080 course: Duplicate section: Fix course_update_section params 2024-06-17 12:47:16 +12:00
Eloy Lafuente (stronk7)
674497a12c
MDL-81523 phpunit: Add all missing setUp/tearDown parent calls
All setUp(), tearDown(), setUpBeforeClass() and tearDownAfterClass()
must, always, call to parent, to ensure that everything is properly
set and cleaned.

While in a lot of situations this is not needed (parents may not
have anything to run), with PHPUnit >= 10 this can become more
important because we are going to move the reset code from current
placement @ runBare() to setUp()/tearDown().

Note that all the changes performed in this commit have been detected
and fixed by moodle-cs (ParentSetUpTearDownSniffTest).
2024-06-14 16:04:57 +02:00
Ilya Tregubov
788f0e6f0a NOBUG: Add upgrade notes 2024-06-14 08:56:53 +08:00
Huong Nguyen
5970d38755
Merge branch 'MDL-81332-main' of https://github.com/andelacruz/moodle 2024-06-12 13:15:05 +07:00
Jun Pataleta
bb1cddb140
Merge branch 'MDL-81681-main' of https://github.com/sarjona/moodle 2024-06-12 10:57:20 +08:00
Huong Nguyen
96d29ef71b
Merge branch 'MDL-81522' of https://github.com/stronk7/moodle 2024-06-12 08:46:31 +07:00
Laurent David
9381343c78 MDL-81510 core_courseformat: Fix activity highlight in index
* When directly accessing the module with the #module-xxx anchor
we should highlight the module as the current page item.
2024-06-11 12:34:20 +02:00
Eloy Lafuente (stronk7)
4f7631113c
MDL-81522 phpunit: Add missing void return type to all tests #2
This commit includes more changes, all them also adding the :void
return type to unit tests missing them.

The difference is that all these changes, while also detected
perfectly by the moodle.PHPUnit.TestReturnType sniff, were not
auto-fixed (like the previous commit ones), because all them
do include some "return" statement and, for safety, we don't
fix them.

All the cases have been visually inspected and confirmed that
the existing "return" statements always belong to anon
functions within the test body and not the test own return statement.
2024-06-11 11:55:08 +02:00
Eloy Lafuente (stronk7)
01148a0816
MDL-81522 phpunit: Add missing void return type to all tests
While this change is not 100% required now, it's good habit
and we are checking for it since Moodle 4.4.

All the changes in this commit have been applied automatically
using the moodle.PHPUnit.TestReturnType sniff and are, exclusively
adding the ": void" return types when missing.
2024-06-11 11:55:07 +02:00
Angelia Dela Cruz
ff8d888c49 MDL-81332 core_course: Behat test for grade and activity reports display 2024-06-11 15:25:21 +08:00