'm.markingworkflow, ' .
'm.markingallocation, ' .
'm.requiresubmissionstatement, '.
+ 'm.preventsubmissionnotingroup, '.
'm.intro, '.
'm.introformat';
$coursearray = array();
'markingworkflow' => $module->markingworkflow,
'markingallocation' => $module->markingallocation,
'requiresubmissionstatement' => $module->requiresubmissionstatement,
+ 'preventsubmissionnotingroup' => $module->preventsubmissionnotingroup,
'configs' => $configarray
);
'markingworkflow' => new external_value(PARAM_INT, 'enable marking workflow'),
'markingallocation' => new external_value(PARAM_INT, 'enable marking allocation'),
'requiresubmissionstatement' => new external_value(PARAM_INT, 'student must accept submission statement'),
+ 'preventsubmissionnotingroup' => new external_value(PARAM_INT, 'Prevent submission not in group', VALUE_OPTIONAL),
'configs' => new external_multiple_structure(self::get_assignments_config_structure(), 'configuration settings'),
'intro' => new external_value(PARAM_RAW,
'assignment intro, not allways returned because it deppends on the activity configuration', VALUE_OPTIONAL),
$this->assertRegExp('@"' . $CFG->wwwroot . '/webservice/pluginfile.php/\d+/mod_assign/intro/intro\.txt"@', $assignment['intro']);
$this->assertEquals(1, $assignment['markingworkflow']);
$this->assertEquals(1, $assignment['markingallocation']);
+ $this->assertEquals(0, $assignment['preventsubmissionnotingroup']);
$this->assertCount(1, $assignment['introattachments']);
$this->assertEquals('introattachment.txt', $assignment['introattachments'][0]['filename']);
$this->assertArrayNotHasKey('introattachments', $assignment);
$this->assertEquals(1, $assignment['markingworkflow']);
$this->assertEquals(1, $assignment['markingallocation']);
+ $this->assertEquals(0, $assignment['preventsubmissionnotingroup']);
$result = mod_assign_external::get_assignments(array($course2->id));
$this->assertArrayNotHasKey('introattachments', $assignment);
$this->assertEquals(1, $assignment['markingworkflow']);
$this->assertEquals(1, $assignment['markingallocation']);
+ $this->assertEquals(0, $assignment['preventsubmissionnotingroup']);
}
/**
This files describes API changes in the assign code.
+=== 3.2 ===
+* External function mod_assign_external::get_assignments now returns additional optional fields:
+ - preventsubmissionnotingroup: Prevent submission not in group.
+
=== 3.1 ===
* The feedback plugins now need to implement the is_feedback_modified() method. The default is to return true
for backwards compatibiltiy.