better variable name

This commit is contained in:
Peter Hormanns 2013-04-30 18:44:38 +02:00
parent 8372a48bcb
commit 6ec7999be6

View File

@ -87,11 +87,11 @@ public class Pac extends AbstractEntity implements Serializable {
@Transient
private BasePac basepac;
public void initPacComponents(EntityManager em, BasePac aBasePac) {
Query qBasepac = em.createQuery("SELECT b FROM BasePacs b WHERE b.valid = :valid AND b.name = :name");
qBasepac.setParameter("valid", Boolean.TRUE);
qBasepac.setParameter("name", aBasePac.getName());
basepac = (BasePac) qBasepac.getSingleResult();
public void initPacComponents(EntityManager em, BasePac aBasepac) {
Query qAttachedBasepac = em.createQuery("SELECT b FROM BasePacs b WHERE b.valid = :valid AND b.name = :name");
qAttachedBasepac.setParameter("valid", Boolean.TRUE);
qAttachedBasepac.setParameter("name", aBasepac.getName());
basepac = (BasePac) qAttachedBasepac.getSingleResult();
setBasepac(basepac);
pacComponents = new HashSet<PacComponent>();
Date today = new Date();