Class SpecificDayDiscountExtender
- Namespace
- Dynamicweb.Ecommerce.Examples.Orders.Discounts
- Assembly
- Dynamicweb.Ecommerce.Examples.dll
The example of an extender which can be used with product and order discounts - if applied the discount will be valid on the specified day only
public class SpecificDayDiscountExtender : DiscountExtenderBase, IDropDownOptions
- Inheritance
-
SpecificDayDiscountExtender
- Implements
- Inherited Members
Constructors
SpecificDayDiscountExtender()
Constructor - sets the favorite day to Tuesday
public SpecificDayDiscountExtender()
Properties
FavoriteDay
[AddInParameter("Favorite day")]
[AddInDescription("Specify which day when this discount applies")]
[AddInParameterEditor(typeof(DropDownParameterEditor), "")]
public string FavoriteDay { get; set; }
Property Value
Methods
DiscountValidForOrder(Order)
If this extender is used for an order discount, it will be checked here
public override bool DiscountValidForOrder(Order order)
Parameters
order
Order
Returns
DiscountValidForProduct(Product)
If this extender is used for a product discount, it will be checked here
public override bool DiscountValidForProduct(Product product)
Parameters
product
Product