Class Mage_Catalog_Model_Product_Option_Type_Default

Description

Catalog product option default type

Located in /Catalog/Model/Product/Option/Type/Default.php (line 34)

Varien_Object
   |
   --Mage_Catalog_Model_Product_Option_Type_Default
Direct descendents
Class Description
Mage_Catalog_Model_Product_Option_Type_Select Catalog product option select type
Mage_Catalog_Model_Product_Option_Type_File Catalog product option file type
Mage_Catalog_Model_Product_Option_Type_Text Catalog product option text type
Mage_Catalog_Model_Product_Option_Type_Date Catalog product option date type
Variable Summary
Method Summary
Variables

Option Instance

  • access: protected
Mage_Catalog_Model_Product $_product (line 48)

Product Instance

  • access: protected
mixed $_productOptions = array() (line 57)

description

  • access: protected
Methods
getConfigData (line 193)

Store Config value

  • access: public
string getConfigData (string $key)
  • string $key: Config value key
getConfigurationItem (line 148)

Getter for Configuration Item

  • access: public
getConfigurationItemOption (line 116)

Getter for Configuration Item Option

  • access: public
getCustomizedView (line 273)

Return option html

  • access: public
string getCustomizedView (array $optionInfo)
  • array $optionInfo

Redefined in descendants as:
getEditableOptionValue (line 296)

Return formatted option value ready to edit, ready to parse (ex: Admin re-order, see Mage_Adminhtml_Model_Sales_Order_Create)

  • access: public
string getEditableOptionValue (string $optionValue)
  • string $optionValue: Prepared for cart option value

Redefined in descendants as:
getFormattedOptionValue (line 262)

Return formatted option value for quote option

  • access: public
string getFormattedOptionValue (string $optionValue)
  • string $optionValue: Prepared for cart option value

Redefined in descendants as:
getOption (line 77)

Option Instance getter

  • throws: Mage_Core_Exception
  • access: public
getOptionPrice (line 331)

Return Price for selected option

  • access: public
float getOptionPrice (string $optionValue, float $basePrice)
  • string $optionValue: Prepared for cart option value
  • float $basePrice: For percent price type

Redefined in descendants as:
getOptionSku (line 349)

Return SKU for selected option

  • access: public
string getOptionSku (string $optionValue, string $skuDelimiter)
  • string $optionValue: Prepared for cart option value
  • string $skuDelimiter: Delimiter for Sku parts

Redefined in descendants as:
getPrintableOptionValue (line 284)

Return printable option value

  • access: public
string getPrintableOptionValue (string $optionValue)
  • string $optionValue: Prepared for cart option value

Redefined in descendants as:
getProduct (line 103)

Product Instance getter

  • throws: Mage_Core_Exception
  • access: public
getProductOptions (line 359)

Return value => key all product options (using for parsing)

  • return: Array of Product custom options, reversing option values and option ids
  • access: public
array getProductOptions ()
getQuoteItem (line 169)

Getter for Quote Item Deprecated in favor of getConfigurationItem()

  • deprecated: after 1.4.2.0
  • access: public
Mage_Sales_Model_Quote_Item getQuoteItem ()
getQuoteItemOption (line 138)

Getter for Quote Item Option Deprecated in favor of getConfigurationItemOption()

  • deprecated: after 1.4.2.0
  • access: public
Mage_Sales_Model_Quote_Item_Option getQuoteItemOption ()
getRequest (line 179)

Getter for Buy Request

  • access: public
Varien_Object getRequest ()
getSkipCheckRequiredOption (line 226)

Check skip required option validation

  • access: public
bool getSkipCheckRequiredOption ()
isCustomizedView (line 251)

Flag to indicate that custom option has own customized output (blocks, native html etc.)

  • access: public
boolean isCustomizedView ()

Redefined in descendants as:
parseOptionValue (line 308)

Parse user input value and return cart prepared value, i.e. "one, two" => "1,2"

  • access: public
string|null parseOptionValue (string $optionValue, array $productOptionValues)
  • string $optionValue
  • array $productOptionValues: Values for product option

Redefined in descendants as:
prepareForCart (line 238)

Prepare option value for cart

  • return: Prepared option value
  • throws: Mage_Core_Exception
  • access: public
mixed prepareForCart ()

Redefined in descendants as:
prepareOptionValueForRequest (line 319)

Prepare option value for info buy request

  • access: public
mixed prepareOptionValueForRequest (string $optionValue)
  • string $optionValue

Redefined in descendants as:
setOption (line 65)

Option Instance setter

  • access: public
setProduct (line 91)

Product Instance setter

  • access: public
validateUserValue (line 205)

Validate user input for option

  • throws: Mage_Core_Exception
  • access: public
Mage_Catalog_Model_Product_Option_Type_Default validateUserValue (array $values)
  • array $values: All product option values, i.e. array (option_id => mixed, option_id => mixed...)

Redefined in descendants as:
_getChargableOptionPrice (line 391)

Return final chargable price for option

  • access: protected
float _getChargableOptionPrice (float $price, boolean $isPercent, float $basePrice)
  • float $price: Price of option
  • boolean $isPercent: Price type - percent or fixed
  • float $basePrice: For percent price type

Documentation generated on Fri, 11 Feb 2011 17:01:03 +0200 by phpDocumentor 1.4.3