diff --git a/src/main/java/org/olat/modules/portfolio/model/BinderImpl.java b/src/main/java/org/olat/modules/portfolio/model/BinderImpl.java index a7569ffad141ed744bcfd6f808418f32eb53020d..b60ba89245401ca22575ff192c60ca1b3cdc1eb6 100644 --- a/src/main/java/org/olat/modules/portfolio/model/BinderImpl.java +++ b/src/main/java/org/olat/modules/portfolio/model/BinderImpl.java @@ -32,7 +32,6 @@ import javax.persistence.GenerationType; import javax.persistence.Id; import javax.persistence.JoinColumn; import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; import javax.persistence.NamedQuery; import javax.persistence.OneToMany; import javax.persistence.OrderColumn; @@ -64,11 +63,12 @@ import org.olat.resource.OLATResourceImpl; */ @Entity(name="pfbinder") @Table(name="o_pf_binder") -@NamedQueries({ - @NamedQuery(name="loadBinderByKey", query="select binder from pfbinder as binder inner join fetch binder.baseGroup as baseGroup where binder.key=:portfolioKey") - - -}) +@NamedQuery(name="loadBinderByKey", query="select binder from pfbinder as binder" + + " inner join fetch binder.baseGroup as baseGroup" + + " left join fetch binder.entry as v" + + " left join fetch v.olatResource as res" + + " where binder.key=:portfolioKey") + public class BinderImpl implements Persistable, ModifiedInfo, CreateInfo, Binder { private static final long serialVersionUID = -2607615295380443760L;