Package com.skava.promotion.ecomm.action
Class ProductPersonalizationOffer
java.lang.Object
com.skava.promotion.action.BasePromotionAction
com.skava.promotion.ecomm.action.EcommBasePromotionAction
com.skava.promotion.ecomm.action.AbstractProductOfferAction
com.skava.promotion.ecomm.action.ProductPersonalizationOffer
- All Implemented Interfaces:
PromotionAction
This class contains the functionalities for Product personalization offer type
.- Since:
- 8.0
- Version:
- 8.0
- Author:
- Infosys Equinox
-
Field Summary
FieldsFields inherited from class com.skava.promotion.ecomm.action.AbstractProductOfferAction
filteredObjects, OFFER_SKU_KEYFields inherited from class com.skava.promotion.ecomm.action.EcommBasePromotionAction
DEAL_ITEM_CONSUMABLE, DISCOUNT_TYPE_EACH, DISCOUNT_TYPE_FLAT, DISCOUNT_TYPE_PARAM, DISCOUNT_TYPE_VALUE, OFFER_EXPENSIVE_TYPE_LEAST, OFFER_EXPENSIVE_TYPE_MOST, offerAbleBundle, offerAbleSkuFields inherited from class com.skava.promotion.action.BasePromotionAction
ADDITIONAL_OFFER_INFO, ALLOW_NEGATIVE_VALUE, CURRENCY_OFFER, FIXED_OFFER, FORMULA, MAX_DISCOUNT_AMOUNT, MIN_DISCOUNT_AMOUNT, OFFER_VALUE, PERCENTAGE_OFFER -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidapplyOffer(PromotionOfferDO promotionOfferDO, PromotionDO promotion) This method provides functionality to apply offerprotected voidgetOffer(PromotionOfferDO promotionOfferDO, PromotionDO promotion, PromotionSku sku) This method provides functionality to get offerprotected doubleFunctionalities to calculate total unitPrice/ShippingCost for current batchprotected voidgetTotalPriceForCurrentBatch(Map<String, Object> priceFacets) Functionalities to calculate total unitPrice/ShippingCost for current batchprotected doubleFunctionalities to calculate total unitPrice/ShippingCost per batchprotected voidgetTotalPricePerBatch(List<PromotionSku> skus, Map<String, Object> priceFacets) Functionalities to calculate total unitPrice/ShippingCost per batchprotected static doublegetUpdatedPersonalizationPrice(int quantityIndex, double price, List<PromotionOffer> offers, String type) This method provides functionality to get the updated personalization priceMethods inherited from class com.skava.promotion.ecomm.action.AbstractProductOfferAction
applyAction, getExpensiveType, prepareApplyAction, processOffer, removefilteredObjectsMethods inherited from class com.skava.promotion.ecomm.action.EcommBasePromotionAction
bundleClone, bundleProductClone, calculatAndGetUpdatedPriceFacetsValue, calculatAndGetUpdatedPriceFacetsValue, calculatAndGetUpdatedPriceFacetsValue, calculatAndGetUpdatedPriceFacetsValue, calculatAndGetUpdatedPriceFacetValue, calculateBundleOffer, calculateBundleOffer, calculateDiscount, calculateOffer, calculateOffer, calculatePriceFacetsOffer, calculatePriceFacetsOfferForBundleProduct, calculateTotalBundlePriceFacets, calculateTotalBundlePriceFacetsQtyFractional, calculateTotalPrice, calculateTotalPriceBundle, calculateTotalPriceBundleQtyFractional, calculateTotalPriceFacets, calculateTotalPriceFacetsQtyFractional, calculateTotalPriceQtyFractional, calibrateDiscount, calibrateDiscount2, checkForBestOffer, clone, findBestBundlePriceOffer, findBestProductPriceOffer, getBaseOffers, getBundleTotalQuantity, getBundleTotalQuantityFractional, getDiscountType, getEachDiscountQtyVal, getEcommOffer, getFlatDiscount, getTotalQuantity, getTotalQuantity, getTotalQuantityFractional, getTotalQuantityFractional, getUpdatedPrice, getUpdatedPriceFacetsValue, getUpdatedShippingCost, promotionSkuClone, removeCompletedBatchBundles, removeCompletedBatchBundles, removeCompletedBatchBundles, removeCompletedBatchBundles, removeCompletedBatchSkus, removeCompletedBatchSkus, setGiftQuantity, setGiftQuantity, setMatchedSkuId, setOffer, setOfferAbleBundles, setOfferAbleSkus, setOfferAbleSkus, sort, sortBundle, updateQuantiyBasedDiscount, updateUnitQuantiyBasedDiscountMethods inherited from class com.skava.promotion.action.BasePromotionAction
createOffer, getAdditionalOfferInfo, getAllowedDiscount, getDiscount, getDiscountForPercentOffer, getDouble, getFormulaDiscount, getFormulaResult, getMaximumDiscount, getMinimumDiscount, getMinValue, getOfferId, getOfferValue, getPercentageDiscount, getPriceFacetDiscount, hasValueForProperty, isOfferExist, onFinish, prepareApplyAction
-
Field Details
-
PERSONALIZATION_TYPE
- See Also:
-
-
Constructor Details
-
ProductPersonalizationOffer
public ProductPersonalizationOffer()
-
-
Method Details
-
getUpdatedPersonalizationPrice
protected static double getUpdatedPersonalizationPrice(int quantityIndex, double price, List<PromotionOffer> offers, String type) This method provides functionality to get the updated personalization price- Parameters:
quantityIndex- quantity index of the offerprice- price of the productoffers- An instance ofList<PromotionOffer>type- Holds the type value- Returns:
- Returns the unit price of the product
-
applyOffer
Description copied from class:AbstractProductOfferActionThis method provides functionality to apply offer- Specified by:
applyOfferin classAbstractProductOfferAction- Parameters:
promotionOfferDO- An instance ofPromotionOfferDOpromotion- An instance ofPromotionDO
-
getOffer
Description copied from class:AbstractProductOfferActionThis method provides functionality to get offer- Specified by:
getOfferin classAbstractProductOfferAction- Parameters:
promotionOfferDO- An instance ofPromotionOfferDOpromotion- An instance ofPromotionDOsku- An instance ofPromotionSku
-
getTotalPriceForCurrentBatch
protected double getTotalPriceForCurrentBatch()Description copied from class:AbstractProductOfferActionFunctionalities to calculate total unitPrice/ShippingCost for current batch- Specified by:
getTotalPriceForCurrentBatchin classAbstractProductOfferAction- Returns:
- return totalPrice in double
-
getTotalPricePerBatch
Description copied from class:AbstractProductOfferActionFunctionalities to calculate total unitPrice/ShippingCost per batch- Specified by:
getTotalPricePerBatchin classAbstractProductOfferAction- Parameters:
skus- An instance ofList<PromotionSku- Returns:
- return totalPrice in double
-
getTotalPriceForCurrentBatch
Description copied from class:AbstractProductOfferActionFunctionalities to calculate total unitPrice/ShippingCost for current batch- Specified by:
getTotalPriceForCurrentBatchin classAbstractProductOfferAction- Parameters:
priceFacets- contains priceFacets
-
getTotalPricePerBatch
Description copied from class:AbstractProductOfferActionFunctionalities to calculate total unitPrice/ShippingCost per batch- Specified by:
getTotalPricePerBatchin classAbstractProductOfferAction- Parameters:
skus- An instance ofList<PromotionSkupriceFacets- contains priceFacets
-