SaaS CMS has officially launched! Learn more now.

How to combine multiple searches from multiple blocks on a page in one request

Vote:
 

Hi,

I have a page contain ten blocks, each block perform one query filter

and i want to combine all query from multiple blocks into one request then perfrom at page level

As i understand, episerver find support multiple search. But i don't know how to combine all requests from multiple blocks when page loading and how to pass result for each block

Please can anyone give me the solution

Regards,

Thao Pham

#206247
Edited, Aug 08, 2019 12:15
Vote:
 
#206249
Aug 08, 2019 12:26
Vote:
 

Hi Quan,

I know episerver support multiple search but my quesion:

How to combine multiple search request from multiple blocks on a same page in one request at page level

Regards,

Thao Pham

#206251
Aug 08, 2019 13:06
Vote:
 

Hi,

first of all you have to access all the blocks from the page controller (or wherever you like to have your code). You can find ideas on how to do that here: https://world.episerver.com/forum/developer-forum/Developer-to-developer/Thread-Container/2018/4/how-to-get-block-items-from-a-contentarea-based-on-its-type/

When you have all the blocks with query filters, follow Quan's advise on multiquery.

 

#206332
Aug 15, 2019 7:58
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.