Class Mage_Sales_Model_Quote
Quote model
Supported events: sales_quote_load_after sales_quote_save_before sales_quote_save_after sales_quote_delete_before sales_quote_delete_after
- Varien_Object
- Mage_Core_Model_Abstract
- Mage_Sales_Model_Quote
Category: Mage
Copyright: Copyright (c) 2012 Magento Inc. (http://www.magentocommerce.com)
License: Open Software License (OSL 3.0)
Author: Magento Core Team <core@magentocommerce.com>
Located at code/core/Mage/Sales/Model/Quote.php
protected
|
|
protected
Varien_Object
|
|
public
integer
|
|
public
|
|
public
|
|
public
array
|
|
protected
|
|
protected
|
|
public
|
|
public
|
|
public
|
|
public
|
#
assignCustomer(
Assign customer model object data to quote |
public
|
#
assignCustomerWithAddressChange(
Assign customer model to quote with billing and shipping address change |
public
|
|
public
|
|
public
integer
|
|
public
|
|
public
|
|
protected
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
array
|
|
public
array
|
|
public
boolean
|
|
public
boolean
|
|
public
boolean
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
#
addProductAdvanced(
Advanced func to add product to quote - processing mode can be specified there. Returns error message if product type instance can't prepare product. |
public
|
#
addProduct(
Add product to quote |
protected
|
#
_addCatalogProduct(
Adding catalog product object data to quote |
public
|
#
updateItem( integer $itemId, Varien_Object $buyRequest, null|array|Varien_Object $params = null )
Updates quote item with new configuration |
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
array
|
|
public
|
|
public
array
|
|
public
array
|
|
protected
|
|
public
|
#
setHasError( boolean $flag )
Sets flag, whether this quote has some error associated with it. When TRUE - also adds 'unknown' error information to list of quote errors. When FALSE - clears whole list of quote errors. It's recommended to use addErrorInfo() instead - to be able to remove error statuses later. |
protected
|
#
_clearErrorInfo( )
Clears list of errors, associated with this quote. Also automatically removes error-flag from oneself. |
public
|
#
addErrorInfo( string $type = 'error', string|null $origin = null, integer|null $code = null, string|null $message = null, Varien_Object|null $additionalData = null )
Adds error information to the quote. Automatically sets error flag. |
public
|
#
removeErrorInfosByParams( string $type = 'error', array $params )
Removes error infos, that have parameters equal to passed in $params. $params
can have following keys (if not set - then any item is good for this key): |
public
|
|
public
|
|
public
|
|
public
boolean
|
|
public
boolean
|
|
public
boolean
|
|
public
|
|
public
boolean
|
|
public
boolean
|
#
hasNominalItems( boolean $countVirtual = true )
Getter whether quote has nominal items Can bypass treating virtual items as nominal |
public
boolean
|
|
public
array
|
|
protected
|
|
protected
|
|
public
|
|
public
|
string |
CHECKOUT_METHOD_GUEST
|
'guest' |
|
string |
CHECKOUT_METHOD_LOGIN_IN
|
'login_in' |
protected
string
|
$_eventPrefix | 'sales_quote' |
#
Prefix of model events names |
protected
string
|
$_eventObject | 'quote' |
#
Parameter name in event |
protected
|
$_customer |
|
#
Quote customer model object |
protected
|
$_addresses | null |
#
Quote addresses collection |
protected
|
$_items | null |
#
Quote items collection |
protected
|
$_payments | null |
#
Quote payments |
protected
array
|
$_errorInfoGroups | array() |
#
Different groups of error infos |
protected
boolean
|
$_preventSaving | false |
#
Whether quote should not be saved |
$_cacheTag,
$_dataSaveAllowed,
$_isObjectNew,
$_resource,
$_resourceCollectionName,
$_resourceName
|