some minor cleanup/bug fix

This commit is contained in:
toyomoyo 2007-07-03 06:20:07 +00:00
parent 5b5eb8e6c7
commit 7759d32720
11 changed files with 30 additions and 67 deletions

View file

@ -9,7 +9,7 @@ class grade_export_form extends moodleform {
$mform->addElement('header', 'general', get_string('gradeitemsinc', 'grades')); // TODO: localize
$id = $this->_customdata['id']; // course id
$mform->addElement('hidden', 'id', $id);
if ($grade_items = grade_grades::fetch_all(array('courseid'=>$id))) {
if ($grade_items = grade_item::fetch_all(array('courseid'=>$id))) {
foreach ($grade_items as $grade_item) {
$element = new HTML_QuickForm_advcheckbox('itemids[]', null, $grade_item->itemname, array('selected'=>'selected'), array(0, $grade_item->id));
$element->setChecked(1);