rename basepac property for reflection problems

This commit is contained in:
Peter Hormanns 2015-09-11 23:03:09 +02:00
parent 88b6b6e67d
commit 4d4ed2942a

View File

@ -58,7 +58,7 @@ public class Pac extends AbstractEntity implements Serializable {
@JoinColumn(name = "basepacket_id") @JoinColumn(name = "basepacket_id")
@ManyToOne(fetch = EAGER) @ManyToOne(fetch = EAGER)
@AnnFieldIO(rw=ReadWriteAccess.WRITEONCE,validation="[A-Za-z0-9\\/]*") @AnnFieldIO(rw=ReadWriteAccess.WRITEONCE,validation="[A-Za-z0-9\\/]*")
private BasePac basePac; private BasePac basepac;
@JoinColumn(name = "hive_id") @JoinColumn(name = "hive_id")
@ManyToOne(fetch = EAGER) @ManyToOne(fetch = EAGER)
@ -96,10 +96,10 @@ public class Pac extends AbstractEntity implements Serializable {
Query qAttachedBasepac = em.createQuery("SELECT b FROM BasePacs b WHERE b.valid = :valid AND b.name = :name"); Query qAttachedBasepac = em.createQuery("SELECT b FROM BasePacs b WHERE b.valid = :valid AND b.name = :name");
qAttachedBasepac.setParameter("valid", Boolean.TRUE); qAttachedBasepac.setParameter("valid", Boolean.TRUE);
qAttachedBasepac.setParameter("name", aBasepac.getName()); qAttachedBasepac.setParameter("name", aBasepac.getName());
basePac = (BasePac) qAttachedBasepac.getSingleResult(); basepac = (BasePac) qAttachedBasepac.getSingleResult();
pacComponents = new HashSet<PacComponent>(); pacComponents = new HashSet<PacComponent>();
Date today = new Date(); Date today = new Date();
for (Component comp : basePac.getComponents()) { for (Component comp : basepac.getComponents()) {
PacComponent pacComp = new PacComponent(); PacComponent pacComp = new PacComponent();
pacComp.setCreated(today); pacComp.setCreated(today);
pacComp.setBaseComponent(comp.getBaseComponent()); pacComp.setBaseComponent(comp.getBaseComponent());
@ -200,11 +200,11 @@ public class Pac extends AbstractEntity implements Serializable {
} }
public BasePac getBasepac() { public BasePac getBasepac() {
return basePac; return basepac;
} }
public void setBasepac(BasePac basepac) { public void setBasepac(BasePac basepac) {
this.basePac = basepac; this.basepac = basepac;
} }
public Set<PacComponent> getPacComponents() { public Set<PacComponent> getPacComponents() {