-
Bug
-
Resolution: Duplicate
-
Major
-
None
-
3.9.12, 3.10.9, 3.11.1, 3.11.2, 4.0, 4.1
-
MOODLE_310_STABLE, MOODLE_311_STABLE, MOODLE_39_STABLE, MOODLE_400_STABLE, MOODLE_401_STABLE
-
wip_
MDL-72357_master -
Presumably after upgrade from Moodle 3.10 to 3.11.1 we encounter a problem in several moodle installations (but not all). The links in the activity chooser are always generated with GET parameter id=1, which refers obviously the startpage. By far i tracked it down to the generated javascript in view.php where the activitychooser constructor ist called with id=1 instead of the real courseid.
M.util.js_pending('core_course/activitychooser'); require(['core_course/activitychooser'], function(amd) {amd.init("1", {"tabmode":"0"}); M.util.js_complete('core_course/activitychooser');});; |
Steps to reproduce:
- Login as admin.
- Go to "Site home" page.
- Add "Main menu" block to start page and enable visibility on every page.
- Visit any course page and try to add an activity/material
Result: The activity edit page will come up as child of the start page (verify Breadcrumb nav or see request uri containing id=1. As you'll see, the links in the activitychooser will point to courseid=1 instead of the desired course
Expected result: The activity will be added to the desired course.
Actions taken:
- cache purge by script as well as manual deletion
- different course formats (is topic in affected moodle)
- different themes (is classic in affected moodle - tried boost alternatively)
- Update Moodle 3.11.1 -> 3.11.2+
- Web search for similar problems but no suggested solution helped (Guest user deleted, missing plugin source etc.)
Workaround:
Manually edit the url that is shown in the activity chooser to contain the id of the desired course instead of id=1. Obviously not very user-friendly
- is duplicated by
-
MDL-85652 "Display throughout the entire site" in Main menu block causes activities to be added to Home page
-
- Open
-
-
MDL-72555 All activities are being created in frontpage when "Main menu" block is added to the frontpage
-
- Closed
-
-
MDL-72505 Cannot add course activities if main menu block is added to the entire site
-
- Closed
-
-
MDL-72686 Unable to add activities to a course when the 'Main menu' block is present on the page
-
- Closed
-
-
MDL-73057 Block "Main menu" causes issues when set to "Display throughout the entire site"
-
- Closed
-
-
MDL-73663 Сourse ID is always equals 1 when add elements or resources to the course
-
- Closed
-
-
MDL-73972 All new activities are added to the Main Menu block instead of the course page
-
- Closed
-
- Testing discovered
-
MDL-74107 Site main menu block redundant line
-
- Closed
-