SilverCommerce\Reports\Items\DiscountUsageItem
Synopsis
class DiscountUsageItem
extends ViewableData
{
- // members
- private $code;
- private DateTime $start_date;
- private DateTime $end_date;
- private static array $casting = ;
- // methods
- public void getTitle()
- public int getDiscountValue()
- public void getCodeUses()
- public int getInvoiceCount()
- public int getInvoiceSubTotal()
- public int getInvoiceTax()
- protected Discount getDiscount()
- protected DataList getAppliedDiscounts()
- protected DataList getInvoices()
- public void canView()
- public string getCode()
- public DiscountUsageItem setCode()
- public DateTime getStartDate()
- public DiscountUsageItem setStartDate()
- public DateTime getEndDate()
- public DiscountUsageItem setEndDate()
Hierarchy
Extends
- SilverStripe\View\ViewableData
Members
private
Methods
protected
- getAppliedDiscounts() — Get a list of all applied discounts for the selected invoices
- getDiscount() — Return the applicable discount for this code
- getInvoices() — Get the invoices for this contact (within the set timeframe)
public
- canView()
- getCode() — Get the discount code for this item
- getCodeUses() — Get the total number of uses for this code
- getDiscountValue() — Get the total number of invoices applicable for this report
- getEndDate() — Get end date for this item
- getInvoiceCount() — Get the total number of invoices applicable for this report
- getInvoiceSubTotal() — Get the total number of invoices applicable for this report
- getInvoiceTax() — Get the total number of invoices applicable for this report
- getStartDate() — Get start date for this item
- getTitle()
- setCode() — Set the discount code assigned to this item
- setEndDate() — Set end date for this item
- setStartDate() — Set start date for this item