Expand my Community achievements bar.

SOLVED

how to create custom Search assets filter in the AEM?

Avatar

Level 4

I need to create custom asset filter and after creating custom filter it should visible along with OOB search assets filter.

User needs to see custom filter as well as OOB filter.

can any one explain with example that how to overlay this path /libs/settings/dam/search/facets/assets.

filters.png

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi @karthick1356,

If I good understand under /conf you have only your custom fields, and you have removed all OOTB ones. If so this is correct behavior that you are seeing only your custom fields. Under /conf you should keep all the fileds OOTB and custom. OOTB fields will be automatically copied when you first time edit Assets Admin Search Rail  from GUI.

Below simple examples.

Scenario 1

I have added new field and also kept OOTB ones under /conf

crx-1.jpg

filter-1.jpg

Scenario 2

Only custom field is stored under /conf

crx-2.jpgfilter-2.jpg

Summarizing, if you need combination of OOTB and custom fields in filter section, you have to store them all under /conf. If there is any configuration under /conf it will be used instead /libs, and there will be no automatic merging of those two location in that case.

View solution in original post

6 Replies

Avatar

Community Advisor

Hi @karthick1356,

Please follow steps described under Adobe documentation - https://experienceleague.adobe.com/docs/experience-manager-65/assets/administer/search-facets.html?l...

In general, you have to:

  1. Navigate to Tools -> General -> Search Forms.
  2. Select Assets Admin Search Rail  from list and click edit.
  3. Set your changes and save.

Your customization will be stored under /conf/global/settings/dam/search/facets/assets/jcr:content/items - so this is part of content you can move to your git repository or include into crx package to propagate changes into other environments.

Avatar

Level 4

Hi @lukasz-m,

Yes, I have created custom filter that are stored under /conf/global/settings/dam/search/facets/assets/jcr:content/items . Now OOB filter from /libs/settings/dam/search/facets/assets and my custom from /conf/global/settings/dam/search/facets/assets/jcr:content/items  filter should merge and display for the user, but its not merging and display its displaying only custom filter one not OOB filter.

I'm not sure what is the issue here?

Avatar

Correct answer by
Community Advisor

Hi @karthick1356,

If I good understand under /conf you have only your custom fields, and you have removed all OOTB ones. If so this is correct behavior that you are seeing only your custom fields. Under /conf you should keep all the fileds OOTB and custom. OOTB fields will be automatically copied when you first time edit Assets Admin Search Rail  from GUI.

Below simple examples.

Scenario 1

I have added new field and also kept OOTB ones under /conf

crx-1.jpg

filter-1.jpg

Scenario 2

Only custom field is stored under /conf

crx-2.jpgfilter-2.jpg

Summarizing, if you need combination of OOTB and custom fields in filter section, you have to store them all under /conf. If there is any configuration under /conf it will be used instead /libs, and there will be no automatic merging of those two location in that case.

Avatar

Level 4

@lukasz-m, how do we get latest update if we move OOB filter and custom under /conf. lets say in new SP there will be new filters, how it get updated under /conf ?

 

Thanks so much for prompt response. I appreciate your effort !.

Avatar

Community Advisor

@karthick1356I think that the only option will be to track changes via release notes, or by checking on the repository level, if there are any new options under /libs after SP installation that you would like to include in your custom configuration.

Avatar

Level 4

Hi @karthick1356,

 

You can find the implementation of a custom asset filter along with the OOTB filters for your reference here -  https://experience-aem.blogspot.com/2020/02/aem-6530-assets-admin-search-rail-predicate-search-based...

 

Hope it helps!

 

Thanks,

Manpreet