Skip to content
Snippets Groups Projects
Commit 1b6ddc35 authored by srosse's avatar srosse
Browse files

OO-4240: allow collecting task without task and optional

parent bc9c307b
No related branches found
No related tags found
No related merge requests found
......@@ -737,6 +737,11 @@ public class GTACoachController extends GTAAbstractController implements Assessm
submittedDocuments = documentsDir.listFiles(new SystemFilenameFilter(true, false));
}
if(task == null && gtaNode.isOptional()) {
TaskProcess firstStep = gtaManager.firstStep(gtaNode);
task = gtaManager.createTask(null, taskList, firstStep, assessedGroup, assessedIdentity, gtaNode);
}
int numOfDocs = submittedDocuments == null ? 0 : submittedDocuments.length;
task = gtaManager.collectTask(task, gtaNode, numOfDocs);
showInfo("run.documents.successfully.submitted");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment