001: /*
002: * Copyright 2005-2007 The Kuali Foundation.
003: *
004: * Licensed under the Educational Community License, Version 1.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/ecl1.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 org.kuali.module.financial.bo;
018:
019: import java.util.LinkedHashMap;
020:
021: import org.kuali.core.bo.PersistableBusinessObjectBase;
022: import org.kuali.core.util.KualiDecimal;
023: import org.kuali.kfs.KFSPropertyConstants;
024:
025: /**
026: * This class is used to represent a disbursement voucher non-employee expense, often associated with a trip or a service rendered.
027: */
028: public class DisbursementVoucherNonEmployeeExpense extends
029: PersistableBusinessObjectBase {
030:
031: private String documentNumber;
032: private Integer financialDocumentLineNumber;
033: private String disbVchrExpenseCode;
034: private String disbVchrExpenseCompanyName;
035: private KualiDecimal disbVchrExpenseAmount;
036:
037: private TravelExpenseTypeCode disbVchrExpense;
038: private TravelCompanyCode disbVchrExpenseCompany;
039: private DisbursementVoucherNonEmployeeTravel disbursementVoucherNonEmployeeTravel;
040:
041: private boolean isPrepaid;
042:
043: /**
044: * Default no-arg constructor.
045: */
046: public DisbursementVoucherNonEmployeeExpense() {
047:
048: }
049:
050: /**
051: * Gets the documentNumber attribute.
052: *
053: * @return Returns the documentNumber
054: */
055: public String getDocumentNumber() {
056: return documentNumber;
057: }
058:
059: /**
060: * Sets the documentNumber attribute.
061: *
062: * @param documentNumber The documentNumber to set.
063: */
064: public void setDocumentNumber(String documentNumber) {
065: this .documentNumber = documentNumber;
066: }
067:
068: /**
069: * Gets the financialDocumentLineNumber attribute.
070: *
071: * @return Returns the financialDocumentLineNumber
072: */
073: public Integer getFinancialDocumentLineNumber() {
074: return financialDocumentLineNumber;
075: }
076:
077: /**
078: * Sets the financialDocumentLineNumber attribute.
079: *
080: * @param financialDocumentLineNumber The financialDocumentLineNumber to set.
081: */
082: public void setFinancialDocumentLineNumber(
083: Integer financialDocumentLineNumber) {
084: this .financialDocumentLineNumber = financialDocumentLineNumber;
085: }
086:
087: /**
088: * Gets the disbVchrExpenseCode attribute.
089: *
090: * @return Returns the disbVchrExpenseCode
091: */
092: public String getDisbVchrExpenseCode() {
093: return disbVchrExpenseCode;
094: }
095:
096: /**
097: * Dummy field so we can have different select options.
098: *
099: * @return String
100: */
101: public String getDisbVchrPrePaidExpenseCode() {
102: return disbVchrExpenseCode;
103: }
104:
105: /**
106: * Sets the disbVchrExpenseCode attribute.
107: *
108: * @param disbVchrExpenseCode The disbVchrExpenseCode to set.
109: */
110: public void setDisbVchrExpenseCode(String disbVchrExpenseCode) {
111: this .disbVchrExpenseCode = disbVchrExpenseCode;
112: this .refresh();
113: }
114:
115: /**
116: * Dummy field so we can have different select options.
117: *
118: * @param disbVchrExpenseCode
119: */
120: public void setDisbVchrPrePaidExpenseCode(String disbVchrExpenseCode) {
121: this .disbVchrExpenseCode = disbVchrExpenseCode;
122: }
123:
124: /**
125: * Gets the disbVchrExpenseCompanyName attribute.
126: *
127: * @return Returns the disbVchrExpenseCompanyName
128: */
129: public String getDisbVchrExpenseCompanyName() {
130: return disbVchrExpenseCompanyName;
131: }
132:
133: /**
134: * Sets the disbVchrExpenseCompanyName attribute.
135: *
136: * @param disbVchrExpenseCompanyName The disbVchrExpenseCompanyName to set.
137: */
138: public void setDisbVchrExpenseCompanyName(
139: String disbVchrExpenseCompanyName) {
140: this .disbVchrExpenseCompanyName = disbVchrExpenseCompanyName;
141: }
142:
143: /**
144: * Gets the disbVchrExpenseCompanyName attribute.
145: *
146: * @return Returns the disbVchrExpenseCompanyName
147: */
148: public String getDisbVchrPrePaidExpenseCompanyName() {
149: return disbVchrExpenseCompanyName;
150: }
151:
152: /**
153: * Sets the disbVchrExpenseCompanyName attribute.
154: *
155: * @param disbVchrExpenseCompanyName The disbVchrExpenseCompanyName to set.
156: */
157: public void setDisbVchrPrePaidExpenseCompanyName(
158: String disbVchrExpenseCompanyName) {
159: this .disbVchrExpenseCompanyName = disbVchrExpenseCompanyName;
160: }
161:
162: /**
163: * Gets the disbVchrExpenseAmount attribute.
164: *
165: * @return Returns the disbVchrExpenseAmount
166: */
167: public KualiDecimal getDisbVchrExpenseAmount() {
168: return disbVchrExpenseAmount;
169: }
170:
171: /**
172: * Sets the disbVchrExpenseAmount attribute.
173: *
174: * @param disbVchrExpenseAmount The disbVchrExpenseAmount to set.
175: */
176: public void setDisbVchrExpenseAmount(
177: KualiDecimal disbVchrExpenseAmount) {
178: this .disbVchrExpenseAmount = disbVchrExpenseAmount;
179: }
180:
181: /**
182: * Gets the disbVchrExpense attribute.
183: *
184: * @return Returns the disbVchrExpense
185: */
186: public TravelExpenseTypeCode getDisbVchrExpense() {
187: return disbVchrExpense;
188: }
189:
190: /**
191: * Sets the disbVchrExpense attribute.
192: *
193: * @param disbVchrExpense The disbVchrExpense to set.
194: * @deprecated
195: */
196: public void setDisbVchrExpense(TravelExpenseTypeCode disbVchrExpense) {
197: this .disbVchrExpense = disbVchrExpense;
198: }
199:
200: /**
201: * Gets the disbVchrExpenseCompany attribute.
202: *
203: * @return Returns the disbVchrExpenseCompany.
204: */
205: public TravelCompanyCode getDisbVchrExpenseCompany() {
206: return disbVchrExpenseCompany;
207: }
208:
209: /**
210: * Sets the disbVchrExpenseCompany attribute value.
211: *
212: * @param disbVchrExpenseCompany The disbVchrExpenseCompany to set.
213: * @deprecated
214: */
215: public void setDisbVchrExpenseCompany(
216: TravelCompanyCode disbVchrExpenseCompany) {
217: this .disbVchrExpenseCompany = disbVchrExpenseCompany;
218: }
219:
220: /**
221: * Gets the disbursementVoucherNonEmployeeTravel attribute.
222: *
223: * @return Returns the disbursementVoucherNonEmployeeTravel.
224: */
225: public DisbursementVoucherNonEmployeeTravel getDisbursementVoucherNonEmployeeTravel() {
226: return disbursementVoucherNonEmployeeTravel;
227: }
228:
229: /**
230: * Sets the disbursementVoucherNonEmployeeTravel attribute value.
231: *
232: * @param disbursementVoucherNonEmployeeTravel The disbursementVoucherNonEmployeeTravel to set.
233: * @deprecated
234: */
235: public void setDisbursementVoucherNonEmployeeTravel(
236: DisbursementVoucherNonEmployeeTravel disbursementVoucherNonEmployeeTravel) {
237: this .disbursementVoucherNonEmployeeTravel = disbursementVoucherNonEmployeeTravel;
238: }
239:
240: /**
241: * @see org.kuali.core.bo.BusinessObjectBase#toStringMapper()
242: */
243: protected LinkedHashMap toStringMapper() {
244: LinkedHashMap m = new LinkedHashMap();
245: m
246: .put(KFSPropertyConstants.DOCUMENT_NUMBER,
247: this .documentNumber);
248: if (this .financialDocumentLineNumber != null) {
249: m.put("financialDocumentLineNumber",
250: this.financialDocumentLineNumber.toString());
251: }
252: return m;
253: }
254: }
|