AverageOrderTotal
- Type
- Class
- Namespace
- craft\commerce\stats
- Inherits
- craft\commerce\stats\AverageOrderTotal ยป craft\commerce\base\Stat
- Implements
- craft\commerce\base\StatInterface
- Uses traits
- craft\commerce\base\StatTrait
- Since
- 3.0
Average Order Total Stat
View source (opens new window)
# Public Properties
Property | Description |
---|---|
cache | boolean (opens new window) |
cacheDuration | integer (opens new window) โ How long to cache the data, in seconds. |
dateRange | string (opens new window), null (opens new window) |
weekStartDay | integer (opens new window) |
# Protected Properties
Property | Description |
---|---|
_handle | string (opens new window) |
# _handle
- Type
- string (opens new window)
- Default value
'averageOrderTotal'
View source (opens new window)
# Public Methods
Method | Description |
---|---|
__construct() | Stat constructor. |
get() | |
getChartQueryOptionsByInterval() | |
getData() | |
getDateRangeInterval() | |
getDateRangeWording() | |
getEndDate() | |
getHandle() | |
getOrderStatuses() | |
getStartDate() | |
prepareData() | |
setEndDate() | |
setOrderStatuses() | Set order statuses to limit stat query. Accepts array of OrderStatus models, handle strings or uid strings. |
setStartDate() |
# getData()
View source (opens new window)
Returns
mixed
# Protected Methods
Method | Description |
---|---|
_createChartQuery() | |
_createStatQuery() | Generate base stat query |
โ Webhooks NewCustomers โ