Click or drag to resize
DiscountCouponInfoProviderCalculateUnitDiscount Method
Validates discount coupon and calculates shopping cart item unit discount after the discount coupon is applied.

Namespace: CMS.Ecommerce
Assembly: CMS.Ecommerce (in CMS.Ecommerce.dll) Version: 9.0.0
Syntax
C#
public static double CalculateUnitDiscount(
	ShoppingCartItemInfo item,
	DiscountCouponInfo discount,
	double basePrice = 0
)

Parameters

item
Type: CMS.EcommerceShoppingCartItemInfo
Shopping cart item to which the discount coupon should be applied
discount
Type: CMS.EcommerceDiscountCouponInfo
Discount coupon data
basePrice (Optional)
Type: SystemDouble
Price to apply discount to.

Return Value

Type: Double
See Also