From 4d910cad014480374e4562857ffb5c469d8e29a5 Mon Sep 17 00:00:00 2001 From: nicolasconnault Date: Wed, 8 Aug 2007 06:12:55 +0000 Subject: [PATCH] MDL-10724 Finished help strings for grade and outcome item edit forms --- grade/edit/tree/grade_form.php | 20 +++++++++++++++++--- grade/edit/tree/outcomeitem_form.php | 12 ++++++++++++ lang/en_utf8/grades.php | 6 ++++++ lang/en_utf8/help/grade/hidden.html | 2 +- lang/en_utf8/help/grade/hiddenuntil.html | 2 +- .../help/grade/{hiddenuntil.html => locked.html} | 4 ++-- lang/en_utf8/help/grade/lockeduntil.html | 2 +- 7 files changed, 40 insertions(+), 8 deletions(-) copy lang/en_utf8/help/grade/{hiddenuntil.html => locked.html} (75%) diff --git a/grade/edit/tree/grade_form.php b/grade/edit/tree/grade_form.php index 1e2894ac4..40c679517 100755 --- a/grade/edit/tree/grade_form.php +++ b/grade/edit/tree/grade_form.php @@ -20,15 +20,17 @@ class edit_grade_form extends moodleform { if ($grade_item->gradetype == GRADE_TYPE_VALUE) { // numeric grade $mform->addElement('text', 'finalgrade', get_string('finalgrade', 'grades')); + $mform->setHelpButton('finalgrade', array(false, get_string('finalgrade', 'grades'), + false, true, false, get_string('finalgradehelp', 'grades'))); } else if ($grade_item->gradetype == GRADE_TYPE_SCALE) { // scale grade $scaleopt = array(); if (empty($grade_item->outcomeid)) { - $scaleopt[-1] = get_string('nograde'); + $scaleopt[-1] = get_string('nograde'); } else { - $scaleopt[-1] = get_string('nooutcome', 'grades'); + $scaleopt[-1] = get_string('nooutcome', 'grades'); } $i = 1; @@ -40,25 +42,37 @@ class edit_grade_form extends moodleform { } $mform->addElement('select', 'finalgrade', get_string('finalgrade', 'grades'), $scaleopt); + $mform->setHelpButton('finalgrade', array(false, get_string('finalgrade', 'grades'), + false, true, false, get_string('finalgradehelp', 'grades'))); } $mform->addElement('advcheckbox', 'overridden', get_string('overridden', 'grades')); + $mform->setHelpButton('overridden', array(false, get_string('overridden', 'grades'), + false, true, false, get_string('overriddenhelp', 'grades'))); $mform->addElement('advcheckbox', 'excluded', get_string('excluded', 'grades')); + $mform->setHelpButton('excluded', array(false, get_string('excluded', 'grades'), + false, true, false, get_string('excludedhelp', 'grades'))); /// hiding /// advcheckbox is not compatible with disabledIf !! $mform->addElement('checkbox', 'hidden', get_string('hidden', 'grades')); + $mform->setHelpButton('hidden', array('hidden', get_string('hidden', 'grades'), 'grade')); $mform->addElement('date_time_selector', 'hiddenuntil', get_string('hiddenuntil', 'grades'), array('optional'=>true)); + $mform->setHelpButton('hiddenuntil', array('hiddenuntil', get_string('hiddenuntil', 'grades'), 'grade')); $mform->disabledIf('hiddenuntil', 'hidden', 'checked'); /// locking $mform->addElement('advcheckbox', 'locked', get_string('locked', 'grades')); + $mform->setHelpButton('locked', array('locked', get_string('locked', 'grades'), 'grade')); $mform->addElement('date_time_selector', 'locktime', get_string('locktime', 'grades'), array('optional'=>true)); + $mform->setHelpButton('locktime', array('locktime', get_string('locktime', 'grades'), 'grade')); $mform->disabledIf('locktime', 'gradetype', 'eq', GRADE_TYPE_NONE); // Feedback format is automatically converted to html if user has enabled editor $mform->addElement('htmleditor', 'feedback', get_string('feedback', 'grades'), array('rows'=>'15', 'course'=>$COURSE->id, 'cols'=>'45')); + $mform->setHelpButton('feedback', array(false, get_string('feedback', 'grades'), + false, true, false, get_string('feedbackhelp', 'grades'))); $mform->setType('text', PARAM_RAW); // to be cleaned before display, no XSS risk $mform->addElement('format', 'feedbackformat', get_string('format')); $mform->setHelpButton('feedbackformat', array('textformat', get_string('helpformatting'))); @@ -139,4 +153,4 @@ class edit_grade_form extends moodleform { } } -?> \ No newline at end of file +?> diff --git a/grade/edit/tree/outcomeitem_form.php b/grade/edit/tree/outcomeitem_form.php index a5d575fba..2d63253a0 100644 --- a/grade/edit/tree/outcomeitem_form.php +++ b/grade/edit/tree/outcomeitem_form.php @@ -15,8 +15,12 @@ class edit_outcomeitem_form extends moodleform { $mform->addRule('itemname', get_string('required'), 'required', null, 'client'); $mform->addElement('text', 'iteminfo', get_string('iteminfo', 'grades')); + $mform->setHelpButton('iteminfo', array(false, get_string('iteminfo', 'grades'), + false, true, false, get_string('iteminfohelp', 'grades'))); $mform->addElement('text', 'idnumber', get_string('idnumber')); + $mform->setHelpButton('idnumber', array(false, get_string('idnumber'), + false, true, false, get_string('idnumberhelp', 'grades'))); // allow setting of outcomes on module items too $options = array(); @@ -26,6 +30,8 @@ class edit_outcomeitem_form extends moodleform { } } $mform->addElement('select', 'outcomeid', get_string('outcome', 'grades'), $options); + $mform->setHelpButton('outcomeid', array(false, get_string('outcomeid', 'grades'), + false, true, false, get_string('outcomeidhelp', 'grades'))); $mform->addRule('outcomeid', get_string('required'), 'required'); $options = array(0=>get_string('none')); @@ -36,6 +42,8 @@ class edit_outcomeitem_form extends moodleform { } } $mform->addElement('select', 'cmid', get_string('linkedactivity', 'grades'), $options); + $mform->setHelpButton('cmid', array(false, get_string('linkedactivity', 'grades'), + false, true, false, get_string('linkedactivityhelp', 'grades'))); $mform->setDefault('cmid', 0); //$mform->addElement('text', 'calculation', get_string('calculation', 'grades')); @@ -46,12 +54,16 @@ class edit_outcomeitem_form extends moodleform { /// hiding /// advcheckbox is not compatible with disabledIf !! $mform->addElement('checkbox', 'hidden', get_string('hidden', 'grades')); + $mform->setHelpButton('hidden', array('hidden', get_string('hidden', 'grades'), 'grade')); $mform->addElement('date_time_selector', 'hiddenuntil', get_string('hiddenuntil', 'grades'), array('optional'=>true)); + $mform->setHelpButton('hiddenuntil', array('hiddenuntil', get_string('hiddenuntil', 'grades'), 'grade')); $mform->disabledIf('hiddenuntil', 'hidden', 'checked'); //locking $mform->addElement('advcheckbox', 'locked', get_string('locked', 'grades')); + $mform->setHelpButton('locked', array('locked', get_string('locked', 'grades'), 'grade')); $mform->addElement('date_time_selector', 'locktime', get_string('locktime', 'grades'), array('optional'=>true)); + $mform->setHelpButton('locktime', array('locktime', get_string('locktime', 'grades'), 'grade')); /// hidden params $mform->addElement('hidden', 'id', 0); diff --git a/lang/en_utf8/grades.php b/lang/en_utf8/grades.php index 43c149793..0497ecb9d 100644 --- a/lang/en_utf8/grades.php +++ b/lang/en_utf8/grades.php @@ -121,17 +121,20 @@ $string['errornocourse'] = 'Could not get course information'; $string['errorreprintheadersnonnumeric'] = 'Received non-numeric value for reprint-headers'; $string['exceptions'] = 'Exceptions'; $string['excluded'] = 'Excluded'; +$string['excludedhelp'] = 'If -excluded- is switched on, this grade will be excluded from any aggregation performed by any parent grade item or category.'; $string['expand'] = 'Expand Category'; $string['export'] = 'Export'; $string['exportplugins'] = 'Export plugins'; $string['extracredit'] = 'Extra Credit'; $string['extracreditwarning'] = 'Note: Setting all items for a category to extra credit will effectively remove them from the grade calculation. Since there will be no point total'; $string['feedback'] = 'Feedback'; +$string['feedbackhelp'] = 'Notes added to the grade by the teacher. They can be extensive, personalised feedback or a simple code that refers to an internal system of feedback.'; $string['feedbackadd'] = 'Add feedback'; $string['feedbackedit'] = 'Edit feedback'; $string['feedbackview'] = 'View feedback'; $string['feedbacksaved'] = 'Feedback saved'; $string['finalgrade'] = 'Final grade'; +$string['finalgradehelp'] = 'The final grade (cached) after all calculations are performed.'; $string['forelementtypes'] = ' for the selected $a'; $string['forstudents'] = 'For Students'; $string['full'] = 'Full'; @@ -214,6 +217,7 @@ $string['lettergradenonnumber'] = 'Low and/or High grade were non-numeric for'; $string['letter'] = 'Letter'; $string['letters'] = 'Letters'; $string['linkedactivity'] = 'Linked activity'; +$string['linkedactivityhelp'] = 'An optional activity this outcome item is linked to.'; $string['lock'] = 'Lock'; $string['locked'] = 'Locked'; $string['locktime'] = 'Locked until'; @@ -253,6 +257,7 @@ $string['onascaleof'] = ' on a scale of $a->grademin to $a->grademax'; $string['operations'] = 'Operations'; $string['outcome'] = 'Outcome'; $string['outcomecreate'] = 'Add a new outcome'; +$string['outcomeidhelp'] = 'The outcome this grade item represents.'; $string['outcomeitem'] = 'Outcome item'; $string['outcomeitemsedit'] = 'Edit outcome item'; $string['outcomes'] = 'Outcomes'; @@ -269,6 +274,7 @@ $string['outcomesstandardavailable'] = 'Available standard outcomes'; $string['outcomestandard'] = 'Standard outcome'; $string['outcomes'] = 'Outcomes'; $string['overridden'] = 'Overridden'; +$string['overriddenhelp'] = 'When on, the overridden flag prevents any future attempts to automatically adjust the value of the grade. This flag is often set internally by the gradebook, but can be switched on and off manually using this form element.'; $string['overallavg'] = 'Overall average'; $string['pctoftotalgrade'] = '%% of total grade'; $string['percent'] = 'Percent'; diff --git a/lang/en_utf8/help/grade/hidden.html b/lang/en_utf8/help/grade/hidden.html index f14009378..50d16b030 100644 --- a/lang/en_utf8/help/grade/hidden.html +++ b/lang/en_utf8/help/grade/hidden.html @@ -1,5 +1,5 @@

Hidden

-

Whether or not the grades in this grade item are hidden to all participants. Usually after the end of the activity and of the grading process.. A typical sequence of events would be: +

Whether or not the grades are hidden to participants. Usually after the end of the activity and of the grading process.. A typical sequence of events would be:

diff --git a/lang/en_utf8/help/grade/hiddenuntil.html b/lang/en_utf8/help/grade/hiddenuntil.html index 335adf463..e7a3609e3 100644 --- a/lang/en_utf8/help/grade/hiddenuntil.html +++ b/lang/en_utf8/help/grade/hiddenuntil.html @@ -1,5 +1,5 @@

Hidden until

-

Date until which the grades in this grade item will be hidden to all participants. Usually after the end of the activity and of the grading process.. A typical sequence of events would be: +

Date until which the grades will be hidden to participants. Usually after the end of the activity and of the grading process.. A typical sequence of events would be:

diff --git a/lang/en_utf8/help/grade/hiddenuntil.html b/lang/en_utf8/help/grade/locked.html similarity index 75% copy from lang/en_utf8/help/grade/hiddenuntil.html copy to lang/en_utf8/help/grade/locked.html index 335adf463..0014d11f4 100644 --- a/lang/en_utf8/help/grade/hiddenuntil.html +++ b/lang/en_utf8/help/grade/locked.html @@ -1,5 +1,5 @@ -

Hidden until

-

Date until which the grades in this grade item will be hidden to all participants. Usually after the end of the activity and of the grading process.. A typical sequence of events would be: +

Locked

+

Whether or not the grades accept automatic updates from the activity they are linked to. Usually this is switched on (locked) as soon as the activity is finished and submissions are no longer accepted. A typical sequence of events would be:

diff --git a/lang/en_utf8/help/grade/lockeduntil.html b/lang/en_utf8/help/grade/lockeduntil.html index 57b13b09f..52f359a9a 100644 --- a/lang/en_utf8/help/grade/lockeduntil.html +++ b/lang/en_utf8/help/grade/lockeduntil.html @@ -1,5 +1,5 @@

Locked until

-

Date after which the grades in this grade item will be locked. Usually this date is set to the end of the activity, and the beginning of the grading process.. A typical sequence of events would be: +

Date after which the grades will be locked. Usually this date is set to the end of the activity, and the beginning of the grading process.. A typical sequence of events would be:

-- 2.11.4.GIT