Developer forum

Forum » Feature requests » Smart Search - variant collection

Smart Search - variant collection

Nuno Aguiar
Reply

Hi,

 

Sometimes we need to create a smart search that returns specific variants. Right now, the smart search works as intended, but returns a product collection.

 

When we apply it to the paragraph, and we want to "Show all variants", we basically loose the smart search. If the smart search were to be a product + variant collection, we would be able to "Show all variants" based on the smart search.

 

Best Regards,

Nuno


Replies

 
Hans-Henrik Stefansen
Reply

Hi Nuno,

Smart searches are currently not able to take the paragraph settings into account, when querying for the matching products.
So no matter how you set the show variant option on the product catalog, smart searches will always return products in the frontend.

We recently made a change, so that if a smart search only matches variants, you get the main products of these variants in the frontend.
But only if no other products are matched.

So in order to achieve the result you are aiming at, I would recommend using filters instead.
And if you want to hide the filter predicates from the user, you could request the products using an AJAX request.
Using the filter directly should also give better performance.

Best regards,

Hans-Henrik

 
Nuno Aguiar
Reply

Hi Hans,

 

Yes we are doing that already, although not with an ajax. We are setting up a "query add on" field on the page level, and when a user enters that page, our navaigation is rendering "/Default.aspx?ID=0&query_add_on", activating the filters directly.

 

But this workaround is "messed up", because the client will want filters on that page, so we always need to take that into account. It's not a clean solution, hence the feature request.

 

Can you tell me if this is eligable for a future version and/if already has been planned for?

 

Best Regards,

Nuno

 
Nicolai Høeg Pedersen
Reply
This post has been marked as an answer

Hi Nuno

This is not planned for in smart searches.

We've just launched a new index and filter search though - much different and way better from the version we have now.

This one I'm pretty sure can be used to what you are trying to accomplish. There are 2 sessions on TC you could see on this!

Nicolai

Votes for this answer: 1
 
Nuno Aguiar
Reply

Hi Nicolai,

 

That's awesome. I will try to figure the best ones.

 

Best Regards,

Nuno Aguiar