Class DateTimeDiscount
- Namespace
- Dynamicweb.Ecommerce.Orders.SalesDiscounts
- Assembly
- Dynamicweb.Ecommerce.dll
The class DateTimeDiscount represents SalesDiscountProvider based on date and time conditions.
[AddInName("Date discount")]
[AddInDescription("If the cart/order was created in a specified period a discount will be triggered.")]
[AddInIgnore(true)]
[Obsolete("Sales discount provider is obsolete. Use DiscountExtender and related interfaces instead.")]
public class DateTimeDiscount : SalesDiscountProvider
- Inheritance
-
DateTimeDiscount
- Inherited Members
Properties
DateFrom
Gets or sets date from when discount will be valid.
[AddInParameter("Date from")]
[AddInParameterEditor(typeof(DateTimeParameterEditor), "")]
public DateTime DateFrom { get; set; }
Property Value
Remarks
Default value is
DateTime.Now
DateTo
Gets or sets date to when discount will be valid.
[AddInParameter("Date to")]
[AddInParameterEditor(typeof(DateTimeParameterEditor), "")]
public DateTime DateTo { get; set; }
Property Value
Remarks
Default value is
DateTime.Now.AddDays(1)
Methods
ProcessOrder(Order)
Process the order to apply discount if valid.
public override void ProcessOrder(Order order)
Parameters
order
Order- The order.