Interface OrderItemPriceDetailAdjustment
- All Superinterfaces:
Adjustment,org.broadleafcommerce.common.copy.MultiTenantCloneable<OrderItemPriceDetailAdjustment>,Serializable
- All Known Implementing Classes:
OrderItemPriceDetailAdjustmentImpl
public interface OrderItemPriceDetailAdjustment
extends Adjustment, org.broadleafcommerce.common.copy.MultiTenantCloneable<OrderItemPriceDetailAdjustment>
Records the actual adjustments that were made to an OrderItemPriceDetail.
- Author:
- bpolster
-
Method Summary
Modifier and TypeMethodDescriptionStores the offer name at the time the adjustment was made.org.broadleafcommerce.common.money.MoneyValue of this adjustment relative to the retail price.org.broadleafcommerce.common.money.MoneyValue of this adjustment relative to the sale price.voidinit(OrderItemPriceDetail orderItemPriceDetail, Offer offer, String reason) booleanEven for items that are on sale, it is possible that an adjustment was made to the retail price that gave the customer a better offer.booleanFuture credit means that the associated adjustment will be discounted at a later time to the customer via a credit.voidsetAppliedToSalePrice(boolean appliedToSalePrice) voidsetFutureCredit(boolean futureCredit) Future credit means that the associated adjustment will be discounted at a later time to the customer via a credit.voidsetOfferName(String offerName) Returns the name of the offer at the time the adjustment was made.voidsetOrderItemPriceDetail(OrderItemPriceDetail orderItemPriceDetail) voidsetRetailPriceValue(org.broadleafcommerce.common.money.Money retailPriceValue) voidsetSalesPriceValue(org.broadleafcommerce.common.money.Money salesPriceValue) Methods inherited from interface org.broadleafcommerce.core.offer.domain.Adjustment
getId, getOffer, getReason, getValue, setId, setReason, setValueMethods inherited from interface org.broadleafcommerce.common.copy.MultiTenantCloneable
createOrRetrieveCopyInstance
-
Method Details
-
getOfferName
String getOfferName()Stores the offer name at the time the adjustment was made. Primarily to simplify display within the admin.- Returns:
-
setOfferName
Returns the name of the offer at the time the adjustment was made.- Parameters:
offerName-
-
getOrderItemPriceDetail
OrderItemPriceDetail getOrderItemPriceDetail() -
setOrderItemPriceDetail
-
init
-
isAppliedToSalePrice
boolean isAppliedToSalePrice()Even for items that are on sale, it is possible that an adjustment was made to the retail price that gave the customer a better offer.Since some offers can be applied to the sale price and some only to the retail price, this setting provides the required value.
- Returns:
- true if this adjustment was applied to the sale price
-
setAppliedToSalePrice
void setAppliedToSalePrice(boolean appliedToSalePrice) -
getRetailPriceValue
org.broadleafcommerce.common.money.Money getRetailPriceValue()Value of this adjustment relative to the retail price.- Returns:
-
setRetailPriceValue
void setRetailPriceValue(org.broadleafcommerce.common.money.Money retailPriceValue) -
getSalesPriceValue
org.broadleafcommerce.common.money.Money getSalesPriceValue()Value of this adjustment relative to the sale price.- Returns:
-
setSalesPriceValue
void setSalesPriceValue(org.broadleafcommerce.common.money.Money salesPriceValue) -
isFutureCredit
boolean isFutureCredit()Future credit means that the associated adjustment will be discounted at a later time to the customer via a credit. It is up to the implementor to decide how to achieve this. This field is used to determine if the adjustment originated from an offer marked as FUTURE_CREDIT.See
Offer.getAdjustmentType()for more info- Returns:
-
setFutureCredit
void setFutureCredit(boolean futureCredit) Future credit means that the associated adjustment will be discounted at a later time to the customer via a credit. It is up to the implementor to decide how to achieve this. This field is used to determine if the adjustment originated from an offer marked as FUTURE_CREDIT.See
Offer.getAdjustmentType()for more info- Parameters:
futureCredit-
-