Expand my Community achievements bar.

Guidelines for the Responsible Use of Generative AI in the Experience Cloud Community.
SOLVED

Asset share commons search results

Avatar

Level 2

Hi All,

 

I am working on search results component in asset share commons, which currently searches for dam:Asset only. I have a requirement to override the OOTB behaviour to search dam:asset as well as sling:folder. Can anybody help to proceed on this ?

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi, 

Please take a look at QuerySearchPreProcessor, here is an example of how to use it: https://suman-shekhar.medium.com/query-search-preprocessor-customization-04cb55adfa60.

Another alternative is to extend the search functionality from here: https://github.com/adobe/asset-share-commons/blob/develop/core/src/main/java/com/adobe/aem/commons/a... 

 

Hope this helps



Esteban Bustamante

View solution in original post

5 Replies

Avatar

Correct answer by
Community Advisor

Hi, 

Please take a look at QuerySearchPreProcessor, here is an example of how to use it: https://suman-shekhar.medium.com/query-search-preprocessor-customization-04cb55adfa60.

Another alternative is to extend the search functionality from here: https://github.com/adobe/asset-share-commons/blob/develop/core/src/main/java/com/adobe/aem/commons/a... 

 

Hope this helps



Esteban Bustamante

Avatar

Level 2

Hi @EstebanBustamante , I have overriden the QuerySearchPreProcessor to modify the search query. This works. But by doing this I path format has changed due to which I need to override search results component to support the new structure. How can we achieve this ? Any suggestion ?

Avatar

Community Advisor

Hi @ayush_aem 

Were the user suggestions helpful? Let us know if more details are needed or mark the answer as correct. If you found a solution independently, please share it with the community.



Arun Patidar

Avatar

Level 2

Yes Arun. This can be marked as the correct answer. It worked.

Avatar

Administrator

@ayush_aem I hope the AEM community has been helpful. We look forward to your return as either a learner or a contributor. The community grows with SMEs like you. Invite your AEM peers to contribute too. Happy AEM learning!



Kautuk Sahni