Class Mage_Reports_Model_Mysql4_Order_Collection

Description

Reports orders collection

  • author: Magento Core Team <core@magentocommerce.com>
  • copyright: Copyright (c) 2010 Magento Inc. (http://www.magentocommerce.com)

Located in /Reports/Model/Mysql4/Order/Collection.php (line 35)

Varien_Data_Collection_Db
   |
   --Mage_Core_Model_Mysql4_Collection_Abstract
      |
      --Mage_Sales_Model_Mysql4_Collection_Abstract
         |
         --Mage_Sales_Model_Mysql4_Order_Collection
            |
            --Mage_Reports_Model_Mysql4_Order_Collection
Direct descendents
Class Description
Mage_Reports_Model_Mysql4_Customer_Orders_Collection Customers by orders Report collection
Mage_Reports_Model_Mysql4_Customer_Totals_Collection Customers by totals Report collection
Variable Summary
mixed $_isLive
Method Summary
Mage_Reports_Model_Mysql4_Order_Collection addRevenueToSelect ([boolean $convertCurrency = false])
boolean checkIsLive ($range $range)
void getDateRange ( $range,  $customStart,  $customEnd, [ $returnObjects = false])
boolean isLive ()
void orderByCreatedAt ([string $dir = 'desc'])
void orderByCustomerRegistration ([ $dir = 'desc'])
void orderByOrdersCount ([ $dir = 'desc'])
Mage_Reports_Model_Mysql4_Order_Collection prepareSummary (string $range, mixed $customStart, mixed $customEnd, [int $isFilter = 0])
void setDateRange ( $from,  $to)
void _getRangeExpression ( $range)
void _getRangeExpressionForAttribute (string $range, unknown_type $attribute)
Mage_Reports_Model_Mysql4_Order_Collection _prepareSummaryAggregated (string $range, mixed $customStart, mixed $customEnd, int $isFilter)
Mage_Reports_Model_Mysql4_Order_Collection _prepareSummaryLive (string $range, mixed $customStart, mixed $customEnd, [int $isFilter = 0])
Variables
Methods
addCreateAtPeriodFilter (line 618)

Add period filter by created_at attribute

  • access: public
Mage_Reports_Model_Mysql4_Order_Collection addCreateAtPeriodFilter (string $period)
  • string $period
addItemCountExpr (line 245)
  • access: public
void addItemCountExpr ()

Redefinition of:
Mage_Sales_Model_Mysql4_Order_Collection::addItemCountExpr()
Add items count expr to collection select, backward capability with eav structure
addOrdersCount (line 488)

Add Order count field to select

  • access: public
addRevenueToSelect (line 503)

Add revenue

  • access: public
Mage_Reports_Model_Mysql4_Order_Collection addRevenueToSelect ([boolean $convertCurrency = false])
  • boolean $convertCurrency
addSumAvgTotals (line 524)

Add summary average totals

  • access: public
Mage_Reports_Model_Mysql4_Order_Collection addSumAvgTotals ([int $storeId = 0])
  • int $storeId
calculateSales (line 345)

Calculate lifitime sales

  • access: public
Mage_Reports_Model_Mysql4_Order_Collection calculateSales ([int $isFilter = 0])
  • int $isFilter
calculateTotals (line 264)

Calculate totals report

  • access: public
Mage_Reports_Model_Mysql4_Order_Collection calculateTotals ([int $isFilter = 0])
  • int $isFilter
checkIsLive (line 45)

Check range for live mode

  • access: public
boolean checkIsLive ($range $range)
  • $range $range
getDateRange (line 187)
  • access: public
void getDateRange ( $range,  $customStart,  $customEnd, [ $returnObjects = false])
  • $range
  • $customStart
  • $customEnd
  • $returnObjects
getSelectCountSql (line 585)
  • access: public
void getSelectCountSql ()

Redefinition of:
Mage_Sales_Model_Mysql4_Order_Collection::getSelectCountSql()
Minimize usual count select
groupByCustomer (line 465)

Add group By customer attribute

  • access: public
isLive (line 56)

Retrieve is live flag for rep

  • access: public
boolean isLive ()
joinCustomerName (line 477)

Join Customer Name (concat)

  • access: public
Mage_Reports_Model_Mysql4_Order_Collection joinCustomerName ([ $alias = 'name'])
  • $alias
orderByCreatedAt (line 579)

Sort order by order created_at date

  • access: public
void orderByCreatedAt ([string $dir = 'desc'])
  • string $dir
orderByCustomerRegistration (line 569)
  • access: public
void orderByCustomerRegistration ([ $dir = 'desc'])
  • $dir
orderByOrdersCount (line 562)
  • access: public
void orderByOrdersCount ([ $dir = 'desc'])
  • $dir
orderByTotalAmount (line 555)

Sort order by total amount

  • access: public
Mage_Reports_Model_Mysql4_Order_Collection orderByTotalAmount ([string $dir = 'desc'])
  • string $dir
prepareSummary (line 70)

Prepare report summary

  • access: public
Mage_Reports_Model_Mysql4_Order_Collection prepareSummary (string $range, mixed $customStart, mixed $customEnd, [int $isFilter = 0])
  • string $range
  • mixed $customStart
  • mixed $customEnd
  • int $isFilter
setDateRange (line 386)
  • access: public
void setDateRange ( $from,  $to)
  • $from
  • $to

Redefined in descendants as:
setStoreIds (line 431)

Set store filter collection

  • access: public
Mage_Reports_Model_Mysql4_Order_Collection setStoreIds (array $storeIds)
  • array $storeIds

Redefined in descendants as:
_calculateTotalsAggregated (line 315)

Calculate totals agregated report

  • access: protected
Mage_Reports_Model_Mysql4_Order_Collection _calculateTotalsAggregated ([int $isFilter = 0])
  • int $isFilter
_calculateTotalsLive (line 281)

Calculate totals live report

  • access: protected
Mage_Reports_Model_Mysql4_Order_Collection _calculateTotalsLive ([int $isFilter = 0])
  • int $isFilter
_getRangeExpression (line 149)
  • access: protected
void _getRangeExpression ( $range)
  • $range
_getRangeExpressionForAttribute (line 181)

Retriev range exression adapteted for attribute

  • access: protected
void _getRangeExpressionForAttribute (string $range, unknown_type $attribute)
  • string $range
  • unknown_type $attribute
_initInitialFieldsToSelect (line 606)

Initialize initial fields to select

  • access: protected
Mage_Reports_Model_Mysql4_Order_Collection _initInitialFieldsToSelect ()

Redefinition of:
Mage_Core_Model_Mysql4_Collection_Abstract::_initInitialFieldsToSelect()
Initialize initial fields to select like id field
_prepareSummaryAggregated (line 124)

Prepare report summary from aggregated data

  • access: protected
Mage_Reports_Model_Mysql4_Order_Collection _prepareSummaryAggregated (string $range, mixed $customStart, mixed $customEnd, int $isFilter)
  • string $range
  • mixed $customStart
  • mixed $customEnd
  • int $isFilter
_prepareSummaryLive (line 91)

Prepare report summary from live data

  • access: protected
Mage_Reports_Model_Mysql4_Order_Collection _prepareSummaryLive (string $range, mixed $customStart, mixed $customEnd, [int $isFilter = 0])
  • string $range
  • mixed $customStart
  • mixed $customEnd
  • int $isFilter

Inherited Methods

Inherited From Mage_Sales_Model_Mysql4_Order_Collection

Mage_Sales_Model_Mysql4_Order_Collection::addAddressFields()
Mage_Sales_Model_Mysql4_Order_Collection::addAttributeToSearchFilter()
Mage_Sales_Model_Mysql4_Order_Collection::addBillingAgreementsFilter()
Mage_Sales_Model_Mysql4_Order_Collection::addFieldToSearchFilter()
Mage_Sales_Model_Mysql4_Order_Collection::addItemCountExpr()
Mage_Sales_Model_Mysql4_Order_Collection::addRecurringProfilesFilter()
Mage_Sales_Model_Mysql4_Order_Collection::getSelectCountSql()
Mage_Sales_Model_Mysql4_Order_Collection::_addAddressFields()
Mage_Sales_Model_Mysql4_Order_Collection::_construct()
Mage_Sales_Model_Mysql4_Order_Collection::_getAllIdsSelect()

Inherited From Mage_Sales_Model_Mysql4_Collection_Abstract

Mage_Sales_Model_Mysql4_Collection_Abstract::addAttributeToFilter()
Mage_Sales_Model_Mysql4_Collection_Abstract::addAttributeToSelect()
Mage_Sales_Model_Mysql4_Collection_Abstract::addAttributeToSort()
Mage_Sales_Model_Mysql4_Collection_Abstract::getAllIds()
Mage_Sales_Model_Mysql4_Collection_Abstract::joinAttribute()
Mage_Sales_Model_Mysql4_Collection_Abstract::setPage()
Mage_Sales_Model_Mysql4_Collection_Abstract::_attributeToField()
Mage_Sales_Model_Mysql4_Collection_Abstract::_getAllIdsSelect()

Inherited From Mage_Core_Model_Mysql4_Collection_Abstract

Mage_Core_Model_Mysql4_Collection_Abstract::__construct()
Mage_Core_Model_Mysql4_Collection_Abstract::addExpressionFieldToSelect()
Mage_Core_Model_Mysql4_Collection_Abstract::addFieldToSelect()
Mage_Core_Model_Mysql4_Collection_Abstract::getAllIds()
Mage_Core_Model_Mysql4_Collection_Abstract::getMainTable()
Mage_Core_Model_Mysql4_Collection_Abstract::getModelName()
Mage_Core_Model_Mysql4_Collection_Abstract::getResource()
Mage_Core_Model_Mysql4_Collection_Abstract::getResourceModelName()
Mage_Core_Model_Mysql4_Collection_Abstract::getSelect()
Mage_Core_Model_Mysql4_Collection_Abstract::getTable()
Mage_Core_Model_Mysql4_Collection_Abstract::join()
Mage_Core_Model_Mysql4_Collection_Abstract::removeAllFieldsFromSelect()
Mage_Core_Model_Mysql4_Collection_Abstract::removeFieldFromSelect()
Mage_Core_Model_Mysql4_Collection_Abstract::resetItemsDataChanged()
Mage_Core_Model_Mysql4_Collection_Abstract::save()
Mage_Core_Model_Mysql4_Collection_Abstract::setMainTable()
Mage_Core_Model_Mysql4_Collection_Abstract::setModel()
Mage_Core_Model_Mysql4_Collection_Abstract::setResetItemsDataChanged()
Mage_Core_Model_Mysql4_Collection_Abstract::setResourceModel()
Mage_Core_Model_Mysql4_Collection_Abstract::_afterLoad()
Mage_Core_Model_Mysql4_Collection_Abstract::_beforeLoad()
Mage_Core_Model_Mysql4_Collection_Abstract::_canUseCache()
Mage_Core_Model_Mysql4_Collection_Abstract::_construct()
Mage_Core_Model_Mysql4_Collection_Abstract::_getCacheTags()
Mage_Core_Model_Mysql4_Collection_Abstract::_getInitialFieldsToSelect()
Mage_Core_Model_Mysql4_Collection_Abstract::_init()
Mage_Core_Model_Mysql4_Collection_Abstract::_initInitialFieldsToSelect()
Mage_Core_Model_Mysql4_Collection_Abstract::_initSelect()
Mage_Core_Model_Mysql4_Collection_Abstract::_initSelectFields()
Mage_Core_Model_Mysql4_Collection_Abstract::_loadCache()
Mage_Core_Model_Mysql4_Collection_Abstract::_saveCache()
Class Constants

Documentation generated on Fri, 11 Feb 2011 16:58:16 +0200 by phpDocumentor 1.4.3