001 /*
002 * Copyright 2006-2007 The Kuali Foundation
003 *
004 * Licensed under the Educational Community License, Version 2.0 (the "License");
005 * you may not use this file except in compliance with the License.
006 * You may obtain a copy of the License at
007 *
008 * http://www.opensource.org/licenses/ecl2.php
009 *
010 * Unless required by applicable law or agreed to in writing, software
011 * distributed under the License is distributed on an "AS IS" BASIS,
012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
013 * See the License for the specific language governing permissions and
014 * limitations under the License.
015 */
016
017 package edu.sampleu.travel.bo;
018
019 import java.util.Date;
020
021 import javax.persistence.CascadeType;
022 import javax.persistence.Column;
023 import javax.persistence.Entity;
024 import javax.persistence.FetchType;
025 import javax.persistence.Id;
026 import javax.persistence.JoinColumn;
027 import javax.persistence.ManyToOne;
028 import javax.persistence.Table;
029
030 import org.kuali.rice.core.util.type.KualiPercent;
031 import org.kuali.rice.kns.bo.PersistableBusinessObjectBase;
032
033 @Entity
034 @Table(name="TRV_ACCT")
035 public class TravelAccount extends PersistableBusinessObjectBase {
036
037 private static final long serialVersionUID = -7739303391609093875L;
038
039 @Id
040 @Column(name="acct_num")
041 private String number;
042
043 private String subAccount;
044
045 @Column(name="acct_name")
046 private String name;
047
048 private String subAccountName;
049
050 private KualiPercent subsidizedPercent;
051
052 private Date createDate;
053
054 public Date getCreateDate() {
055 return this.createDate;
056 }
057
058 @Column(name="acct_fo_id")
059 private Long foId;
060
061 @ManyToOne(fetch=FetchType.EAGER, cascade={CascadeType.PERSIST, CascadeType.MERGE})
062 @JoinColumn(name="acct_fo_id", insertable=false, updatable=false)
063 private FiscalOfficer fiscalOfficer;
064
065 public String getName() {
066 return name;
067 }
068
069 public void setName(String name) {
070 this.name = name;
071 }
072
073 public String getNumber() {
074 return number;
075 }
076
077 public void setNumber(String number) {
078 this.number = number;
079 }
080
081 public FiscalOfficer getFiscalOfficer() {
082 return fiscalOfficer;
083 }
084
085 public void setFiscalOfficer(FiscalOfficer fiscalOfficer) {
086 this.fiscalOfficer = fiscalOfficer;
087 }
088
089 public Long getFoId() {
090 return foId;
091 }
092
093 public void setFoId(Long foId) {
094 this.foId = foId;
095 }
096
097 public String getSubAccount() {
098 return this.subAccount;
099 }
100
101 public void setSubAccount(String subAccount) {
102 this.subAccount = subAccount;
103 }
104
105 public String getSubAccountName() {
106 return this.subAccountName;
107 }
108
109 public void setSubAccountName(String subAccountName) {
110 this.subAccountName = subAccountName;
111 }
112
113 public KualiPercent getSubsidizedPercent() {
114 return this.subsidizedPercent;
115 }
116
117 public void setSubsidizedPercent(KualiPercent subsidizedPercent) {
118 this.subsidizedPercent = subsidizedPercent;
119 }
120
121 public void setCreateDate(Date createDate) {
122 this.createDate = createDate;
123 }
124
125 }