From 6d62a9d7ee84a015cfe463c286cb8d4e5ecd06ab Mon Sep 17 00:00:00 2001 From: skodak Date: Sat, 22 Mar 2008 21:26:31 +0000 Subject: [PATCH] MDL-14008 various SUM aggregation bugfixes; merged from MOODLE_19_STABLE --- grade/edit/tree/item_form.php | 6 +++--- grade/edit/tree/outcomeitem_form.php | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/grade/edit/tree/item_form.php b/grade/edit/tree/item_form.php index 1a65097de4..03da5e7252 100644 --- a/grade/edit/tree/item_form.php +++ b/grade/edit/tree/item_form.php @@ -153,7 +153,7 @@ class edit_item_form extends moodleform { $coefstring = ($coefstring=='' or $coefstring=='aggregationcoefextra') ? 'aggregationcoefextra' : 'aggregationcoef'; } else if ($cat->aggregation == GRADE_AGGREGATE_SUM) { - $coefstring = ($coefstring=='' or $coefstring=='aggregationcoefextrasump') ? 'aggregationcoefextrasum' : 'aggregationcoef'; + $coefstring = ($coefstring=='' or $coefstring=='aggregationcoefextrasum') ? 'aggregationcoefextrasum' : 'aggregationcoef'; } else { $coefstring = 'aggregationcoef'; @@ -174,7 +174,7 @@ class edit_item_form extends moodleform { } else { $mform->addElement('text', 'aggregationcoef', get_string($coefstring, 'grades')); } - $mform->setHelpButton('aggregationcoef', array('aggregationcoef', get_string('aggregationcoef', 'grades'), 'grade'), true); + $mform->setHelpButton('aggregationcoef', array($coefstring, get_string($coefstring, 'grades'), 'grade'), true); } /// hidden params @@ -281,7 +281,7 @@ class edit_item_form extends moodleform { if ($aggcoef !== '') { $agg_el->setLabel(get_string($aggcoef, 'grades')); - $mform->setHelpButton('aggregationcoef', array('aggregationcoef', get_string('aggregationcoef', 'grades'), 'grade'), true); + $mform->setHelpButton('aggregationcoef', array($aggcoef, get_string($aggcoef, 'grades'), 'grade'), true); } } } diff --git a/grade/edit/tree/outcomeitem_form.php b/grade/edit/tree/outcomeitem_form.php index 8c99a5a651..6b0178185e 100644 --- a/grade/edit/tree/outcomeitem_form.php +++ b/grade/edit/tree/outcomeitem_form.php @@ -104,7 +104,7 @@ class edit_outcomeitem_form extends moodleform { $coefstring = ($coefstring=='' or $coefstring=='aggregationcoefextra') ? 'aggregationcoefextra' : 'aggregationcoef'; } else if ($cat->aggregation == GRADE_AGGREGATE_SUM) { - $coefstring = ($coefstring=='' or $coefstring=='aggregationcoefextrasump') ? 'aggregationcoefextrasum' : 'aggregationcoef'; + $coefstring = ($coefstring=='' or $coefstring=='aggregationcoefextrasum') ? 'aggregationcoefextrasum' : 'aggregationcoef'; } else { $coefstring = 'aggregationcoef'; @@ -126,7 +126,7 @@ class edit_outcomeitem_form extends moodleform { } else { $mform->addElement('text', 'aggregationcoef', get_string($coefstring, 'grades')); } - $mform->setHelpButton('aggregationcoef', array('aggregationcoef', get_string('aggregationcoef', 'grades'), 'grade'), true); + $mform->setHelpButton('aggregationcoef', array($coefstring, get_string($coefstring, 'grades'), 'grade'), true); } /// hidden params @@ -208,7 +208,7 @@ class edit_outcomeitem_form extends moodleform { if ($aggcoef !== '') { $agg_el->setLabel(get_string($aggcoef, 'grades')); - $mform->setHelpButton('aggregationcoef', array('aggregationcoef', get_string('aggregationcoef', 'grades'), 'grade')); + $mform->setHelpButton('aggregationcoef', array($aggcoef, get_string($aggcoef, 'grades'), 'grade')); } } } -- 2.39.5