-
Improvement
-
Resolution: Fixed
-
Minor
-
3.2.1
-
MOODLE_32_STABLE
-
MOODLE_33_STABLE
-
wip-
MDL-57769-master -
Each section in the course is represented by one record in course_sections table. However formats topics and weeks (and many cloned formats in plugins directory) have 'numsections' parameter that often conflicts with actual number of sections.
This parameter can not be removed since some teachers use it to create "orphaned" activities that are available but not visible on the course page. MDL-4782 will provide necessary functionality for it.
Problems that will be resolved by removing 'numsections' field:
- It is confusing for the majority of teachers. Also many don't understand that "orphaned" activities are actually available
- Controls to add/remove section in the bottom of the page are also not user-friendly (
MDL-34706), in fact why not allow to insert sections anywhere? (MDL-51221). It is already possible to delete any section - It creates problems when importing courses or restoring a course into existing, uploading courses using templates (
MDL-56590,MDL-15659) - the records from course_sections get created, activities are imported but numsections is not changed. This results in confusing orphaned activities in the course
What we need to do:
- create an upgrade script that converts all existing "orphaned" sections in topics and weeks formats into hidden sections with visible activities in them ("stealth" activities)
- remove the course format option 'numsections' from formats weeks and topics and all usages of it
- when restoring course from the backup made before the change respect 'numsections' and convert extra sections into hidden sections with stealth activities
- when making backups include 'numsections' so that these backups can be restored into previous versions of moodle (even though we warn that such restore may not work)
- in existing WS retrieving course contents return the 'numsections' for backward-compatibility that will be calculated on-the-fly as the maximum section number
- make sure that all contributed formats with 'numsections' attribute continue working; provide documentation for developers on how to upgrade their plugins
- leave the "Number of sections" in the create course form and in the default course settings so that new courses are created with the number of empty sections
- caused a regression
-
MDL-59262 Courses made via course request or tool_uploadcourse do not respect default course sections
- Closed
-
MDL-61265 No Sections created in Database Enrolment when not using a Template course
- Closed
- has a non-specific relationship to
-
MDL-57863 Restore test error in behat
- Closed
-
MDL-59481 Ability to create ‘stealth’ topics/sections for advanced course design
- Open
-
MDL-65269 Remove the legacy code for displaying the +/- buttons to add/remove sections to a course
- Open
- has been marked as being related by
-
MDL-58837 Allow to add multiple sections in one step
- Closed
-
MDL-53078 Sections: Deleting sections with AJAX
- Closed
- is blocked by
-
MDL-4782 allow resources/activities to be hidden but available/active
- Closed
- will help resolve
-
MDL-15659 restore to "existing course deleting it first" does not bring in the course settings such as forced theme or # of weeks/modules.
- Closed
-
MDL-48637 Course summary in "Manage courses and categories" has the wrong sections list
- Closed
-
MDL-34706 A request for a new set of "changenumsections" icons
- Closed
-
MDL-51221 Allow sections to be inserted between other sections
- Closed
-
MDL-51367 Set number of course sections to a reasonable value when course content is imported
- Closed
-
MDL-56590 Upload Courses function should be able to handle numsections and other course format options
- Closed