Public Member Functions | |
getGroupedProduct () | |
getProductThumbnail () | |
getProductUrl () | |
Public Attributes | |
const | GROUPED_PRODUCT_IMAGE = 'checkout/cart/grouped_product_image' |
const | USE_PARENT_IMAGE = 'parent' |
Protected Member Functions | |
_toHtml () |
Definition at line 34 of file Grouped.php.
_toHtml | ( | ) | [protected] |
Prepare item html
This method uses renderer for real product type
Reimplemented from Mage_Core_Block_Template.
Definition at line 85 of file Grouped.php.
00086 { 00087 $renderer = $this->getRenderedBlock()->getItemRenderer($this->getItem()->getRealProductType()); 00088 $renderer->setItem($this->getItem()); 00089 $renderer->overrideProductUrl($this->getProductUrl()); 00090 $renderer->overrideProductThumbnail($this->getProductThumbnail()); 00091 $rendererHtml = $renderer->toHtml(); 00092 $renderer->overrideProductUrl(null); 00093 $renderer->overrideProductThumbnail(null); 00094 return $rendererHtml; 00095 }
getGroupedProduct | ( | ) |
Get item grouped product
Definition at line 44 of file Grouped.php.
00045 { 00046 if ($option = $this->getItem()->getOptionByCode('product_type')) { 00047 return $option->getProduct(); 00048 } 00049 return $this->getProduct(); 00050 }
getProductThumbnail | ( | ) |
Get product thumbnail image
Reimplemented from Mage_Checkout_Block_Cart_Item_Renderer.
Definition at line 57 of file Grouped.php.
00058 { 00059 $product = $this->getProduct(); 00060 if (!$product->getData('thumbnail') 00061 ||($product->getData('thumbnail') == 'no_selection') 00062 || (Mage::getStoreConfig(self::GROUPED_PRODUCT_IMAGE) == self::USE_PARENT_IMAGE)) { 00063 $product = $this->getGroupedProduct(); 00064 } 00065 return $this->helper('catalog/image')->init($product, 'thumbnail'); 00066 }
getProductUrl | ( | ) |
Get url to item product
Reimplemented from Mage_Checkout_Block_Cart_Item_Renderer.
Definition at line 73 of file Grouped.php.
00074 { 00075 return $this->getGroupedProduct()->getProductUrl(); 00076 }
const GROUPED_PRODUCT_IMAGE = 'checkout/cart/grouped_product_image' |
Definition at line 36 of file Grouped.php.
const USE_PARENT_IMAGE = 'parent' |
Definition at line 37 of file Grouped.php.