No new promotions will be applied to an exchange order. New promotions include all promotions available to the shopper for their next new order checkout. Promotions that were applied to the original purchase can still be applied to the exchange order. For example, a promotion that is “buy X and get Y free” will still be applied if Y is exchanged for another Y.

However, once a promotion no longer applies to the order it cannot be applied on subsequent exchanges. For example, a promotion that is “buy X and get Y free” will not be applied if Y is exchanged for Z, and then Z is exchanged for Y. The system calculates and saves the changes in the promotion value within the ReturnRequest. This value is also saved in the repository with the return request item.

Applying Item Level Promotions

The ItemPricingEngine configuration contains the ExchangeItemAdjustmentCalculator item pricing calculator. This calculator adjusts the ItemPriceInfo of an item in the Exchange Order based on pricing of the corresponding item in the PEO and copies that information from the PEO to the ItemPriceInfo created for the exchange item. This includes the amount, all PricingAdjustments and DetailedItemPricingInfos. This prices the item in the Exchange Order with the exact pricing it received in the PEO, including any item level promotions that may have been applied.

The ExchangeItemAdjustmentCalculator, an extension of ItemPriceCalculator, uses the priceItem method only when an exchange item is being priced.

Calculating Order Promotion and Manual Adjustment Values

To apply value of order promotions and manual adjustments, Commerce Service Center calculates the value of each order promotion and manual adjustment of the replacement items in the Promotion Evaluation Order to produce value maps. The value maps connect an order promotion ID or manual adjustment ID to its value applied to the replacement items in the Promotion Evaluation Order.

An order promotion’s value is calculated using the ratio of the total replacement item amount to the Promotion Evaluation Order’s raw subtotal. The promotion’s total discount value in the Promotion Evaluation Order is then multiplied by the calculated ratio to determine the value of the promotion applied to the replacement items. The values are obtained as follows:

Value

Description

totalOrderDiscountsOn
ReplacementItems

Is the sum of order discount share on all exchange items in the Promotions Evaluation Order

orderPromotionTotalDiscount

Is the sum of all PricingAdjustments that reference the promotion

totalExchangeItemAmount

Equals the total amount of the exchange item only

double totalDiscountRatio

Equals the totalExchangeItemAmount divided by peoOrder.getPriceInfo().getRawSubtotal()

double promotionDiscountValue

Equals the totalOrderDiscountsOnReplacementItems times the totalDisountRatio

A manual adjustment’s value is calculated using the ratio of the total replacement item amount to the order raw subtotal. The manual adjustment total value is then multiplied by the calculated ratio to determine the value of the manual adjustment applied to the replacement items.

Value

Description

totalAdjustmentsOnReplacementItems

Is the sum of manual adjustment share on all exchange items in the Promotion Evaluation Order

adjustmentTotalValue

Is the sum of PricingAdjustments that reference the manual adjustment

totalExchangeItemAmount

Equals the total amount of the exchange items only

double totalAdjustmentRatio

Equals the totalExchangeItemAmount divided by the peoOrder.getPriceInfo().getRawSubtotal()

double adjustmentValue

Equals the adjustmentTotalValue times the totalAdjustmentRatio

If manual adjustments are applied to the Promotion Evaluation Order, they are applied to the exchange order by the OrderPricingEngine’s post calculator OrderAdjustmentCalculator. This calculator implements priceOrder to trigger the calculation or the manual adjustment value map when pricing an Exchange Order, then determines if manual adjustments should be applied to the exchange order. If necessary, the calculator overrides the adjustOrderSubTotal to adjust the order subtotal based on the pre-calculated value of each manual adjustment.

Agent Price Overrides

Exchange Order price overrides are copied from the Exchange Order into the Promotion Evaluation Order because they affect how promotions are applied within the Promotion Evaluation Order. Overrides in the Exchange Order are applied to the items prior to executing the promotion evaluation process. When exchange items and shipping groups are copied to the Promotion Evaluation Order, if the Exchange Order item is marked as final by the agent, it will also be marked as final in the Promotion Evaluation Order with the same amount, preserving the final price for the Promotion Evaluation Order pricing operation.


Copyright © 1997, 2012 Oracle and/or its affiliates. All rights reserved. Legal Notices