Details
-
Type:
Improvement
-
Status:
Closed
-
Priority:
Minor
-
Resolution: Fixed
-
Affects Version/s: 1.9
-
Fix Version/s: 1.9.1
-
Component/s: Administration, Quiz
-
Labels:None
-
Affected Branches:MOODLE_19_STABLE
-
Fixed Branches:MOODLE_19_STABLE
Description
We want to allow quiz reports to add settings pages to the tree of admin settings pages.
- We think the pages should be sub pages of module / activity / quiz page.
- Unfortunately the current settings.php module hook does not allow us to do more than add fields to one page for a module.
- Don't want to interfere with how api currently works. So we introduce a new hook : settingstree.php and check for that before settings.php
Thoroughly tested :
- Links on module activity page to module settings still work.
- If module is disabled then the sub menu and general settigngs are all made invisible.
I attach :
- a patch to plugins.php to enable the new hook.
- and an example settingstree.php that scans quiz/report/ sub directories for settings.php files to add sub pages to menu for.
- and a screen shot of the menu with a sub menu for quiz report settings pages. The quiz module settings page is 'General Settings' under the main Quiz folder.
Attachments
Issue Links
| This issue duplicates: | ||||
| MDL-14565 | Give modules the ability to add whole trees of settings pages to the admin menu of they want. |
|
|
|
Added Tim, Petr and Martin D here as I want your opinions on whether this seems a sensible way of allowing activities to add more setting pages to the site admin menu.