Skip to content

Commit

Permalink
MDL-35910 Assignment 2.2: Fixed included files in assignment zip.
Browse files Browse the repository at this point in the history
If Marking button is enabled, assignment is open and is not finalized, then don't add file to zip
  • Loading branch information
Rajesh Taneja committed Oct 19, 2012
1 parent ecfe814 commit 7212740
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions mod/assignment/type/upload/assignment.class.php
Expand Up @@ -1164,9 +1164,9 @@ public function download_submissions() {
}
$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.
// If assignment is open and submission is not finalized and marking button enabled then don't add it to zip.
$submissionstatus = $this->is_finalized($submission);
if ($this->isopen() && empty($submissionstatus)) {
if ($this->isopen() && empty($submissionstatus) && !empty($this->assignment->var4)) {
continue;
}
$a_userid = $submission->userid; //get userid
Expand Down

0 comments on commit 7212740

Please sign in to comment.