Class Mage_Catalog_Model_Product_Type_Configurable

Description

Configurable product type implementation

This type builds in product attributes and existing simple products

Located in /Catalog/Model/Product/Type/Configurable.php (line 36)

Mage_Catalog_Model_Product_Type_Abstract
   |
   --Mage_Catalog_Model_Product_Type_Configurable
Class Constant Summary
TYPE_CODE = 'configurable'
Variable Summary
Method Summary
bool canUseAttribute ( $attribute)
array getChildrenIds (int $parentId, [bool $required = true])
array getOrderOptions ([Mage_Catalog_Model_Product $product = null])
array getParentIdsByChild (int|array $childId)
Mage_Catalog_Model_Product|null getProductByAttributes ( $attributesInfo, [Mage_Catalog_Model_Product $product = null], array $attrbutesInfo)
Varien_Object getRelationInfo ()
string getSku ([Mage_Catalog_Model_Product $product = null])
array getUsedProductIds ([Mage_Catalog_Model_Product $product = null])
array getUsedProducts ([array $requiredAttributeIds = null], [Mage_Catalog_Model_Product $product = null])
decimal getWeight ([Mage_Catalog_Model_Product $product = null])
bool hasOptions ([Mage_Catalog_Model_Product $product = null])
bool isSalable ([ $product = null])
bool isVirtual ([ $product = null])
array processBuyRequest (Mage_Catalog_Model_Product $product, Varien_Object $buyRequest)
array|string _prepareProduct ( $buyRequest, Mage_Catalog_Model_Product $product, string $processMode)
Variables
bool $_canConfigure = true (line 94)

Product is configurable

  • access: protected

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::$_canConfigure
Is a configurable product type
string $_configurableAttributes = '_cache_instance_configurable_attributes' (line 66)

Cache key for configurable attributes

  • access: protected
bool $_isComposite = true (line 87)

Product is composite

  • access: protected

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::$_isComposite
Is a composite product type
string $_usedAttributes = '_cache_instance_used_attributes' (line 59)

Cache key for Used Attributes

  • access: protected
string $_usedProductAttributeIds = '_cache_instance_used_product_attribute_ids' (line 45)

Cache key for Used Product Attribute Ids

  • access: protected
string $_usedProductAttributes = '_cache_instance_used_product_attributes' (line 52)

Cache key for Used Product Attributes

  • access: protected
string $_usedProductIds = '_cache_instance_product_ids' (line 73)

Cache key for Used product ids

  • access: protected
string $_usedProducts = '_cache_instance_products' (line 80)

Cache key for used products

  • access: protected

Inherited Variables

Inherited from Mage_Catalog_Model_Product_Type_Abstract

Mage_Catalog_Model_Product_Type_Abstract::$_canUseQtyDecimals
Mage_Catalog_Model_Product_Type_Abstract::$_editableAttributes
Mage_Catalog_Model_Product_Type_Abstract::$_fileQueue
Mage_Catalog_Model_Product_Type_Abstract::$_product
Mage_Catalog_Model_Product_Type_Abstract::$_setAttributes
Mage_Catalog_Model_Product_Type_Abstract::$_storeFilter
Mage_Catalog_Model_Product_Type_Abstract::$_typeId
Methods
assignProductToOption (line 735)

Implementation of product specify logic of which product needs to be assigned to option.

For example if product which was added to option already removed from catalog.

  • access: public

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::assignProductToOption()
Implementation of product specify logic of which product needs to be assigned to option.
beforeSave (line 382)

Before save process

  • access: public

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::beforeSave()
Before save type related data
canUseAttribute (line 164)

Checkin attribute availability for create superproduct

  • access: public
bool canUseAttribute ( $attribute)
checkProductBuyState (line 612)

Check if product can be bought

  • throws: Mage_Core_Exception
  • access: public
Mage_Catalog_Model_Product_Type_Abstract checkProductBuyState ([Mage_Catalog_Model_Product $product = null])

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::checkProductBuyState()
Check if product can be bought
getChildrenIds (line 120)

Retrieve Required children ids

Return grouped array, ex array( group => array(ids) )

  • access: public
array getChildrenIds (int $parentId, [bool $required = true])
  • int $parentId
  • bool $required

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::getChildrenIds()
Retrieve Required children ids
getConfigurableAttributeCollection (line 289)

Retrieve configurable atrribute collection

  • access: public
getConfigurableAttributes (line 245)

Retrieve configurable attrbutes data

  • access: public
array getConfigurableAttributes ([Mage_Catalog_Model_Product $product = null])
getConfigurableAttributesAsArray (line 264)

Retrieve Configurable Attributes as array

  • access: public
array getConfigurableAttributesAsArray ([Mage_Catalog_Model_Product $product = null])
getEditableAttributes (line 144)

Retrieve product type attributes

  • access: public
array getEditableAttributes ([Mage_Catalog_Model_Product $product = null])

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::getEditableAttributes()
Retrieve product type attributes
getOrderOptions (line 651)

Prepare additional options/information for order item which will be created from this product

  • access: public
array getOrderOptions ([Mage_Catalog_Model_Product $product = null])

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::getOrderOptions()
Prepare additional options/information for order item which will be created from this product
getParentIdsByChild (line 132)

Retrieve parent ids array by requered child

  • access: public
array getParentIdsByChild (int|array $childId)
  • int|array $childId

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::getParentIdsByChild()
Retrieve parent ids array by requered child
getProductByAttributes (line 474)

Retrieve used product by attribute values

$attrbutesInfo = array( $attributeId => $attributeValue )

  • access: public
Mage_Catalog_Model_Product|null getProductByAttributes ( $attributesInfo, [Mage_Catalog_Model_Product $product = null], array $attrbutesInfo)
getProductsToPurchaseByReqGroups (line 754)

Retrieve products divided into groups required to purchase At least one product in each group has to be purchased

  • access: public
array getProductsToPurchaseByReqGroups ([Mage_Catalog_Model_Product $product = null])

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::getProductsToPurchaseByReqGroups()
Retrieve products divided into groups required to purchase At least one product in each group has to be purchased
getRelationInfo (line 101)

Return relation info about used products

  • return: Object with information data
  • access: public
Varien_Object getRelationInfo ()

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::getRelationInfo()
Return relation info about used products for specific type instance
getSelectedAttributesInfo (line 499)

Retrieve Selected Attributes info

  • access: public
array getSelectedAttributesInfo ([Mage_Catalog_Model_Product $product = null])
getSku (line 766)

Get sku of product

  • access: public
string getSku ([Mage_Catalog_Model_Product $product = null])

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::getSku()
Default action to get sku of product
getSpecifyOptionMessage (line 639)

Retrieve message for specify option(s)

  • access: public
string getSpecifyOptionMessage ()

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::getSpecifyOptionMessage()
Retrieve message for specify option(s)
getUsedProductAttributeIds (line 205)

Retrieve identifiers of used product attributes

  • access: public
array getUsedProductAttributeIds ([Mage_Catalog_Model_Product $product = null])
getUsedProductAttributes (line 223)

Retrieve used product attributes

  • access: public
array getUsedProductAttributes ([Mage_Catalog_Model_Product $product = null])
getUsedProductCollection (line 363)

Retrieve related products collection

  • access: public
getUsedProductIds (line 302)

Retrieve subproducts identifiers

  • access: public
array getUsedProductIds ([Mage_Catalog_Model_Product $product = null])
getUsedProducts (line 321)

Retrieve array of "subproducts"

  • access: public
array getUsedProducts ([array $requiredAttributeIds = null], [Mage_Catalog_Model_Product $product = null])
getWeight (line 714)

Return product weight based on simple product weight or configurable product weight

  • access: public
decimal getWeight ([Mage_Catalog_Model_Product $product = null])

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::getWeight()
Default action to get weight of product
hasOptions (line 688)

Return true if product has options

  • access: public
bool hasOptions ([Mage_Catalog_Model_Product $product = null])

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::hasOptions()
Return true if product has options
isSalable (line 447)

Check is product available for sale

  • access: public
bool isSalable ([ $product = null])
  • $product

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::isSalable()
Check is product available for sale
isVirtual (line 671)

Check is virtual product

  • access: public
bool isVirtual ([ $product = null])
  • $product

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::isVirtual()
Check is virtual product
processBuyRequest (line 786)

Prepare selected options for configurable product

  • access: public
array processBuyRequest (Mage_Catalog_Model_Product $product, Varien_Object $buyRequest)

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::processBuyRequest()
Prepare selected options for product
save (line 412)

Save configurable product depended data

  • access: public

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::save()
Save type related data
setUsedProductAttributeIds (line 182)

Declare attribute identifiers used for asign subproducts

  • access: public
Mage_Catalog_Model_Product_Type_Configurable setUsedProductAttributeIds (array $ids, [Mage_Catalog_Model_Product $product = null])
_prepareProduct (line 538)

Prepare product and its configuration to be added to some products list.

Perform standard preparation process and then add Configurable specific options.

  • access: protected
array|string _prepareProduct ( $buyRequest, Mage_Catalog_Model_Product $product, string $processMode)

Redefinition of:
Mage_Catalog_Model_Product_Type_Abstract::_prepareProduct()
Prepare product and its configuration to be added to some products list.

Inherited Methods

Inherited From Mage_Catalog_Model_Product_Type_Abstract

Mage_Catalog_Model_Product_Type_Abstract::addFileQueue()
Mage_Catalog_Model_Product_Type_Abstract::assignProductToOption()
Mage_Catalog_Model_Product_Type_Abstract::attributesCompare()
Mage_Catalog_Model_Product_Type_Abstract::beforeSave()
Mage_Catalog_Model_Product_Type_Abstract::canConfigure()
Mage_Catalog_Model_Product_Type_Abstract::canUseQtyDecimals()
Mage_Catalog_Model_Product_Type_Abstract::checkProductBuyState()
Mage_Catalog_Model_Product_Type_Abstract::checkProductConfiguration()
Mage_Catalog_Model_Product_Type_Abstract::getAttributeById()
Mage_Catalog_Model_Product_Type_Abstract::getChildrenIds()
Mage_Catalog_Model_Product_Type_Abstract::getEditableAttributes()
Mage_Catalog_Model_Product_Type_Abstract::getForceChildItemQtyChanges()
Mage_Catalog_Model_Product_Type_Abstract::getOptionSku()
Mage_Catalog_Model_Product_Type_Abstract::getOrderOptions()
Mage_Catalog_Model_Product_Type_Abstract::getParentIdsByChild()
Mage_Catalog_Model_Product_Type_Abstract::getProduct()
Mage_Catalog_Model_Product_Type_Abstract::getProductsToPurchaseByReqGroups()
Mage_Catalog_Model_Product_Type_Abstract::getRelationInfo()
Mage_Catalog_Model_Product_Type_Abstract::getSearchableData()
Mage_Catalog_Model_Product_Type_Abstract::getSetAttributes()
Mage_Catalog_Model_Product_Type_Abstract::getSku()
Mage_Catalog_Model_Product_Type_Abstract::getSpecifyOptionMessage()
Mage_Catalog_Model_Product_Type_Abstract::getStoreFilter()
Mage_Catalog_Model_Product_Type_Abstract::getWeight()
Mage_Catalog_Model_Product_Type_Abstract::hasOptions()
Mage_Catalog_Model_Product_Type_Abstract::hasRequiredOptions()
Mage_Catalog_Model_Product_Type_Abstract::isComposite()
Mage_Catalog_Model_Product_Type_Abstract::isSalable()
Mage_Catalog_Model_Product_Type_Abstract::isVirtual()
Mage_Catalog_Model_Product_Type_Abstract::prepareForCart()
Mage_Catalog_Model_Product_Type_Abstract::prepareForCartAdvanced()
Mage_Catalog_Model_Product_Type_Abstract::prepareQuoteItemQty()
Mage_Catalog_Model_Product_Type_Abstract::processBuyRequest()
Mage_Catalog_Model_Product_Type_Abstract::processConfiguration()
Mage_Catalog_Model_Product_Type_Abstract::processFileQueue()
Mage_Catalog_Model_Product_Type_Abstract::save()
Mage_Catalog_Model_Product_Type_Abstract::setConfig()
Mage_Catalog_Model_Product_Type_Abstract::setProduct()
Mage_Catalog_Model_Product_Type_Abstract::setStoreFilter()
Mage_Catalog_Model_Product_Type_Abstract::setTypeId()
Mage_Catalog_Model_Product_Type_Abstract::updateQtyOption()
Mage_Catalog_Model_Product_Type_Abstract::_isStrictProcessMode()
Mage_Catalog_Model_Product_Type_Abstract::_prepareOptions()
Mage_Catalog_Model_Product_Type_Abstract::_prepareOptionsForCart()
Mage_Catalog_Model_Product_Type_Abstract::_prepareProduct()
Mage_Catalog_Model_Product_Type_Abstract::_removeNotApplicableAttributes()
Class Constants

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