At the Open University we've created / had created many custom Moodle modules and plugins, some large and complex. (Several of these - OU wiki, OU blog, ForumNG) are available to the public, so you can see and use them if you want to.)
Upgrading all these to 2.0 is a bit of a scary thought.
I - and I'm sure others - would appreciate input from anyone who has already converted a custom module to work properly with 2.0. It's early days given that 2.0 is not even in beta, so I hardly expect many people have. However, people can always add to this discussion later.
I'd like to know (a) about timescale [converting a simple module took X hours/days/whatever, converting a more complex one took Y] and (b) about difficulty - i.e. does it work almost 'by rote' so that we could get less experienced developers to do it by following a wiki page - there doesn't seem to be a single one yet, or I couldn't find it, but I guess there will be - or did it require many complicated decisions about new approaches, or something in the middle.
The reason for this is so that I can give my employer some idea of how difficult we're expecting the conversion to be. At present, I'd say my expectation is that module changes will be significant but not too bad, while dealing with our changes to core (deciding some are no longer necessary, re-implementing others) is probably more serious.
--sam
I'll try and remember what I did... This happened over a long period of time. Going back through commits, here are the major changes...
Change |
Description |
Difficulty |
Comment |
Documentation |
Database refactoring | changing all database calls to new database API | significant | Requires restructuring of database functions to use new array structure for arguments. |
Moodle Docs |
Output refactoring | changing all output functions to use combination of $PAGE and $OUTPUT class functions | very significant | This one took me a long time, because I did it once quite a while ago, and then the API changed again. You may need to re-check what old code did in old API's to successfully convert new code. |
Moodle Docs |
Forms changes |
change htmleditor element to editor element. May need to change to use new "intro" element. |
medium |
Need to look at old code and refactor for options. |
?? |
there is already a little checklist, see http://cvs.moodle.org/moodle/mod/upgrade.txt?revision=1.12&view=markup
petr
petr
Thanks Mike, Petr. Really helpful!