From a7a9688d415069d61d00d72a8a8fef83aba58546 Mon Sep 17 00:00:00 2001 From: Etienne Roudeix Date: Fri, 5 Jul 2013 11:12:51 +0200 Subject: [PATCH] product lopp --- core/lib/Thelia/Core/Template/Loop/Product.php | 7 ++++--- templates/smarty-sample/category.html | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/core/lib/Thelia/Core/Template/Loop/Product.php b/core/lib/Thelia/Core/Template/Loop/Product.php index 7387a3699..29294e709 100755 --- a/core/lib/Thelia/Core/Template/Loop/Product.php +++ b/core/lib/Thelia/Core/Template/Loop/Product.php @@ -240,10 +240,11 @@ class Product extends BaseLoop case "reverse": $search->orderByPosition(\Criteria::DESC); break; - /*case "min_price": - $search->orderByPosition(\Criteria::DESC); + case "min_price": + //$search->order + //$search->orderByPosition(\Criteria::DESC); break; - case "max_price": + /*case "max_price": $search->orderByPosition(\Criteria::DESC); break; case "category": diff --git a/templates/smarty-sample/category.html b/templates/smarty-sample/category.html index b99390cb6..594be9cc6 100755 --- a/templates/smarty-sample/category.html +++ b/templates/smarty-sample/category.html @@ -19,7 +19,7 @@
{/loop*}

PRODUCTS

-{loop name="product" type="product"} +{loop name="product" type="product" order="min_price"}

PRODUCT : #REF / #TITLE

price : #PRICE €
promo price : #PROMO_PRICE €