use of uk.ac.ebi.spot.goci.curation.model.StudyNoteForm in project goci by EBISPOT.
the class StudyNoteOperationsService method convertToStudyNoteForm.
public StudyNoteForm convertToStudyNoteForm(StudyNote note) {
// #xintodo Should factory be use to create these instance?
StudyNoteForm noteFrom = new StudyNoteForm(note.getId(), note.getTextNote(), noteSubjectService.findOne(note.getNoteSubject().getId()), note.getStatus(), curatorService.findOne(note.getCurator().getId()), note.getGenericId(), note.getCreatedAt(), note.getUpdatedAt());
if (isSystemNote(note)) {
noteFrom.setSystemNote(Boolean.TRUE);
noteFrom.makeNotEditable();
} else {
noteFrom.setSystemNote(Boolean.FALSE);
noteFrom.makeEditable();
}
return noteFrom;
}
Aggregations