1 | |
|
2 | |
|
3 | |
|
4 | |
|
5 | |
|
6 | |
|
7 | |
|
8 | |
|
9 | |
|
10 | |
|
11 | |
|
12 | |
|
13 | |
|
14 | |
|
15 | |
|
16 | |
package org.kuali.rice.kim.impl.identity.affiliation |
17 | |
|
18 | |
import javax.persistence.Column |
19 | |
import javax.persistence.Entity |
20 | |
import javax.persistence.Id |
21 | |
import javax.persistence.Table |
22 | |
import org.kuali.rice.kim.api.identity.CodedAttribute |
23 | |
import org.kuali.rice.kim.api.identity.CodedAttributeContract |
24 | |
import org.kuali.rice.krad.bo.PersistableBusinessObjectBase |
25 | |
import org.kuali.rice.kim.api.identity.affiliation.EntityAffiliationTypeContract |
26 | |
import org.kuali.rice.kim.api.identity.affiliation.EntityAffiliationType |
27 | |
|
28 | |
@Entity |
29 | |
@Table(name="KRIM_AFLTN_TYP_T") |
30 | |
public class EntityAffiliationTypeBo extends PersistableBusinessObjectBase implements EntityAffiliationTypeContract { |
31 | |
@Id |
32 | |
@Column(name="EMP_TYP_CD") |
33 | |
String code; |
34 | |
@Column(name="NM") |
35 | |
String name; |
36 | |
@org.hibernate.annotations.Type(type="yes_no") |
37 | |
@Column(name="ACTV_IND") |
38 | |
boolean active; |
39 | |
@Column(name="DISPLAY_SORT_CD") |
40 | |
String sortCode; |
41 | |
|
42 | |
@org.hibernate.annotations.Type(type="yes_no") |
43 | |
@Column(name="EMP_AFLTN_TYP_IND") |
44 | |
boolean employmentAffiliationType; |
45 | |
|
46 | |
|
47 | |
|
48 | |
|
49 | |
|
50 | |
|
51 | |
|
52 | |
static EntityAffiliationType to(EntityAffiliationTypeBo bo) { |
53 | 0 | if (bo == null) { return null } |
54 | 0 | return EntityAffiliationType.Builder.create(bo).build() |
55 | |
} |
56 | |
|
57 | |
|
58 | |
|
59 | |
|
60 | |
|
61 | |
|
62 | |
static EntityAffiliationTypeBo from(EntityAffiliationType immutable) { |
63 | 0 | if (immutable == null) {return null} |
64 | |
|
65 | 0 | EntityAffiliationTypeBo bo = new EntityAffiliationTypeBo() |
66 | 0 | bo.code = immutable.code |
67 | 0 | bo.name = immutable.name |
68 | 0 | bo.sortCode = immutable.sortCode |
69 | 0 | bo.employmentAffiliationType = immutable.employmentAffiliationType |
70 | 0 | bo.active = immutable.active |
71 | 0 | bo.versionNumber = immutable.versionNumber |
72 | 0 | bo.objectId = immutable.objectId |
73 | |
|
74 | 0 | return bo; |
75 | |
} |
76 | |
} |