Last active
December 22, 2015 15:39
-
-
Save Shagshag/6493785 to your computer and use it in GitHub Desktop.
Tags in product properties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class Product extends ProductCore{ | |
public static function getProductProperties($id_lang, $row, Context $context = null) | |
{ | |
$row = parent::getProductProperties($id_lang, $row, $context); | |
if (is_array($row) && isset($row['id_product'])) { | |
$usetax = Tax::excludeTaxeOption(); | |
$cache_key = $row['id_product'].'-'.$row['id_product_attribute'].'-'.$id_lang.'-'.(int)$usetax; | |
self::$producPropertiesCache[$cache_key]['tags'] = Tag::getProductTags($row['id_product']); | |
$row = self::$producPropertiesCache[$cache_key]; | |
} | |
return $row; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment