+ *
+ */
+class ProductSaleElementsTest extends BaseLoopTestor
+{
+ public function getTestedClassName()
+ {
+ return 'Thelia\Core\Template\Loop\ProductSaleElements';
+ }
+
+ public function getTestedInstance()
+ {
+ return new ProductSaleElements($this->request, $this->dispatcher, $this->securityContext);
+ }
+
+ public function getMandatoryArguments()
+ {
+ return array('product' => 1);
+ }
+}
diff --git a/templates/default/category.html b/templates/default/category.html
index fd4651a93..2f14976f9 100755
--- a/templates/default/category.html
+++ b/templates/default/category.html
@@ -40,6 +40,32 @@
{elseloop rel="ft"}
No feature
{/elseloop}
+ {ifloop rel="pse"}
+ Product sale elements
+
+ {assign var=current_product value=#ID}
+ {loop name="pse" type="product_sale_elements" product="#ID"}
+
+ {loop name="combi" type="attribute_combination" product_sale_element="#ID"}
+ #ATTRIBUTE_TITLE = #ATTRIBUTE_AVAILABILITY_TITLE
+ {/loop}
+
#WEIGHT g
+
{if #IS_PROMO == 1} #PROMO_PRICE € (instead of #PRICE) {else} #PRICE € {/if}
+
+ Add
+
+ to my cart
+
+
+ {/loop}
+ {/ifloop}
+ {elseloop rel="ft"}
+ No feature
+ {/elseloop}
{/loop}
{loop name="catgory1" type="category" parent="#ID"}
@@ -65,7 +91,12 @@
Features
{loop name="ft" type="feature" order="manual" product="#ID"}
- - #TITLE
+ -
+ #TITLE :
+ {loop name="ft_v" type="feature_value" product="{$current_product}" feature="#ID"}
+ #TITLE / #PERSONAL_VALUE
+ {/loop}
+
{/loop}
{/ifloop}