commit aa2d75ec41fe024cbf3ec79e451daa3c2f0fab27 Author: t6nis Date: Wed Oct 10 13:28:43 2012 +0300 MDL-35910 - Assignment(2.2) allow download files as zip when send for marking is set no. diff --git a/mod/assignment/type/upload/assignment.class.php b/mod/assignment/type/upload/assignment.class.php index 7956bd6..c361f0f 100644 --- a/mod/assignment/type/upload/assignment.class.php +++ b/mod/assignment/type/upload/assignment.class.php @@ -1165,10 +1165,10 @@ class assignment_upload extends assignment_base { } $filename = str_replace(' ', '_', clean_filename($this->course->shortname.'-'.$this->assignment->name.'-'.$groupname.$this->assignment->id.".zip")); //name of new zip file. - foreach ($submissions as $submission) { - // If assignment is open and submission is not finalized then don't add it to zip. - //09.10.2012 - if there is no send for marking button, skip the submitted flag setting + foreach ($submissions as $submission) { + //If "Send for marking" button is no, skip this check and download all, including drafts. if ($this->assignment->var4 > 0) { + // If assignment is open and submission is not finalized then don't add it to zip. $submissionstatus = $this->is_finalized($submission); if ($this->isopen() && empty($submissionstatus)) { continue;