Add ids to product listing products and variants

This commit is contained in:
Rohan Mitchell
2014-12-18 11:00:45 +11:00
parent 1d3800696e
commit ead84aa9ff

View File

@@ -17,11 +17,11 @@
%div.pad-top{bindonce: true}
%product.animate-repeat{"ng-controller" => "ProductNodeCtrl",
"ng-repeat" => "product in filteredProducts = (Products.products | products:query | taxons:activeTaxons | orderBy:ordering.order) track by product.id "}
"ng-repeat" => "product in filteredProducts = (Products.products | products:query | taxons:activeTaxons | orderBy:ordering.order) track by product.id ", "id" => "product-{{ product.id }}"}
= render partial: "shop/products/summary"
%shop-variant{variant: 'product.master', "bo-if" => "!product.hasVariants"}
%shop-variant{variant: 'variant', "ng-repeat" => "variant in product.variants track by variant.id"}
%shop-variant{variant: 'product.master', "bo-if" => "!product.hasVariants", "id" => "variant-{{ product.master.id }}"}
%shop-variant{variant: 'variant', "ng-repeat" => "variant in product.variants track by variant.id", "id" => "variant-{{ variant.id }}"}
%product{"ng-show" => "Products.loading"}
.row.summary