cancel
Showing results for 
Search instead for 
Did you mean: 

Widget Document Suggestion how to query on two fields?

Mathilde_Viveri
Confirmed Champ
Confirmed Champ

Hello,

In my layout I would like to be able to search a document but be able to search either on its name or on its code. I tried several things with the nxql query but couldn't make it work. I thought about the javascript formatter but I think it wouldn't help me search on both field.

Here's what I tried: SELECT * FROM myDocType WHERE dc:title = '%?%' OR mySchema:code = '%?%'

but obviously it's not working. I get an empty response from the servor. Would you have any idea how to achieve this ? Or if it's even possible ?

Thanks

1 REPLY 1

pibou_Bouvret
Elite Collaborator
Elite Collaborator

You can use your widget's custom parameter : "operationId" and set its value to the name of your contributed custom operation. There is an example with javascript automation here : https://www.nuxeo.com/blog/fun-suggestion-widget-javascript/

Getting started

Attention: Blogs & Forums are in READ-ONLY mode from Oct 9-19 as we transition to our new platform. Learn more.

Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.