cancel
Showing results for 
Search instead for 
Did you mean: 

How to change result order in search?

How to change result order in search?

Hello,

 

Let me explain, currently when searching for a product these return by default the most relevant in ascending order, as a result the products appear but for example the first one is "available" and the next one is "coming soon" being those their labels.

 

How can I make it return the products, for example, first all the "available" ones and then the "coming soon" ones?

Captura de pantalla de 2022-09-13 18-17-53.png

Currently I have the "changeCollection" function as seen in the image where the collection that returns the order is, for example, changing it instead of "ranking_summaries" to "available" does not change it and the search engine query continues with "ranking_summaries".

 

Any idea why it overwrites it or how or where this can be changed?

Beforehand thank you very much.

1 REPLY 1

Re: How to change result order in search?


@Price Chopper Employee Login wrote:

Hello,

 

Let me explain, currently when searching for a product these return by default the most relevant in ascending order, as a result the products appear but for example the first one is "available" and the next one is "coming soon" being those their labels.

 

How can I make it return the products, for example, first all the "available" ones and then the "coming soon" ones?

Captura de pantalla de 2022-09-13 18-17-53.png

Currently I have the "changeCollection" function as seen in the image where the collection that returns the order is, for example, changing it instead of "ranking_summaries" to "available" does not change it and the search engine query continues with "ranking_summaries".

 

Any idea why it overwrites it or how or where this can be changed?

Beforehand thank you very much.


I appreciate the information and advice you have shared. I will try to figure it out for more.