Moodle release 2.6.2
[moodle.git] / report / upgrade.txt
blob644d13d3d53cd167996fc63a77ec99e92891f935
1 This files describes API changes in /report/* - plugins,
2 information provided here is intended especially for developers.
5 === 2.2 ===
7 API changes:
8 * reports were moved from /admin/report/ to /report/
9 * new support for report settings
12 How to migrate existing admin reports:
13 # move all files to new /report/yourplugin/ location
14 # if settings.php exists add $settings=null;
15 # if settings.php does not exist create it and link the report, index.php is not linked automatically any more
16 # update require('../../config.php'); - remove one ../
17 # update all others includes and requires
18 # update all links to report pages by removing /admin/ or /$CFG->admin/
19 # add language pack with at least 'pluginname' string
20 # update CSS selectors
22 How to migrate existing course reports (optional):
23 # move all files to new /report/yourplugin/ location
24 # update require('../../config.php'); - remove one ../
25 # update all others includes and requires
26 # update all links to report pages by removing /course/ part
27 # update all language strings (use 'report_yourplugin' instead of 'coursereport_yourplugin') - use AMOS hints in commit message
28 # update all capability names
29 # grep the plugin codebase and look for any remaining 'coursereport' occurrences
30 # add new navigation hooks in lib.php - ex: report_stats_extend_navigation_course(), report_stats_extend_navigation_user()
31 # add new page types in lib.php
32 # create db/install.php migration script - delete old settings and capabilities (see converted plugins for examples)
33 # update CSS selectors
35 See http://docs.moodle.org/dev/General_report_plugins for more details and explanation.