use of org.olat.modules.portfolio.PageBody in project openolat by klemens.
the class EvaluationFormHandler method getEditor.
@Override
public Controller getEditor(UserRequest ureq, WindowControl wControl, PageElement element) {
if (element instanceof EvaluationFormPart) {
PortfolioService portfolioService = CoreSpringFactory.getImpl(PortfolioService.class);
// find assignment
EvaluationFormPart eva = (EvaluationFormPart) element;
PageBody body = eva.getBody();
Assignment assignment = portfolioService.getAssignment(body);
// find the evaluation form
RepositoryEntry re = assignment.getFormEntry();
File repositoryDir = new File(FileResourceManager.getInstance().getFileResourceRoot(re.getOlatResource()), FileResourceManager.ZIPDIR);
File formFile = new File(repositoryDir, FORM_XML_FILE);
return new EvaluationFormController(ureq, wControl, formFile);
}
return null;
}
Aggregations