Select Featured Brands to Appear on Homepage

TrentTrent Member Posts: 2

We have some important brands that need representation on our homepage in the Brands Slider. The Support team at Lightspeed eCom have said:

The logic for featured brands at the moment is the 10 first created brands. When the number of brands surpasses 10, the logic switches over to the 10 brands with the most products being featured. If there are 2 brands that have the same number of products, the logic then switches over to the newest of those 2 brands is the featured one.

There is currently an enhancement request for the ability to pick featured brands since as of now it wouldn't be possible. An alternative would be to code in a custom banner that shows brands but doesn't rely on the feat:true, but rather some other parameter (have some sort of loop that goes through the brands and if a certain condition is met, gets added to the banner for example).

I am currently using this code to call up specific brands on the homepage. However the shop.brands variable only works if the brand id is a featured brand.

<div class="brand">

   <a href="{{ shop.brands.2039594.url | url }}"> <img class="lazy" src="{{ 'lazy-preload.jpg' | url_asset }}" data-src="{{shop.brands.2039594.image | url_image('400x300x1') }}" width="120" height="90" alt="{{ shop.brands.2039594.title }}"/> </a>


Looking for some insight on how to loop through all brands and filter the brand id's that I want to appear. (something like {% if brand == 2039594 or 2048896 or 2049122 or 2055277 %} then list brands)

I'm sure there's a way to do this. What am I missing?


Sign In or Register to comment.