Log of /moodle/lib/grade/grade_item.php
Parent Directory
Revision
1.185 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sat Dec 26 07:31:59 2009 WST (2 months, 3 weeks ago) by
mudrd8mz
Branch:
MAIN
Changes since
1.184: +6 -2 lines
Diff to
previous 1.184
MDL-21191 Fixing another regression in dependency calculation
This is not easy to spot as $params may just contain one more item than $sql
would expect. However, $sql and $params should be well paired.
Revision
1.184 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sat Dec 26 01:18:52 2009 WST (2 months, 3 weeks ago) by
mudrd8mz
Branch:
MAIN
Changes since
1.183: +2 -3 lines
Diff to
previous 1.183
MDL-21190 Re-fixing a regression in dependency calculation
Sorry for the last commit. This should be the proper way. The problem
was with the question mark within quotes - it was not considered as a
placeholder.
Revision
1.180 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Sep 17 15:16:51 2009 WST (6 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.179: +8 -1 lines
Diff to
previous 1.179
MDL-19407 Defaulting all grade items to non-extra-credit when moving to a SWM category, except if they originally come from a SWM category and were set as extra credit there. Merged from MOODLE_19_STABLE
Revision
1.170 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri May 16 05:40:07 2008 WST (22 months ago) by
skodak
Branch:
MAIN
Changes since
1.169: +5 -3 lines
Diff to
previous 1.169
MDL-14679 ok, here is the big patch with new dmllib and ddlib API, some code is already converted, XML db editor works; see tracker for details of regressions and TODOs
Revision
1.164 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sat Mar 15 23:54:44 2008 WST (2 years ago) by
skodak
Branch:
MAIN
Changes since
1.163: +12 -3 lines
Diff to
previous 1.163
MDL-13920 assignment without grades now sets text grade type, fixed overriding of feedback and overriding logic in general on grade edit page; merged from MOODLE_19_STABLE
Revision
1.163 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Mar 13 04:45:17 2008 WST (2 years ago) by
skodak
Branch:
MAIN
Changes since
1.162: +31 -21 lines
Diff to
previous 1.162
MDL-13845 rewritten rounding in grades classes again - rounding done also before storage into db so that we can compare the values properly and skip db updates if possible + some more optimisations; merged from MOODLE_19_STABLE
Revision
1.144 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Nov 13 18:08:44 2007 WST (2 years, 4 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.143: +5 -3 lines
Diff to
previous 1.143
Managed to remove static calls from the core gradebook classes without removing support for such calls in gradebook interface code. I used a singleton pattern for this (get_instance in grade_object).
Revision
1.143 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Nov 13 16:36:01 2007 WST (2 years, 4 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.142: +71 -58 lines
Diff to
previous 1.142
Managed to remove static calls from the core gradebook classes without removing support for such calls in gradebook interface code. I used a singleton pattern for this (get_instance in grade_object).
Revision
1.133
Fri Oct 26 10:15:00 2007 WST (2 years, 4 months ago) by
toyomoyo
Branch:
MAIN
Changes since
1.132: +1 -1 lines
FILE REMOVED
bad merge, removing first then adding again
Revision
1.128 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Oct 9 07:09:11 2007 WST (2 years, 5 months ago) by
skodak
Branch:
MAIN
Changes since
1.127: +6 -29 lines
Diff to
previous 1.127
MDL-11578 , MDL-11578 , MDL-11573 :
* renamed Preferences to "My report preferences"
* renamed Site defaults to "Report defaults"
* rename Change site defaults to "Change report defaults"
* reintroduced Inherit option to Grader preferences - Nicolas was right, it is not possible to implement preference overrides without it with our current get_pref inplementation
* new separate option in plugin selector "Course settings"
* moved displaytype, decimals and aggregation position to "Course settings"
* created new table grade_settings + related functions grade_get/set_preference()
* user report now uses grade_seq class instead of grade_item::fetch_all(); added preloading of grade items into grade_grade instances
* other minor bugfixing/cleanup/improvements
Please note that the Grader report preferences and its defaults must be resaved again - sorry.
Revision
1.127 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon Oct 8 02:15:59 2007 WST (2 years, 5 months ago) by
skodak
Branch:
MAIN
Changes since
1.126: +3 -3 lines
Diff to
previous 1.126
MDL-11618 removed the inherit override from decimals and gradetype used on grader report preferences + several bug fixes + settings improvements
Revision
1.118 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sun Sep 23 05:39:28 2007 WST (2 years, 5 months ago) by
skodak
Branch:
MAIN
Changes since
1.117: +2 -5 lines
Diff to
previous 1.117
overridden flag is now used to track the last time of modification - going to use it in assignments to print the correct time/date
Revision
1.116 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sat Sep 22 19:40:10 2007 WST (2 years, 5 months ago) by
skodak
Branch:
MAIN
Changes since
1.115: +74 -40 lines
Diff to
previous 1.115
MDL-11363 merged tables grade_grades with grade_grades_text - it is now possible to define fields as required and optional
finally fixed formula validation in calculation edit form
Revision
1.113 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Sep 19 23:37:47 2007 WST (2 years, 5 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.112: +20 -1 lines
Diff to
previous 1.112
MDL-11353 Completed the implementation. This included a new method in grade_item: get_displaytype(), since that value could be set to default, and we must then look up to course, then site values. And the get_letter() method in grade_grade has been modified to first check the grade_letters table. All works like a dream!
Revision
1.111 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sat Sep 15 01:21:30 2007 WST (2 years, 6 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.110: +14 -4 lines
Diff to
previous 1.110
MDL-11278 Implementation is complete, but grade_categories records in DB are not affected by global settings. This way, when global settings are switched back to "Do not Force", the original category settings will be in place.
Revision
1.109 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sat Sep 1 06:42:08 2007 WST (2 years, 6 months ago) by
skodak
Branch:
MAIN
Changes since
1.108: +49 -58 lines
Diff to
previous 1.108
MDL-11092 events are not used for changed raw grades anymore + minor cleanup in handling of raw grades (now used only for modules or other external plugins that produce grades)
Revision
1.108 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Aug 14 14:05:07 2007 WST (2 years, 7 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.107: +10 -1 lines
Diff to
previous 1.107
MDL-10829 Added get_grade_item() to the grade_item class, for cases when we don't whether an object is a category or a grade_item. The new interface for viewing and adding idnumbers (no editing) is 99% finished. Help strings still to do.
Revision
1.102 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Aug 8 18:27:29 2007 WST (2 years, 7 months ago) by
skodak
Branch:
MAIN
Changes since
1.101: +2 -2 lines
Diff to
previous 1.101
removing $grade_item param from grade_grde methods - not needed anymore, assignment to grade_item property used instead
fixed typo in grade refresh code
Revision
1.96 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Aug 3 16:41:20 2007 WST (2 years, 7 months ago) by
skodak
Branch:
MAIN
Changes since
1.95: +10 -3 lines
Diff to
previous 1.95
improved aggregation - items without value (none + text) are not aggregated; faster regrading of categroies with no grades; lang typo fixed
Revision
1.91 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Aug 1 06:56:31 2007 WST (2 years, 7 months ago) by
skodak
Branch:
MAIN
Changes since
1.90: +3 -3 lines
Diff to
previous 1.90
MDL-10544 basic support for outcomes grading in modules - implemented in assignment popup grading (TODO: fix html and css there)
Revision
1.82 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Jul 19 03:29:33 2007 WST (2 years, 8 months ago) by
skodak
Branch:
MAIN
Changes since
1.81: +3 -2 lines
Diff to
previous 1.81
MDL-9137 added new aggregation needed for upgrade - weighted + extra credit
minor item edit form cleanup
fixed minor bug in grader/lib.php
Revision
1.81 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed Jul 18 22:54:38 2007 WST (2 years, 8 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.80: +3 -4 lines
Diff to
previous 1.80
MDL-10478 Added category preference aggregationview. This one is linked with the more global preferences and $CFG. However, a category-specific preference needs implementing: grade_report_categorystate{$catid}, which equals GRADE_CATEGORY_EXPANDED or GRADE_CATEGORY_CONTRACTED. I've written a stub in grade/report/grader/lib.php around line 492 for pruning out the grade_tree according to these prefs.
We'll also need to implement the actions for the -/+ icons.
Revision
1.77 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Jul 13 06:31:23 2007 WST (2 years, 8 months ago) by
skodak
Branch:
MAIN
Changes since
1.76: +11 -3 lines
Diff to
previous 1.76
major grade editing fixes and improvements - grader form now knows if grade is editable; fixed broken quickgrading; feedback format is handled the same way as in the rest of moodle - automatically converted to FORMAT_HTML when editor enabled; fixed calculation of grades that was breaking locking
Revision
1.76 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Jul 13 03:40:50 2007 WST (2 years, 8 months ago) by
skodak
Branch:
MAIN
Changes since
1.75: +3 -3 lines
Diff to
previous 1.75
MDL-10437 moved editing forms to grade/edit/ directory - these should be shared by all reports, there were too many files in grader directory anyway
Revision
1.72 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Jul 12 00:54:12 2007 WST (2 years, 8 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.71: +2 -1 lines
Diff to
previous 1.71
MDL-9628 Enabling multiple feedback and grades update. Feedbacks now working, but grades don't (at least scales don't)
Revision
1.61 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Jul 3 18:06:10 2007 WST (2 years, 8 months ago) by
skodak
Branch:
MAIN
Changes since
1.60: +1 -29 lines
Diff to
previous 1.60
complete unit tests for grade_category, minor API cleanup, fixed forced regrading in grade_category
Revision
1.59 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sun Jul 1 05:12:50 2007 WST (2 years, 8 months ago) by
skodak
Branch:
MAIN
Changes since
1.58: +77 -62 lines
Diff to
previous 1.58
MDL-9629 fixed regressions in grade reports caused by my previous commits, added unfinished forms for category and item edit
Revision
1.56 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Jun 28 21:20:30 2007 WST (2 years, 8 months ago) by
skodak
Branch:
MAIN
Changes since
1.55: +146 -84 lines
Diff to
previous 1.55
MDL-10224 total course grade implemented + lots of other changes and improvements; there are still some regressions and bugs - going to fix them ASAP; some unit tests still missing too
Revision
1.55 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Jun 26 16:50:22 2007 WST (2 years, 8 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.54: +6 -3 lines
Diff to
previous 1.54
Changed grade_item so that its grademax is count(scale_items) and grademin is 1, to be consistent with use of scales throughout Moodle.
Revision
1.52 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon Jun 25 15:56:25 2007 WST (2 years, 8 months ago) by
skodak
Branch:
MAIN
Changes since
1.51: +33 -5 lines
Diff to
previous 1.51
moving event trigger from update_grade() to grade_item->update_raw_grade(); removing itemnumber generation for now
Revision
1.51 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon Jun 25 06:26:34 2007 WST (2 years, 8 months ago) by
skodak
Branch:
MAIN
Changes since
1.50: +44 -49 lines
Diff to
previous 1.50
MDL-10233 improved static factory methods of grade obejcts fetch() and fetch_all(); implemented default values of grade objects, fixed null values for some properties that are not required - unit tests included, tested with PHP4 and PHP5
Revision
1.50 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Sun Jun 24 00:33:17 2007 WST (2 years, 8 months ago) by
skodak
Branch:
MAIN
Changes since
1.49: +228 -68 lines
Diff to
previous 1.49
MDL-10231 merge grade_calculations and grade_items table + calculation improvements
MDL-10233 fixed grade_*::fetch() - does not modify $this anymore, we can now use it from normal methods to fetch other objects of the same class.
Revision
1.48 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Jun 22 16:57:41 2007 WST (2 years, 8 months ago) by
skodak
Branch:
MAIN
Changes since
1.47: +204 -100 lines
Diff to
previous 1.47
MDL-10223 Implement locking of grades and grade items - cron support still not implemented;
this patch also contains improvements in handling of needsupdate, though it is not yet fully working for calculated grades
Revision
1.44 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon Jun 18 21:43:41 2007 WST (2 years, 9 months ago) by
skodak
Branch:
MAIN
Changes since
1.43: +299 -313 lines
Diff to
previous 1.43
MDL-9137 various grading improvements
1/ initial support for migration of old grade_items and categories (not tested)
2/ rewritten grade update and calculation logic
3/ initial support for calculation formulas
4/ minor API refactoring and cleanup
5/ various small bugfixes
6/ fixed use of grademax with scales
7/ fixed some unit tests
TODO:
* implement proper locking of grades - needs discussion
* force recalculation of all formulas after adding/removing/changing of grade items
* better delete flag support
* support for NULLs n backup - Eloy already proposed a solution
* support for NULLs in set_field()
* speedup
* more unit tests nd functional tests
Revision
1.43 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu Jun 7 20:45:24 2007 WST (2 years, 9 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.42: +39 -8 lines
Diff to
previous 1.42
grade_item idnumber now self generated if needed.
deleted flag implemented in grade_item::update method
added GRADE_TYPE_NONE to gradelib and updated grade_item object
Implemented multiple items (generation of itemnumber when not explicitly given)
Revision
1.40 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue Jun 5 16:50:28 2007 WST (2 years, 9 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.39: +10 -1 lines
Diff to
previous 1.39
MDL-9629 Changed grade_item.gradetype default to 1, added GRADE_TYPE_NONE constant = 0, incrementing existing constants by 1. Set up auto-generation of idnumber for grade_item if itemmodule and iteminstance are set, only a temporary stub if they are not set (must be replaced by correct generation code). New category form now has server-side validation (not using formslib)
Revision
1.39 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Jun 1 12:46:25 2007 WST (2 years, 9 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.38: +7 -1 lines
Diff to
previous 1.38
MDL-9137 Removed hidden field from grade_categories and added deleted field to grade_items. Also added 2 images in pix/i
Revision
1.38 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri Jun 1 12:02:38 2007 WST (2 years, 9 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.37: +39 -1 lines
Diff to
previous 1.37
MDL-9629 Category edit page now implements delete, show/hide, lock/unlock, moveup/movedown and move actions. The edit icon is also shown but not yet implemented.
Revision
1.36 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu May 31 11:15:43 2007 WST (2 years, 9 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.35: +268 -241 lines
Diff to
previous 1.35
MDL-9506 MDL-9137 MDL-9629
Added a number of small getters and setters to grade_item and grade_category, to hide the structural differences between the two, and provide a common interface for cases when we are not sure whether an $object is of one type or another.
The grade_tree::renumber() method now adds complete objects to the need_update array, because both grade_category and grade_item need to update their parent field when moved to a different parent. Amazingly, these important changes worked straight away (after 1 hour of coding without testing anything), and all the unit tests passed!
Revision
1.35 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon May 28 16:00:20 2007 WST (2 years, 9 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.34: +17 -1 lines
Diff to
previous 1.34
MDL-9506 Category and Item now set their own courseid if not set explicitly, and if they have enough information from
other sources. category::set_as_parent has a new constraint: cannot set over children from different courses.
Applied recursion to grade_tree::renumber(), but still some fine-tuning to do, since only grade_items are getting updated in DB.
Revision
1.32 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu May 24 16:50:04 2007 WST (2 years, 9 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.31: +21 -2 lines
Diff to
previous 1.31
MDL-9629 Beginning the edit category page. Also added dmllib::sql_max($field) and fixed a few bugs. Grade_item should now extrapolate its sortorder upon insertion if not set, by looking up the last sortorder in the table, and incrementing by 1.
Revision
1.31 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu May 24 11:32:23 2007 WST (2 years, 9 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.30: +20 -1 lines
Diff to
previous 1.30
MDL-9506 Added grademax extrapolation from scale info for grade_item, in insert() and update() methods. Corrected a few other minor bugs.
Revision
1.29 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon May 21 13:54:12 2007 WST (2 years, 9 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.28: +2 -3 lines
Diff to
previous 1.28
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.
Revision
1.28 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri May 18 16:05:53 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.27: +11 -1 lines
Diff to
previous 1.27
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.
Revision
1.27 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu May 17 17:04:52 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.26: +26 -2 lines
Diff to
previous 1.26
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 :-)
Revision
1.26 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon May 14 16:18:03 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.25: +7 -1 lines
Diff to
previous 1.25
MDL-9506 Added some unit tests, found some errors, and realised they came from incorrect setup unit test data, which I corrected (grade finals for item 3 were set to 2-digit ints although item 3 was a scale of 1-7.
Revision
1.25 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon May 14 12:14:23 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.24: +7 -7 lines
Diff to
previous 1.24
MDL-9506 Finally cracked the category aggregation. However, more thorough unit tests need to be written, with exact expectations instead of ranges, as currently used. All unit tests pass.
Revision
1.24 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri May 11 16:46:35 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.23: +65 -3 lines
Diff to
previous 1.23
MDL-9506 Almost completed category aggregation, including generation of raw and final grades held by these categories. Only a few small glitches remain, that cause these grades not to be generated properly. This is the last critical element of the gradebook API, so I'm looking forward to finishing it :-)
Revision
1.23 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Fri May 11 11:29:01 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.22: +2 -2 lines
Diff to
previous 1.22
MDL-9506 Finished implementing the propagation of needsupdate flag up the hierarchy when a lower element justifies it. All unit tests pass. The next task is to implement the generation of raw grades and final grades based on this needsupdate setting.
Revision
1.20 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu May 10 16:08:44 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.19: +142 -57 lines
Diff to
previous 1.19
MDL-9506
grade_grades_raw
added grade_item object
added load_grade_item()
added call to grade_item->flag_for_update() when object is inserted, deleted or updated
grade_grades_final
added grade_item object
added load_grade_item()
grade_grades_text
added grade_item object
added load_grade_item()
grade_item
added qualifies_for_update()
added call to grade_category->flag_for_update() when object is inserted, deleted or updated (only when qualifies_for_update() is true)
However since I have made this last set of changes, the unit tests are performing extremely slow, and several of them fail. I suspect that there is a serious performance issue involved in using objects too heavily, instead of performing more SQL queries, especially when updates are concerned. Often a complete object is SELECTed before it is amended in an object form then UPDATEd.
In the next iteration I will look at this seriously, and put together some tests with thousands of users and many grade_items, to see how well the API responds.
Revision
1.19 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu May 10 10:34:01 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Branch point for:
MOODLE_19_QUESTIONS
Changes since
1.18: +40 -8 lines
Diff to
previous 1.18
MDL-9506
grade_category:
new parent_category object
new load_parent_category() method
new flag_for_update() recursive method
grade_item:
new category object
changed get_category() to load_category() and updated testgradeitem
added missing idnumber field
new flag_for_update() recursive method
Revision
1.18 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed May 9 15:50:29 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.17: +13 -23 lines
Diff to
previous 1.17
MDL-9506 Unit test tables are now created and emptied using XMLDB. raw.gradescale and final.gradescale have been removed in favour of a single gradevalue. Scale value is no longer rounded until moment of display. A number of other changes which you can look at by browsing the diff :-)
Revision
1.17 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue May 8 16:01:56 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.16: +23 -25 lines
Diff to
previous 1.16
MDL-9506 Stuck on grade_category->generate_grades. I cannot figure out how to recursively generate raw grades for each category's associated grade_item based on that category's children categories and items. Heaps of other changes with this commit, including a new grade_object::update_from_db() method, which uses the state of the record in DB to update the current object with a matching id (useful when you insert an incomplete object in the DB and want to get the default values as set up in the DB).
Revision
1.16 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue May 8 10:20:26 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.15: +66 -12 lines
Diff to
previous 1.15
MDL-9506 Issue 1: adjusting a gradeitem's value would result in a grade_final object with gradevalue assigned, even when a gradescale should have been assigned. Issue 2: double grade_final entries when calling grade_item->load_final() after grade_item->generate_final(). Issue 3: Calling grade_item->update_final_grade() without first calling grade_item->generate_final() would result in fatal error. generate_final() is now called if the raw and final arrays' sizes don't match.
Revision
1.15 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon May 7 10:04:06 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.14: +10 -5 lines
Diff to
previous 1.14
MDL-9506 Removed implicit loading of associated objects from constructors (grade_item and grade_grades_raw) to avoid very large numbers of sql queries when only little data is required. The load_scale() method, for example, needs to be called explicitly.
Revision
1.11 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Thu May 3 15:10:23 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.10: +11 -17 lines
Diff to
previous 1.10
MDL-9506 Upgraded grade_item::adjust_grade with Darlene's more elegant formula. Completed grade_category::get_children($depth, $arraytype). Added 4 constants to help that method. Added and passed all unit tests (111 now).
Revision
1.10 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Wed May 2 15:20:13 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.9: +8 -9 lines
Diff to
previous 1.9
MDL-9506 Finished all unit test stubs, another batch to write soon. One one test fails because I haven't implemented recursive category hierarchy output yet, and not sure if it's needed. A grade_category already returns its immediate children, and that may be enough.
Revision
1.9 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue May 1 13:45:54 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.8: +51 -17 lines
Diff to
previous 1.8
MDL-9506 Finished grade_item::adjust_grade, which now also adjusts scale grades correctly. Added grade_scale object to wrap around the current non-normalized scale DB table. When/if we upgrade to grade_scales and grade_scale_items DB tables, changing the grade_scale class will be easy.
Revision
1.8 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Tue May 1 11:18:55 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.7: +14 -11 lines
Diff to
previous 1.7
MDL-9506 Implemented rescaling and grade adjustment formulas in grade_item::adjust_grade(). Also wrote unit tests.
Revision
1.7 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon Apr 30 17:09:32 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.6: +89 -10 lines
Diff to
previous 1.6
MDL-9506 Lots more unit tests, and work on grade_item::update method and associated functionality. 3 unit tests currently fail, so more work needed.
Revision
1.6 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon Apr 30 13:25:19 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.5: +26 -9 lines
Diff to
previous 1.5
MLD-9506 Corrected update_final_grades() in grade_item, which was updating the grade_raw table
instead of grade_final. Made a few other adjustments.
Revision
1.4 -
(
view)
(
download)
(
annotate)
-
[select for diffs]
Mon Apr 30 12:49:25 2007 WST (2 years, 10 months ago) by
nicolasconnault
Branch:
MAIN
Changes since
1.3: +62 -8 lines
Diff to
previous 1.3
MDL-9506 Added grade_grades_raw as a proper object used by grade_item. Also added a global function in gradelib for updating grade_grades_raw objects.
This form allows you to request diffs between any two revisions of this file.
For each of the two "sides" of the diff,
select a symbolic revision name using the selection box, or choose
'Use Text Field' and enter a numeric revision.