Search in pathfield picker not listing title but nodename only | Community
Skip to main content
September 14, 2023
Solved

Search in pathfield picker not listing title but nodename only

  • September 14, 2023
  • 1 reply
  • 389 views

Dear Community,

 

I am trying to enable the title from content-fragments to show in the search-result of the granite-pickerdialog.

The search was on the nodename only by default.

With an additional oak:index, this couled be solved and the search now works on the title.

However, the title is not showing up in the serach result. (It is listed if no search is done)

 

How can I add the jcr:title (or data/master/title from content-fragment) into the serach result so people actually see what they searched for?

 

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by aanchal-sikka

Hello @grodintierce 

 

To use "Title" we would need to -

  • overlay /libs/granite/ui/components/coral/foundation/form/pathfield/card/card.jsp
  • update
String title = resource.getName();

But the file lies in granite:FinalArea, which we should not overlay.

 

Other alternative:

create your own picker based on: /libs/dam/cfm/content/cfpicker/picker, which uses the updated card.jsp

 

Also, please post this enhancement as an Idea on the portal

 

1 reply

aanchal-sikka
Community Advisor
aanchal-sikkaCommunity AdvisorAccepted solution
Community Advisor
September 14, 2023

Hello @grodintierce 

 

To use "Title" we would need to -

  • overlay /libs/granite/ui/components/coral/foundation/form/pathfield/card/card.jsp
  • update
String title = resource.getName();

But the file lies in granite:FinalArea, which we should not overlay.

 

Other alternative:

create your own picker based on: /libs/dam/cfm/content/cfpicker/picker, which uses the updated card.jsp

 

Also, please post this enhancement as an Idea on the portal

 

Aanchal Sikka