annotate pac properties
This commit is contained in:
parent
c8dd78ff9f
commit
fa75194cf3
@ -25,7 +25,9 @@ import javax.persistence.Temporal;
|
||||
import javax.persistence.TemporalType;
|
||||
|
||||
import de.hsadmin.core.model.AbstractEntity;
|
||||
import de.hsadmin.core.model.AnnFieldIO;
|
||||
import de.hsadmin.core.model.AnnModuleImpl;
|
||||
import de.hsadmin.core.model.ReadWriteAccess;
|
||||
import de.hsadmin.hostsharing.BasePacType;
|
||||
import de.hsadmin.mods.cust.Customer;
|
||||
import de.hsadmin.mods.user.UnixUser;
|
||||
@ -46,6 +48,7 @@ public class Pac extends AbstractEntity implements Serializable {
|
||||
private long id;
|
||||
|
||||
@Column(name = "packet_name", unique = true)
|
||||
@AnnFieldIO(rw=ReadWriteAccess.WRITEONCE,validation="[a-z0-9]*")
|
||||
private String name;
|
||||
|
||||
@JoinColumn(name = "bp_id")
|
||||
@ -54,10 +57,12 @@ public class Pac extends AbstractEntity implements Serializable {
|
||||
|
||||
@JoinColumn(name = "basepacket_id")
|
||||
@ManyToOne(fetch = EAGER)
|
||||
@AnnFieldIO(rw=ReadWriteAccess.WRITEONCE,validation="[A-Za-z0-9\\/]*")
|
||||
private BasePac basePac;
|
||||
|
||||
@JoinColumn(name = "hive_id")
|
||||
@ManyToOne(fetch = EAGER)
|
||||
@AnnFieldIO(rw=ReadWriteAccess.WRITEONCE,validation="[a-z0-9]*")
|
||||
private Hive hive;
|
||||
|
||||
@Column(name = "created")
|
||||
@ -73,6 +78,7 @@ public class Pac extends AbstractEntity implements Serializable {
|
||||
|
||||
@JoinColumn(name = "cur_inet_addr_id", nullable = true)
|
||||
@ManyToOne(fetch = EAGER)
|
||||
@AnnFieldIO(rw=ReadWriteAccess.WRITEONCE,validation="[0-9\\.]*")
|
||||
private INetAddress curINetAddr;
|
||||
|
||||
@JoinColumn(name = "old_inet_addr_id", nullable = true)
|
||||
@ -83,6 +89,7 @@ public class Pac extends AbstractEntity implements Serializable {
|
||||
private Set<PacComponent> pacComponents;
|
||||
|
||||
@OneToMany(fetch = LAZY, cascade = ALL, mappedBy="pac")
|
||||
@AnnFieldIO(rw=ReadWriteAccess.WRITEONCE,validation="[a-z0-9\\-\\.\\_]*")
|
||||
private Set<UnixUser> unixUser;
|
||||
|
||||
public void initPacComponents(EntityManager em, BasePac aBasepac, boolean setDefaults) {
|
||||
|
Loading…
Reference in New Issue
Block a user