V agendě Fakturace požadavků byl opraven lazy load vlastníka požadavku.

refs #182
Verze_1.0
Josef Rokos 10 years ago
parent 4e2b00a957
commit ecbc2be47c

@ -64,5 +64,13 @@ public class InvoicingServiceImpl extends AbstractOwnedService<Invoicing> implem
Query q = dao.getQuery("select inv from Invoicing as inv join fetch inv.requirement rq join fetch rq.ownedBy order by rq.numser"); Query q = dao.getQuery("select inv from Invoicing as inv join fetch inv.requirement rq join fetch rq.ownedBy order by rq.numser");
return q.list(); return q.list();
} }
@Transactional
@LazyLoader("form")
public void loadOwnedBy(Invoicing invoice) {
Invoicing inv = getById(invoice.getId());
Hibernate.initialize(inv.getRequirement().getOwnedBy());
invoice.getRequirement().setOwnedBy(inv.getRequirement().getOwnedBy());
}
} }

Loading…
Cancel
Save