001 /* 002 * Copyright 2011 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 package org.kuali.kfs.module.ar.report.util; 017 018 import java.math.BigDecimal; 019 020 import org.kuali.kfs.module.ar.businessobject.CustomerCreditMemoDetail; 021 import org.kuali.kfs.module.ar.businessobject.CustomerInvoiceDetail; 022 import org.kuali.rice.kns.util.KualiDecimal; 023 024 public class CustomerCreditMemoDetailReportDataHolder { 025 026 private BigDecimal creditMemoItemQuantity; 027 private String creditMemoItemUnitOfMeasureCode; 028 private String creditMemoItemDescription; 029 private String creditMemoItemCode; 030 private KualiDecimal creditMemoItemUnitPrice; 031 private KualiDecimal creditMemoItemTaxAmount; 032 private KualiDecimal creditMemoItemTotalAmount; 033 034 public CustomerCreditMemoDetailReportDataHolder(CustomerCreditMemoDetail cmDetail, CustomerInvoiceDetail iDetail) { 035 creditMemoItemQuantity = cmDetail.getCreditMemoItemQuantity(); 036 creditMemoItemUnitOfMeasureCode = iDetail.getInvoiceItemUnitOfMeasureCode(); 037 creditMemoItemDescription = iDetail.getInvoiceItemDescription(); 038 creditMemoItemCode = iDetail.getInvoiceItemCode(); 039 creditMemoItemUnitPrice = new KualiDecimal(iDetail.getInvoiceItemUnitPrice()); 040 creditMemoItemTaxAmount = cmDetail.getCreditMemoItemTaxAmount(); 041 creditMemoItemTotalAmount = cmDetail.getCreditMemoLineTotalAmount(); 042 } 043 044 /** 045 * Gets the creditMemoItemQuantity attribute. 046 * @return Returns the creditMemoItemQuantity. 047 */ 048 public BigDecimal getCreditMemoItemQuantity() { 049 return creditMemoItemQuantity; 050 } 051 052 /** 053 * Sets the creditMemoItemQuantity attribute value. 054 * @param creditMemoItemQuantity The creditMemoItemQuantity to set. 055 */ 056 public void setCreditMemoItemQuantity(BigDecimal creditMemoItemQuantity) { 057 this.creditMemoItemQuantity = creditMemoItemQuantity; 058 } 059 060 /** 061 * Gets the creditMemoItemUnitOfMeasureCode attribute. 062 * @return Returns the creditMemoItemUnitOfMeasureCode. 063 */ 064 public String getCreditMemoItemUnitOfMeasureCode() { 065 return creditMemoItemUnitOfMeasureCode; 066 } 067 068 /** 069 * Sets the creditMemoItemUnitOfMeasureCode attribute value. 070 * @param creditMemoItemUnitOfMeasureCode The creditMemoItemUnitOfMeasureCode to set. 071 */ 072 public void setCreditMemoItemUnitOfMeasureCode(String creditMemoItemUnitOfMeasureCode) { 073 this.creditMemoItemUnitOfMeasureCode = creditMemoItemUnitOfMeasureCode; 074 } 075 076 /** 077 * Gets the creditMemoItemDescription attribute. 078 * @return Returns the creditMemoItemDescription. 079 */ 080 public String getCreditMemoItemDescription() { 081 return creditMemoItemDescription; 082 } 083 084 /** 085 * Sets the creditMemoItemDescription attribute value. 086 * @param creditMemoItemDescription The creditMemoItemDescription to set. 087 */ 088 public void setCreditMemoItemDescription(String creditMemoItemDescription) { 089 this.creditMemoItemDescription = creditMemoItemDescription; 090 } 091 092 /** 093 * Gets the creditMemoItemCode attribute. 094 * @return Returns the creditMemoItemCode. 095 */ 096 public String getCreditMemoItemCode() { 097 return creditMemoItemCode; 098 } 099 100 /** 101 * Sets the creditMemoItemCode attribute value. 102 * @param creditMemoItemCode The creditMemoItemCode to set. 103 */ 104 public void setCreditMemoItemCode(String creditMemoItemCode) { 105 this.creditMemoItemCode = creditMemoItemCode; 106 } 107 108 /** 109 * Gets the creditMemoItemUnitPrice attribute. 110 * @return Returns the creditMemoItemUnitPrice. 111 */ 112 public KualiDecimal getCreditMemoItemUnitPrice() { 113 return creditMemoItemUnitPrice; 114 } 115 116 /** 117 * Sets the creditMemoItemUnitPrice attribute value. 118 * @param creditMemoItemUnitPrice The creditMemoItemUnitPrice to set. 119 */ 120 public void setCreditMemoItemUnitPrice(KualiDecimal creditMemoItemUnitPrice) { 121 this.creditMemoItemUnitPrice = creditMemoItemUnitPrice; 122 } 123 124 /** 125 * Gets the creditMemoItemTaxAmount attribute. 126 * @return Returns the creditMemoItemTaxAmount. 127 */ 128 public KualiDecimal getCreditMemoItemTaxAmount() { 129 return creditMemoItemTaxAmount; 130 } 131 132 /** 133 * Sets the creditMemoItemTaxAmount attribute value. 134 * @param creditMemoItemTaxAmount The creditMemoItemTaxAmount to set. 135 */ 136 public void setCreditMemoItemTaxAmount(KualiDecimal creditMemoItemTaxAmount) { 137 this.creditMemoItemTaxAmount = creditMemoItemTaxAmount; 138 } 139 140 /** 141 * Gets the creditMemoItemTotalAmount attribute. 142 * @return Returns the creditMemoItemTotalAmount. 143 */ 144 public KualiDecimal getCreditMemoItemTotalAmount() { 145 return creditMemoItemTotalAmount; 146 } 147 148 /** 149 * Sets the creditMemoItemTotalAmount attribute value. 150 * @param creditMemoItemTotalAmount The creditMemoItemTotalAmount to set. 151 */ 152 public void setCreditMemoItemTotalAmount(KualiDecimal creditMemoItemTotalAmount) { 153 this.creditMemoItemTotalAmount = creditMemoItemTotalAmount; 154 } 155 }