In Release 9.2.1, coupon processing has changed in the Pricing module due to the Mutual Exclusivity feature. The IsExclusive flag is still supported but with a change in behavior.
Instead of the Coupon IsExclusive attribute, you can use the pricing rule attributes ExclusivityId and ExclusivityType.
Previously, coupon exclusivity had a first-come, first-served behavior. For example, if the following coupons were applied to an order in the following sequence, Coupon1 would be applied first:
Example 1:
Coupon1 IsExclusive='Y'
Coupon2 IsExclusive='N'
Coupon3 IsExclusive='N'
In the example above, because Coupon1 was applied first and it is marked as IsExclusive, Coupon2 and Coupon3 would not be applied.
The following example shows that even if the sequence were changed, Coupon1 would be processed first and applied to the order. Then Coupon2 would be processed. Since Coupon1 is already applied and Coupon2 is marked IsExclusive, Coupon2 would not be applied. Next, Coupon3 is processed and applied to the order, because it is not marked IsExclusive. Finally, Coupon4 is processed and skipped over because, like Coupon2, it is marked IsExclusive.
Coupon1 IsExclusive='N'
Coupon2 IsExclusive='Y'
Coupon3 IsExclusvie='N'
Coupon4 IsExclusive='Y'
The change in behavior for this release is that coupons are no longer processed in a first-come first-served manner. Instead, the selection is done by best discount. The "best" IsExclusive coupon is compared against the summed total discount of all the nonexclusive coupons. Using the same previous list of coupons, this new behavior would apply either (Coupon2) or (Coupon4) or (Coupon1, Coupon3). From the three choices, the one that gives the best discount will be applied to the order. The sequence in which the coupons are specified on the order does not matter.
During upgrade, previously existing pricing rule data will be left as is and coupon pricing rules that have the IsExclusive=Y flag set will be treated as ExclusivityType = “Pricing rule cannot combine with pricing rules of the same rule group for the same item.” In addition, pricing rules that have their rule type set to ORDER_TOTAL and their Exclusivity Type set to RULE_TYPE_ITEM will be treated as having Exclusivity Type set to "Pricing rule cannot combine with pricing rules of the same rule group for the same order."
Refer to the Sterling Selling and Fulfillment Foundation: Javadocs for more information about the managePricingRule API.
None.
None.