001: /*
002: * Copyright 2006-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.sql.Date;
020: import java.util.LinkedHashMap;
021:
022: import org.kuali.core.bo.PersistableBusinessObjectBase;
023: import org.kuali.core.util.KualiDecimal;
024: import org.kuali.kfs.KFSPropertyConstants;
025: import org.kuali.module.chart.bo.Account;
026: import org.kuali.module.chart.bo.Chart;
027:
028: /**
029: * This class is used to represent a sales tax business object.
030: */
031: public class SalesTax extends PersistableBusinessObjectBase {
032:
033: private String documentNumber;
034: private String financialDocumentLineTypeCode;
035: private Integer financialDocumentLineNumber;
036: private String chartOfAccountsCode;
037: private String accountNumber;
038: private KualiDecimal financialDocumentGrossSalesAmount;
039: private KualiDecimal financialDocumentTaxableSalesAmount;
040: private Date financialDocumentSaleDate;
041:
042: private Account account;
043: private Chart chartOfAccounts;
044:
045: /**
046: * Default constructor.
047: */
048: public SalesTax() {
049:
050: }
051:
052: /**
053: * Gets the documentNumber attribute.
054: *
055: * @return Returns the documentNumber
056: */
057: public String getDocumentNumber() {
058: return documentNumber;
059: }
060:
061: /**
062: * Sets the documentNumber attribute.
063: *
064: * @param documentNumber The documentNumber to set.
065: */
066: public void setDocumentNumber(String documentNumber) {
067: this .documentNumber = documentNumber;
068: }
069:
070: /**
071: * Gets the financialDocumentLineTypeCode attribute.
072: *
073: * @return Returns the financialDocumentLineTypeCode
074: */
075: public String getFinancialDocumentLineTypeCode() {
076: return financialDocumentLineTypeCode;
077: }
078:
079: /**
080: * Sets the financialDocumentLineTypeCode attribute.
081: *
082: * @param financialDocumentLineTypeCode The financialDocumentLineTypeCode to set.
083: */
084: public void setFinancialDocumentLineTypeCode(
085: String financialDocumentLineTypeCode) {
086: this .financialDocumentLineTypeCode = financialDocumentLineTypeCode;
087: }
088:
089: /**
090: * Gets the financialDocumentLineNumber attribute.
091: *
092: * @return Returns the financialDocumentLineNumber
093: */
094: public Integer getFinancialDocumentLineNumber() {
095: return financialDocumentLineNumber;
096: }
097:
098: /**
099: * Sets the financialDocumentLineNumber attribute.
100: *
101: * @param financialDocumentLineNumber The financialDocumentLineNumber to set.
102: */
103: public void setFinancialDocumentLineNumber(
104: Integer financialDocumentLineNumber) {
105: this .financialDocumentLineNumber = financialDocumentLineNumber;
106: }
107:
108: /**
109: * Gets the chartOfAccountsCode attribute.
110: *
111: * @return Returns the chartOfAccountsCode
112: */
113: public String getChartOfAccountsCode() {
114: return chartOfAccountsCode;
115: }
116:
117: /**
118: * Sets the chartOfAccountsCode attribute.
119: *
120: * @param chartOfAccountsCode The chartOfAccountsCode to set.
121: */
122: public void setChartOfAccountsCode(String chartOfAccountsCode) {
123: this .chartOfAccountsCode = chartOfAccountsCode;
124: }
125:
126: /**
127: * Gets the accountNumber attribute.
128: *
129: * @return Returns the accountNumber
130: */
131: public String getAccountNumber() {
132: return accountNumber;
133: }
134:
135: /**
136: * Sets the accountNumber attribute.
137: *
138: * @param accountNumber The accountNumber to set.
139: */
140: public void setAccountNumber(String accountNumber) {
141: this .accountNumber = accountNumber;
142: }
143:
144: /**
145: * Gets the financialDocumentGrossSalesAmount attribute.
146: *
147: * @return Returns the financialDocumentGrossSalesAmount
148: */
149: public KualiDecimal getFinancialDocumentGrossSalesAmount() {
150: return financialDocumentGrossSalesAmount;
151: }
152:
153: /**
154: * Sets the financialDocumentGrossSalesAmount attribute.
155: *
156: * @param financialDocumentGrossSalesAmount The financialDocumentGrossSalesAmount to set.
157: */
158: public void setFinancialDocumentGrossSalesAmount(
159: KualiDecimal financialDocumentGrossSalesAmount) {
160: this .financialDocumentGrossSalesAmount = financialDocumentGrossSalesAmount;
161: }
162:
163: /**
164: * Gets the financialDocumentTaxableSalesAmount attribute.
165: *
166: * @return Returns the financialDocumentTaxableSalesAmount
167: */
168: public KualiDecimal getFinancialDocumentTaxableSalesAmount() {
169: return financialDocumentTaxableSalesAmount;
170: }
171:
172: /**
173: * Sets the financialDocumentTaxableSalesAmount attribute.
174: *
175: * @param financialDocumentTaxableSalesAmount The financialDocumentTaxableSalesAmount to set.
176: */
177: public void setFinancialDocumentTaxableSalesAmount(
178: KualiDecimal financialDocumentTaxableSalesAmount) {
179: this .financialDocumentTaxableSalesAmount = financialDocumentTaxableSalesAmount;
180: }
181:
182: /**
183: * Gets the financialDocumentSaleDate attribute.
184: *
185: * @return Returns the financialDocumentSaleDate
186: */
187: public Date getFinancialDocumentSaleDate() {
188: return financialDocumentSaleDate;
189: }
190:
191: /**
192: * Sets the financialDocumentSaleDate attribute.
193: *
194: * @param financialDocumentSaleDate The financialDocumentSaleDate to set.
195: */
196: public void setFinancialDocumentSaleDate(
197: Date financialDocumentSaleDate) {
198: this .financialDocumentSaleDate = financialDocumentSaleDate;
199: }
200:
201: /**
202: * Gets the account attribute.
203: *
204: * @return Returns the account
205: */
206: public Account getAccount() {
207: return account;
208: }
209:
210: /**
211: * Sets the account attribute.
212: *
213: * @param account The account to set.
214: * @deprecated
215: */
216: public void setAccount(Account account) {
217: this .account = account;
218: }
219:
220: /**
221: * Gets the chartOfAccounts attribute.
222: *
223: * @return Returns the chartOfAccounts
224: */
225: public Chart getChartOfAccounts() {
226: return chartOfAccounts;
227: }
228:
229: /**
230: * Sets the chartOfAccounts attribute.
231: *
232: * @param chartOfAccounts The chartOfAccounts to set.
233: * @deprecated
234: */
235: public void setChartOfAccounts(Chart chartOfAccounts) {
236: this .chartOfAccounts = chartOfAccounts;
237: }
238:
239: /**
240: * @see org.kuali.core.bo.BusinessObjectBase#toStringMapper()
241: */
242: protected LinkedHashMap toStringMapper() {
243: LinkedHashMap m = new LinkedHashMap();
244: m
245: .put(KFSPropertyConstants.DOCUMENT_NUMBER,
246: this .documentNumber);
247: m.put("financialDocumentLineTypeCode",
248: this .financialDocumentLineTypeCode);
249: if (this .financialDocumentLineNumber != null) {
250: m.put("financialDocumentLineNumber",
251: this.financialDocumentLineNumber.toString());
252: }
253: return m;
254: }
255: }
|