Public Member Functions | |
getConfigurableProduct () | |
getChildProduct () | |
getProductThumbnail () | |
getProductName () | |
getProductUrl () | |
getProductAttributes () | |
getOptionList () | |
Public Attributes | |
const | CONFIGURABLE_PRODUCT_IMAGE = 'checkout/cart/configurable_product_image' |
const | USE_PARENT_IMAGE = 'parent' |
Definition at line 34 of file Configurable.php.
getChildProduct | ( | ) |
Get item configurable child product
Definition at line 57 of file Configurable.php.
00058 { 00059 if ($option = $this->getItem()->getOptionByCode('simple_product')) { 00060 return $option->getProduct(); 00061 } 00062 return $this->getProduct(); 00063 }
getConfigurableProduct | ( | ) |
Get item configurable product
Definition at line 44 of file Configurable.php.
00045 { 00046 if ($option = $this->getItem()->getOptionByCode('product_type')) { 00047 return $option->getProduct(); 00048 } 00049 return $this->getProduct(); 00050 }
getOptionList | ( | ) |
Get list of all otions for product
Reimplemented from Mage_Checkout_Block_Cart_Item_Renderer.
Definition at line 118 of file Configurable.php.
00119 { 00120 $options = array_merge($this->getProductAttributes(), $this->getProductOptions()); 00121 return $options; 00122 }
getProductAttributes | ( | ) |
Get selected for configurable product attributes
Definition at line 106 of file Configurable.php.
00107 { 00108 $attributes = $this->getProduct()->getTypeInstance(true) 00109 ->getSelectedAttributesInfo($this->getProduct()); 00110 return $attributes; 00111 }
getProductName | ( | ) |
Get item product name
Reimplemented from Mage_Checkout_Block_Cart_Item_Renderer.
Definition at line 86 of file Configurable.php.
00087 { 00088 return $this->getProduct()->getName(); 00089 }
getProductThumbnail | ( | ) |
Get product thumbnail image
Reimplemented from Mage_Checkout_Block_Cart_Item_Renderer.
Definition at line 70 of file Configurable.php.
00071 { 00072 $product = $this->getChildProduct(); 00073 if (!$product || !$product->getData('thumbnail') 00074 || ($product->getData('thumbnail') == 'no_selection') 00075 || (Mage::getStoreConfig(self::CONFIGURABLE_PRODUCT_IMAGE) == self::USE_PARENT_IMAGE)) { 00076 $product = $this->getProduct(); 00077 } 00078 return $this->helper('catalog/image')->init($product, 'thumbnail'); 00079 }
getProductUrl | ( | ) |
Get url to item product
Reimplemented from Mage_Checkout_Block_Cart_Item_Renderer.
Definition at line 96 of file Configurable.php.
00097 { 00098 return $this->getProduct()->getProductUrl(); 00099 }
const CONFIGURABLE_PRODUCT_IMAGE = 'checkout/cart/configurable_product_image' |
Definition at line 36 of file Configurable.php.
const USE_PARENT_IMAGE = 'parent' |
Definition at line 37 of file Configurable.php.