1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package edu.sampleu.travel.dataobject;
17
18 import org.kuali.rice.core.api.mo.common.active.MutableInactivatable;
19 import org.kuali.rice.krad.bo.DataObjectBase;
20 import org.kuali.rice.krad.data.jpa.converters.BooleanYNConverter;
21 import org.kuali.rice.krad.data.jpa.PortableSequenceGenerator;
22 import org.kuali.rice.krad.data.provider.annotation.Description;
23 import org.kuali.rice.krad.data.provider.annotation.Label;
24 import org.kuali.rice.krad.data.provider.annotation.UifAutoCreateViewType;
25 import org.kuali.rice.krad.data.provider.annotation.UifAutoCreateViews;
26 import org.kuali.rice.krad.data.provider.annotation.UifValidCharactersConstraintBeanName;
27
28 import javax.persistence.Column;
29 import javax.persistence.Entity;
30 import javax.persistence.GeneratedValue;
31 import javax.persistence.Id;
32 import javax.persistence.Table;
33 import java.io.Serializable;
34
35
36
37
38
39
40 @Entity
41 @Table(name = "TRVL_CO_T")
42 @UifAutoCreateViews({UifAutoCreateViewType.INQUIRY, UifAutoCreateViewType.LOOKUP})
43 public class TravelCompany extends DataObjectBase implements MutableInactivatable, Serializable {
44
45 private static final long serialVersionUID = 6853317217732768445L;
46
47 @Id @Column(name = "CO_ID", length = 40)
48 @GeneratedValue(generator = "TRVL_CO_ID_S")
49 @PortableSequenceGenerator(name = "TRVL_CO_ID_S")
50 @Label("Id")
51 @Description("Unique identifier for company")
52 @UifValidCharactersConstraintBeanName("AlphaNumericPatternConstraint")
53 private String travelCompanyId;
54
55 @Column(name = "CO_NM", length = 40)
56 @Label("Company Name")
57 @Description("Company Name")
58 private String travelCompanyName;
59
60 @Column(name = "ACTV_IND", nullable = false, length = 1)
61 @javax.persistence.Convert(converter = BooleanYNConverter.class)
62 @Label("Active")
63 @Description("Whether active or inactive")
64 private boolean active = Boolean.TRUE;
65
66 public String getTravelCompanyId() {
67 return travelCompanyId;
68 }
69
70 public void setTravelCompanyId(String travelCompanyId) {
71 this.travelCompanyId = travelCompanyId;
72 }
73
74 public String getTravelCompanyName() {
75 return travelCompanyName;
76 }
77
78 public void setTravelCompanyName(String travelCompanyName) {
79 this.travelCompanyName = travelCompanyName;
80 }
81
82 public boolean isActive() {
83 return active;
84 }
85
86 public void setActive(boolean active) {
87 this.active = active;
88 }
89 }