diff --git a/Plugin/Frontend/MageSuite/ProductTile/Block/Tile/Container.php b/Plugin/Frontend/MageSuite/ProductTile/Block/Tile/Container.php new file mode 100644 index 0000000..87cf1b5 --- /dev/null +++ b/Plugin/Frontend/MageSuite/ProductTile/Block/Tile/Container.php @@ -0,0 +1,46 @@ +config = $config; + } + + /** + * @param $subject + * @param $result + * @return mixed|string + */ + public function afterToHtml($subject, $result) + { + if ($result && $this->config->isEnabled()) { + if ($subject->getData('html_tag') == 'figure') { + return $result. Html::COMMENT_PREFIX . $subject->getProduct()->getId() . Html::COMMENT_SUFFIX; + } + } + + return $result; + } +} \ No newline at end of file diff --git a/etc/frontend/di.xml b/etc/frontend/di.xml index affe7d9..7400f4a 100644 --- a/etc/frontend/di.xml +++ b/etc/frontend/di.xml @@ -16,4 +16,8 @@ + + + +