diff --git a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Block/Product/View/Type/Configurable.php b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Block/Product/View/Type/Configurable.php index 7086d24..4b468d4 100644 --- a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Block/Product/View/Type/Configurable.php +++ b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Block/Product/View/Type/Configurable.php @@ -14,7 +14,8 @@ public function getJsonConfig() $productId = $product->getId(); $childProducts[$productId] = array( "price" => $this->_registerJsPrice($this->_convertPrice($product->getPrice())), - "finalPrice" => $this->_registerJsPrice($this->_convertPrice($product->getFinalPrice())) + "finalPrice" => $this->_registerJsPrice($this->_convertPrice($product->getFinalPrice())), + "sku" => $product->getSku(), ); if (Mage::getStoreConfig('SCP_options/product_page/change_name')) { @@ -34,13 +35,36 @@ public function getJsonConfig() ->toHtml(); } + $bChangeStock = Mage::getStoreConfig('SCP_options/product_page/change_stock'); + if ($bChangeStock) { + // Stock status HTML + $oStockBlock = $this->getLayout()->createBlock('catalog/product_view_type_simple')->setTemplate('catalog/product/view/scpavailability.phtml'); + $childProducts[$productId]["stockStatus"] = $oStockBlock->setProduct($product)->toHtml(); + + // Add to cart button + $oAddToCartBlock = $this->getLayout()->createBlock('catalog/product_view_type_simple')->setTemplate('catalog/product/view/addtocart.phtml'); + $childProducts[$productId]["addToCart"] = $oAddToCartBlock->setProduct($product)->toHtml(); + } + + $bShowProductAlerts = Mage::getStoreConfig(Mage_ProductAlert_Model_Observer::XML_PATH_STOCK_ALLOW); + if ($bShowProductAlerts && !$product->isAvailable()) { + $oAlertBlock = $this->getLayout()->createBlock('productalert/product_view') + ->setTemplate('productalert/product/view.phtml') + ->setSignupUrl(Mage::helper('productalert')->setProduct($product)->getSaveUrl('stock'));; + $childProducts[$productId]["alertHtml"] = $oAlertBlock->toHtml(); + } + #if image changing is enabled.. if (Mage::getStoreConfig('SCP_options/product_page/change_image')) { #but dont bother if fancy image changing is enabled if (!Mage::getStoreConfig('SCP_options/product_page/change_image_fancy')) { #If image is not placeholder... if($product->getImage()!=='no_selection') { - $childProducts[$productId]["imageUrl"] = (string)Mage::helper('catalog/image')->init($product, 'image'); + $productMag = Mage::getModel('catalog/product')->load($productId); + foreach($productMag->getMediaGalleryImages() as $image) + { + $childProducts[$productId]["imageUrl"][] = (string)Mage::helper('catalog/image')->init($product, 'image', $image->getFile()); + } } } } @@ -75,7 +99,10 @@ public function getJsonConfig() $config['shortDescription'] = $this->helper('catalog/output')->productAttribute($p, nl2br($p->getShortDescription()), 'short_description'); if (Mage::getStoreConfig('SCP_options/product_page/change_image')) { - $config["imageUrl"] = (string)Mage::helper('catalog/image')->init($p, 'image'); + foreach($p->getMediaGalleryImages() as $image) + { + $config["imageUrl"][] = (string)Mage::helper('catalog/image')->init($p, 'image', $image->getFile()); + } } $childBlock = $this->getLayout()->createBlock('catalog/product_view_attributes'); @@ -83,6 +110,14 @@ public function getJsonConfig() ->setProduct($this->getProduct()) ->toHtml(); + $bShowProductAlerts = Mage::getStoreConfig(Mage_ProductAlert_Model_Observer::XML_PATH_STOCK_ALLOW); + if ($bShowProductAlerts && !Mage::registry('child_product')->isAvailable()) { + $oAlertBlock = $this->getLayout()->createBlock('productalert/product_view') + ->setTemplate('productalert/product/view.phtml') + ->setSignupUrl(Mage::helper('productalert')->setProduct(Mage::registry('child_product'))->getSaveUrl('stock'));; + $config["alertHtml"] = $oAlertBlock->toHtml(); + } + if (Mage::getStoreConfig('SCP_options/product_page/change_image')) { if (Mage::getStoreConfig('SCP_options/product_page/change_image_fancy')) { $childBlock = $this->getLayout()->createBlock('catalog/product_view_media'); diff --git a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Product/Type/Simple.php b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Product/Type/Simple.php index fed7bef..7b4a08b 100644 --- a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Product/Type/Simple.php +++ b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Product/Type/Simple.php @@ -35,7 +35,7 @@ public function prepareForCart(Varien_Object $buyRequest, $product = null) public function hasConfigurableProductParentId() { $cpid = $this->getCpid(); - Mage::log("cpid: ". $cpid); + //Mage::log("cpid: ". $cpid); return !empty($cpid); } diff --git a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Eav/Mysql4/Product/Collection.php b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Eav/Mysql4/Product/Collection.php deleted file mode 100644 index 8f85575..0000000 --- a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Eav/Mysql4/Product/Collection.php +++ /dev/null @@ -1,40 +0,0 @@ -_productLimitationFilters; - if (empty($filters['use_price_index'])) { - return $this; - } - - $connection = $this->getConnection(); - - $joinCond = $joinCond = join(' AND ', array( - 'price_index.entity_id = e.entity_id', - $connection->quoteInto('price_index.website_id = ?', $filters['website_id']), - $connection->quoteInto('price_index.customer_group_id = ?', $filters['customer_group_id']) - )); - - $fromPart = $this->getSelect()->getPart(Zend_Db_Select::FROM); - if (!isset($fromPart['price_index'])) { - $minimalExpr = new Zend_Db_Expr( - 'IF(`price_index`.`tier_price`, LEAST(`price_index`.`min_price`, `price_index`.`tier_price`), `price_index`.`min_price`)' - ); - $indexedExpr = new Zend_Db_Expr('price_index.price'); - $this->getSelect()->join( - array('price_index' => $this->getTable('catalog/product_index_price')), - $joinCond, - array('indexed_price'=>$indexedExpr,'price', 'final_price', 'minimal_price'=>$minimalExpr , 'min_price', 'max_price', 'tier_price')); - - } else { - $fromPart['price_index']['joinCondition'] = $joinCond; - $this->getSelect()->setPart(Zend_Db_Select::FROM, $fromPart); - } - - return $this; - } -} diff --git a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Product/Collection.php b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Product/Collection.php new file mode 100644 index 0000000..bbf6a28 --- /dev/null +++ b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Product/Collection.php @@ -0,0 +1,56 @@ +addPriceData(); + * + * @see Mage_Catalog_Model_Resource_Product_Collection::_productLimitationJoinPrice() + */ + protected function _productLimitationPrice($joinLeft = false) + { + $filters = $this->_productLimitationFilters; + if (empty($filters['use_price_index'])) { + return $this; + } + + $helper = Mage::getResourceHelper('core'); + $connection = $this->getConnection(); + $select = $this->getSelect(); + $joinCond = join(' AND ', array( + 'price_index.entity_id = e.entity_id', + $connection->quoteInto('price_index.website_id = ?', $filters['website_id']), + $connection->quoteInto('price_index.customer_group_id = ?', $filters['customer_group_id']) + )); + + $fromPart = $select->getPart(Zend_Db_Select::FROM); + if (!isset($fromPart['price_index'])) { + $least = $connection->getLeastSql(array('price_index.min_price', 'price_index.tier_price')); + $minimalExpr = $connection->getCheckSql('price_index.tier_price IS NOT NULL', + $least, 'price_index.min_price'); + $indexedExpr = new Zend_Db_Expr('price_index.price'); + $colls = array('indexed_price'=>$indexedExpr,'price', 'tax_class_id', 'final_price', + 'minimal_price'=>$minimalExpr , 'min_price', 'max_price', 'tier_price'); + $tableName = array('price_index' => $this->getTable('catalog/product_index_price')); + if ($joinLeft) { + $select->joinLeft($tableName, $joinCond, $colls); + } else { + $select->join($tableName, $joinCond, $colls); + } + // Set additional field filters + foreach ($this->_priceDataFieldFilters as $filterData) { + $select->where(call_user_func_array('sprintf', $filterData)); + } + + } else { + $fromPart['price_index']['joinCondition'] = $joinCond; + $select->setPart(Zend_Db_Select::FROM, $fromPart); + } + //Clean duplicated fields + $helper->prepareColumnsList($select); + + return $this; + } +} diff --git a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Eav/Mysql4/Product/Indexer/Price.php b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Product/Indexer/Price.php similarity index 56% rename from app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Eav/Mysql4/Product/Indexer/Price.php rename to app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Product/Indexer/Price.php index 21eda98..2d24d50 100644 --- a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Eav/Mysql4/Product/Indexer/Price.php +++ b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Product/Indexer/Price.php @@ -1,17 +1,20 @@ child_product type_id + */ private function getChildIdsByParent($parentId) { $read = $this->_getReadAdapter(); $select = $read->select() - #->from(array('pr' => $this->getTable('catalog/product_relation')), array('child_id')) ->from(array('p' => $this->getTable('catalog/product')), array('entity_id')) ->join( - #array('p' => $this->getTable('catalog/product')), array('pr' => $this->getTable('catalog/product_relation')), 'pr.child_id=p.entity_id', array('p.type_id')) @@ -19,6 +22,15 @@ private function getChildIdsByParent($parentId) return $read->fetchPairs($select); } + /** + * Get product type from product id + * + * catalog_product_entity has the product type. Not exactly sure why + * we're using a join here, but it works. + * + * @param integer $id + * @return string Product type + */ private function getProductTypeById($id) { $read = $this->_getReadAdapter(); @@ -30,20 +42,21 @@ private function getProductTypeById($id) array('p.type_id')) ->where('pr.parent_id=?', $id); $data = $read->fetchRow($select); - #Mage::log("SCP: getProductTypeById: result is: " . print_r($data, true)); return $data['type_id']; } - #This is modified to pull in all sibling associated products' tier prices. - #Without this, indexed price updates only consider the tier prices of the specific - #associated product that's being saved, and it's parent - #This will often result in a non-lowest tier price being displayed, or no tier price being - #displayed when there is one (on a sibling) - #It's also updated to reindex child tier prices when a parent is saved - - #Surely it's not just tier prices but all related prices this acts on? - #does copyRelationIndexData followed by reindexEntity do this itself? (just not for tier prices?) + /** + * Modified to pull in all sibling associated products' tier prices and + * to reindex child tier prices when a parent is saved. + * + * Process product save. + * Method is responsible for index support + * when product was saved and changed attribute(s) has an effect on price. + * + * @param Mage_Index_Model_Event $event + * @return Mage_Catalog_Model_Resource_Product_Indexer_Price + */ public function catalogProductSave(Mage_Index_Model_Event $event) { $productId = $event->getEntityPk(); @@ -55,55 +68,40 @@ public function catalogProductSave(Mage_Index_Model_Event $event) if (!isset($data['reindex_price'])) { return $this; } - $this->cloneIndexTable(true); + + $this->clearTemporaryIndexTable(); $this->_prepareWebsiteDateTable(); $indexer = $this->_getIndexer($data['product_type_id']); $processIds = array($productId); - if ($indexer->getIsComposite()) { - #Mage::log("catalogProductSave: " . "saving composite"); if ($this->getProductTypeById($productId) == 'configurable') { - #Mage::log("catalogProductSave: " . "saving composite - is configurable"); $children = $this->getChildIdsByParent($productId); $processIds = array_merge($processIds, array_keys($children)); - #Ignore tier price data for actual configurable product + //Ignore tier and group price data for actual configurable product $tierPriceIds = array_keys($children); } else { $tierPriceIds = $productId; } - #Mage::log("catalogProductSave: " . "copyRelationIndexData for: " . $productId); $this->_copyRelationIndexData($productId); - #Mage::log("catalogProductSave: " . "_prepareTierPriceIndex for: " . print_r($tierPriceIds, true)); $this->_prepareTierPriceIndex($tierPriceIds); - #Mage::log("catalogProductSave: " . "reindexEntity for: " . $productId); + $this->_prepareGroupPriceIndex($tierPriceIds); $indexer->reindexEntity($productId); } else { - #Mage::log("catalogProductSave: " . "saving non-composite"); $parentIds = $this->getProductParentsByChild($productId); - if ($parentIds) { - #Mage::log("catalogProductSave: " . "non-composite product: " . $productId . " has parents: " . print_r($parentIds, true)); - - #Prepare to process parents too $processIds = array_merge($processIds, array_keys($parentIds)); - $siblingIds = array(); foreach (array_keys($parentIds) as $parentId) { $childIds = $this->getChildIdsByParent($parentId); - #Mage::log("catalogProductSave: For parent_id: $parentId, adding childIds of: " . print_r($childIds, true)); $siblingIds = array_merge($siblingIds, array_keys($childIds)); } - #Mage::log("catalogProductSave: siblingIds are: " . print_r($siblingIds, true)); if(count($siblingIds)>0) { $processIds = array_unique(array_merge($processIds, $siblingIds)); } - #Mage::log("catalogProductSave: " . "copyRelationIndexData for: " . print_r(array_keys($parentIds), true) . "ignoring relation: " . $productId); $this->_copyRelationIndexData(array_keys($parentIds), $productId); - - #Mage::log("catalogProductSave: " . "_prepareTierPriceIndex for: " . print_r($processIds, true)); $this->_prepareTierPriceIndex($processIds); - #Mage::log("catalogProductSave: " . "reindexEntity for: " . $productId); + $this->_prepareGroupPriceIndex($processIds); $indexer->reindexEntity($productId); $parentByType = array(); @@ -112,13 +110,11 @@ public function catalogProductSave(Mage_Index_Model_Event $event) } foreach ($parentByType as $parentType => $entityIds) { - #Mage::log("catalogProductSave: " . "reindexEntity using indexer of type: " . $parentType . " for: " . print_r($entityIds, true)); $this->_getIndexer($parentType)->reindexEntity($entityIds); } - } else { - #Mage::log("catalogProductSave: " . "non-composite product: " . $productId . " has no parents"); $this->_prepareTierPriceIndex($productId); + $this->_prepareGroupPriceIndex($productId); $indexer->reindexEntity($productId); } } diff --git a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Eav/Mysql4/Product/Indexer/Price/Configurable.php b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Product/Indexer/Price/Configurable.php similarity index 86% rename from app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Eav/Mysql4/Product/Indexer/Price/Configurable.php rename to app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Product/Indexer/Price/Configurable.php index 8e26148..cc44314 100644 --- a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Eav/Mysql4/Product/Indexer/Price/Configurable.php +++ b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Catalog/Model/Resource/Product/Indexer/Price/Configurable.php @@ -1,5 +1,5 @@ new Zend_Db_Expr('pi.final_price'), 'tier_price' => new Zend_Db_Expr('pi.tier_price'), 'base_tier' => new Zend_Db_Expr('pi.tier_price'), - 'group_price' => new Zend_Db_Expr('pi.tier_price'), - 'base_group_price' => new Zend_Db_Expr('pi.tier_price'), + 'group_price' => new Zend_Db_Expr('pi.group_price'), + 'base_group_price' => new Zend_Db_Expr('pi.group_price'), )); @@ -130,7 +130,6 @@ protected function _prepareFinalPriceData($entityIds = null) 'base_tier', 'group_price', 'base_group_price', - #'base_tier', #'child_entity_id' )); # Mage::log("SCP Price inner query: " . $select->__toString()); @@ -140,6 +139,23 @@ protected function _prepareFinalPriceData($entityIds = null) $write->query($query); + /** + * Add possibility modify prices from external events + */ + $select = $write->select() + ->join(array('wd' => $this->_getWebsiteDateTable()), + 'i.website_id = wd.website_id', + array()); + Mage::dispatchEvent('prepare_catalog_product_price_index_table', array( + 'index_table' => array('i' => $this->_getDefaultFinalPriceTable()), + 'select' => $select, + 'entity_id' => 'i.entity_id', + 'customer_group_id' => 'i.customer_group_id', + 'website_id' => 'i.website_id', + 'website_date' => 'wd.website_date', + 'update_fields' => array('price', 'min_price', 'max_price') + )); + return $this; } } diff --git a/app/code/community/OrganicInternet/SimpleConfigurableProducts/CatalogInventory/Model/Mysql4/Indexer/Stock/Configurable.php b/app/code/community/OrganicInternet/SimpleConfigurableProducts/CatalogInventory/Model/Resource/Indexer/Stock/Configurable.php similarity index 67% rename from app/code/community/OrganicInternet/SimpleConfigurableProducts/CatalogInventory/Model/Mysql4/Indexer/Stock/Configurable.php rename to app/code/community/OrganicInternet/SimpleConfigurableProducts/CatalogInventory/Model/Resource/Indexer/Stock/Configurable.php index 200379a..888b4b3 100644 --- a/app/code/community/OrganicInternet/SimpleConfigurableProducts/CatalogInventory/Model/Mysql4/Indexer/Stock/Configurable.php +++ b/app/code/community/OrganicInternet/SimpleConfigurableProducts/CatalogInventory/Model/Resource/Indexer/Stock/Configurable.php @@ -1,11 +1,24 @@ _getWriteAdapter(); @@ -39,20 +52,20 @@ protected function _getStockStatusSelect($entityIds = null, $usePrimaryTable = f ->where('e.type_id = ?', $this->getTypeId()) ->group(array('e.entity_id', 'cw.website_id', 'cis.stock_id')); - $this->_addProductWebsiteJoinToSelect($select, 'cw.website_id', 'le.entity_id'); #may need to use le.entity_id? + $this->_addProductWebsiteJoinToSelect($select, 'cw.website_id', 'le.entity_id'); $psExpr = $this->_addAttributeToSelect($select, 'status', 'le.entity_id', 'cs.store_id'); $psCond = $adapter->quoteInto($psExpr . '=?', Mage_Catalog_Model_Product_Status::STATUS_ENABLED); if ($this->_isManageStock()) { - $statusExpr = new Zend_Db_Expr('IF(cisi.use_config_manage_stock = 0 AND cisi.manage_stock = 0,' - . ' 1, cisi.is_in_stock)'); + $statusExpr = $adapter->getCheckSql('cisi.use_config_manage_stock = 0 AND cisi.manage_stock = 0', + 1, 'cisi.is_in_stock'); } else { - $statusExpr = new Zend_Db_Expr('IF(cisi.use_config_manage_stock = 0 AND cisi.manage_stock = 1,' - . 'cisi.is_in_stock, 1)'); + $statusExpr = $adapter->getCheckSql('cisi.use_config_manage_stock = 0 AND cisi.manage_stock = 1', + 'cisi.is_in_stock', 1); } - $stockStatusExpr = new Zend_Db_Expr("MAX(LEAST(IF({$psCond}, 1, 0), {$statusExpr}))"); + $stockStatusExpr = new Zend_Db_Expr("MAX(LEAST(IF({$psCond}, 1, 0), {$statusExpr}))"); $select->columns(array( 'status' => $stockStatusExpr @@ -60,8 +73,7 @@ protected function _getStockStatusSelect($entityIds = null, $usePrimaryTable = f if (!is_null($entityIds)) { $select->where('e.entity_id IN(?)', $entityIds); - } - + } return $select; } } diff --git a/app/code/community/OrganicInternet/SimpleConfigurableProducts/CatalogRule/Model/Mysql4/Rule.php b/app/code/community/OrganicInternet/SimpleConfigurableProducts/CatalogRule/Model/Resource/Rule.php similarity index 98% rename from app/code/community/OrganicInternet/SimpleConfigurableProducts/CatalogRule/Model/Mysql4/Rule.php rename to app/code/community/OrganicInternet/SimpleConfigurableProducts/CatalogRule/Model/Resource/Rule.php index 8935ef4..6e6663f 100644 --- a/app/code/community/OrganicInternet/SimpleConfigurableProducts/CatalogRule/Model/Mysql4/Rule.php +++ b/app/code/community/OrganicInternet/SimpleConfigurableProducts/CatalogRule/Model/Resource/Rule.php @@ -5,8 +5,8 @@ #My fix is: only delete pricerule price entries for the rule that fails to validate #It's an odd bug - and maybe there's a good reason, but it's making my rules disappear when I save products, which is pretty annoying -class OrganicInternet_SimpleConfigurableProducts_CatalogRule_Model_Mysql4_Rule extends - Mage_CatalogRule_Model_Mysql4_Rule +class OrganicInternet_SimpleConfigurableProducts_CatalogRule_Model_Resource_Rule extends + Mage_CatalogRule_Model_Resource_Rule { public function applyToProduct($rule, $product, $websiteIds) diff --git a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Checkout/Block/Cart/Item/Renderer.php b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Checkout/Block/Cart/Item/Renderer.php index 4817f31..c65931e 100644 --- a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Checkout/Block/Cart/Item/Renderer.php +++ b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Checkout/Block/Cart/Item/Renderer.php @@ -10,10 +10,13 @@ protected function getConfigurableProductParentId() #No idea why in 1.5 the stuff in buyRequest isn't auto-decoded from info_buyRequest #but then it's Magento we're talking about, so I've not a clue what's *meant* to happen. try { - $buyRequest = unserialize($this->getItem()->getOptionByCode('info_buyRequest')->getValue()); - if(!empty($buyRequest['cpid'])) { - return $buyRequest['cpid']; + $buyRequest = $this->getItem()->getOptionByCode('info_buyRequest'); + if ($buyRequest) { + $buyRequest = unserialize($buyRequest->getValue()); } + if(!empty($buyRequest['cpid'])) { + return $buyRequest['cpid']; + } } catch (Exception $e) { } return null; diff --git a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Rss/Block/Catalog/Category.php b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Rss/Block/Catalog/Category.php index fa9daeb..38f756e 100644 --- a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Rss/Block/Catalog/Category.php +++ b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Rss/Block/Catalog/Category.php @@ -69,7 +69,7 @@ protected function _toHtml() '
Price From:' : '
Price:'). + ($_product->isConfigurable() ? '
Preis ab: ' : '
Preis:'). Mage::helper('core')->currency($_product->getPrice()). ($_product->getPrice() != $final_price ? ' Special Price:'. Mage::helper('core')->currency($final_price) : ''). '
'. diff --git a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Rss/Block/Catalog/New.php b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Rss/Block/Catalog/New.php index 6401130..016db9c 100644 --- a/app/code/community/OrganicInternet/SimpleConfigurableProducts/Rss/Block/Catalog/New.php +++ b/app/code/community/OrganicInternet/SimpleConfigurableProducts/Rss/Block/Catalog/New.php @@ -12,7 +12,7 @@ public function addNewItemXmlCallback($args) $description = '