MDL-48347 gradebook: Single view shows all grade items.

Manual grade items, course totals, and categroy totals
were not being displayed in the single view.
This commit is contained in:
Adrian Greeve 2014-12-05 15:54:17 +08:00
parent 2d84748c26
commit 37f308629a

View File

@ -48,7 +48,8 @@ class finalgrade extends grade_attribute_format implements unique_value, be_disa
$this->label = $this->grade->grade_item->itemname;
$isoverridden = $this->grade->is_overridden();
if (!empty($isoverridden)) {
// If the grade is overridden or the grade type is not an activity then use finalgrade.
if (!empty($isoverridden) || $this->grade->grade_item->itemtype != 'mod') {
$val = $this->grade->finalgrade;
} else {
$val = $this->grade->rawgrade;