nicolasconnault [Tue, 22 May 2007 09:03:33 +0000 (09:03 +0000)]
MDL-9506 Changed grade_tree fullobjects param (not fully implemented) to $include_grades param, default to false, fully implemented. Full objects are always loaded when building the tree, but grades are only loaded conditionally.
skodak [Mon, 21 May 2007 20:33:42 +0000 (20:33 +0000)]
MDL-9880 Remove user_activate() method from public API because it was used only from user_confirm() in LDAP, other plugins use only user_confirm()
MDL-9575 fix email signup in ldap auth mod
skodak [Mon, 21 May 2007 20:08:45 +0000 (20:08 +0000)]
MDL-9861 Password expiration value is calculated wrong when ldap_expirationtime2unix() returns 0 - patch by Iñaki Arenaza; merged from MOODLE_18_STABLE
nicolasconnault [Mon, 21 May 2007 08:56:44 +0000 (08:56 +0000)]
MDL-9506 Extracted the code that applies droplow and keephigh rules to aggregated values, into its own little method. Unit testing this method revealed a coding error which I have rectified.
nicolasconnault [Mon, 21 May 2007 05:54:12 +0000 (05:54 +0000)]
MDL-9506 Removed the debugging message for the fetch() methods. Added droplow and keephigh rules to grade_category::aggregate_grades(). The only question now is what to do when the droplow or keephigh field is larger than the number of grades for a given user/item combination. At the moment it just gives that value 0.
jamiesensei [Sun, 20 May 2007 16:17:48 +0000 (16:17 +0000)]
UI for editing questions changed to support sharing questions in multiple contexts. Also changed import / export and category editing form to use formslib.
jamiesensei [Sun, 20 May 2007 13:59:58 +0000 (13:59 +0000)]
some changes to listlib to make it possible to chain the paging of several lists together that are displayed on the same page, so that paging can work across several lists
nicolasconnault [Fri, 18 May 2007 08:05:53 +0000 (08:05 +0000)]
MDL-9506 New grade_category::set_as_parent($children) method (non-static). Crucial method for adding categories over children. 4 constraints have been set up, and successfully tested in unit tests. However, the method fails when it comes to updating the children's parent fields. The test data may be missing some required fields.
nicolasconnault [Fri, 18 May 2007 05:34:30 +0000 (05:34 +0000)]
MDL-9506 Fixed up the grade_tree and its unit tests. The main change to notice is in grade_category, where the array returned by get_children() is indexed by sortorder. The associated unit tests have been updated to reflect this important change.
skodak [Thu, 17 May 2007 15:44:07 +0000 (15:44 +0000)]
MDL-9843 get_cached_events does not handle components properly;
whitespace cleanup;
minor coding style changes - such as always returning arrays from get cached and file events;
marked some functions as eventslib internal only
nicolasconnault [Thu, 17 May 2007 09:04:52 +0000 (09:04 +0000)]
MDL-9506 Elements of the array returned by grade_category::get_children are now indexed by sortorder, to work more easily with grade_tree methods.
New get_sortorder method for grade_category and grade_item. This is used when the type of an object is unknown, and could be either one. Because categories have a "virtual" sortorder (through their grade_item), they can transparently return one as well.
Unit tests fail for grade_tree at present because of faulty implementation which is being fixed. The $depth attribute has been completely removed, as well as a number of switch statements, in favour of an $index variable which is exploded and used to build strings of array keys for eval statements (unset and array_splice). Can't wait to get all this working :-)
nicolasconnault [Thu, 17 May 2007 04:13:42 +0000 (04:13 +0000)]
MDL-9506 Successfully implemented the grade_tree methods for moving an element somewhere else in the tree. Tests pass successfully. However the test data doesn't yet include more than 1 top-category, so I can't test moving it. Direct insertion and deletion have not yet been tested, although insertion is used by the move_element method.
nicolasconnault [Wed, 16 May 2007 03:17:46 +0000 (03:17 +0000)]
MDL-9506 Reorganised unit tests a bit, added some stubs and tests for grade_category, and corrected missing grade_finals for orphan grade_items and categories.
nicolasconnault [Wed, 16 May 2007 02:47:56 +0000 (02:47 +0000)]
MDL-9506 grade_category::display_grades() and grade_category::get_tree() correctly built the headers for a HTML table of grades, with two layers of categories and one layer of grade_items. Empty filler cells are used when a 1st or 2nd level category doesn't exist for a grade_item.