Alfresco 6.0 advanced custom search query

cancel
Showing results for 
Search instead for 
Did you mean: 
angelborroy
Alfresco Employee

Re: Alfresco 6.0 advanced custom search query

It looks like you are deploying twice the content model in the repository. This error is not related with share-config-custom.xml customisation.

Hyland Developer Evangelist
pedrohernandez
Active Member II

Re: Alfresco 6.0 advanced custom search query

I have only 1 content model active, and actually I changed the URI to a new one to test it out, and got some error but the uri changed.

angelborroy
Alfresco Employee

Re: Alfresco 6.0 advanced custom search query

No, you have 2 content models deployed using the same URI:

http://kardox.demo.netlinux/model/facturasnew/1.0 

Check your modules (JAR / AMP), your XML in 'extension' directory and Model Manager tool.

Hyland Developer Evangelist
pedrohernandez
Active Member II

Re: Alfresco 6.0 advanced custom search query

Hello Angel, thanks for your help, Yes aparently that was an issue, since right now im in local, I deleted the container and build it again, now Solr it's not giving me error, but, I can't still find the documents by the custom aspect properties..

Also to note, when my aspect properties is set to index "free text" or "full text" the property disapears from the search filters and i cannot add it to filters.

My files properties is as follow:

I'm trying to look for value of property "Nombre proveedor":

And this is the result.

checking share container in docker on route $tomcatHome/shared/classes/alfresco/web-extension/share-config-custom.xml I have this configuration.

I checked that properties in this files match the propereties in my content model.

Much appreciate your help

angelborroy
Alfresco Employee

Re: Alfresco 6.0 advanced custom search query

I don't know what are you trying to configure, really.

Take a look at this presentation and you'll get some additional information on configuring Search in Share: http://beecon.buzz/2017/assets/files/F20/Leveraging%20search%20in%20Share.pdf 

Hyland Developer Evangelist
pedrohernandez
Active Member II

Re: Alfresco 6.0 advanced custom search query

Thanks Angel,

Sorry if I wasn't totally specific, So looking at the presentation on page 21, apparently the default "Search on metadata" the default is this one:

#searchTerm=&query={"prop_cm_name":"project","prop_cm_title":"","prop_cm_description":"","prop_mimetype":"","prop_cm_modified-daterange":"","prop_cm_modifier":"","datatype":"cm:content"}&scope=all_sites&sortField=cm:name&sortAscending=truefacetFilters={http://www.alfresco.org/model/content/1.0}creator|abeecher

So, I would like to add a custom searchable metadata so when I search for a custom aspect value it will show all the files containing the above examples values. example: "nombre_proveedor:gruposolux"

Thanks for your help again.

cesarista
Customer

Re: Alfresco 6.0 advanced custom search query

Wow, I will check it.

Regards.

--C.

cesarista
Customer

Re: Alfresco 6.0 advanced custom search query

Normally the OOTB options for search custom metadata are the following:

 0 - Use Alfresco FTS syntax

 1 - Use custom facets as filters over full text searches (probably only nombre_proveedor and nombre_cliente)

 2 - Extend share webscripts config search.get.config.xml or live-search-docs.get.config.xml with your custom metadata.

 3 - Create a custom form in Alfresco Advanced Search for a custom type in share-config-custom.xml

 4 - A smart folder with predefined queries about your custom metadata.

Regards.

--C.

pedrohernandez
Active Member II

Re: Alfresco 6.0 advanced custom search query

Thank you Cesar,

So, Trying your suggestions I found the following.

Option 0: I have to investigate a little more about FTS syntax didn't know about it.

Option 1: I tried this one but when defining the index of the aspect when I select free text in the property it doesn't show on the filters on search management.

Option 2: looking at the files, apparentlly those files are for alfresco old version, I don't find those files in my instalation of alfresco 6.0.

Option 3: I created a custom form in Alfresco Advanced Search and it shows the form for my custom type, but when searching for any value there, it shows not result.

cesarista
Customer

Re: Alfresco 6.0 advanced custom search query

Considering that your indices are correctly working, so you can do searches:

- Option 1: You should define the index of a property for a given aspect. For a filter, it is not a good idea to use free text for a property like "nombre del cliente", because if is not indexed as an exact match or coincidence the name will be tokenised and splitted in parts. So the filtered terms may appear incorrect or confusing. For appearing in filters sometimes you need to have several documents too.

- Option 2: Probably you are looking wrong, look inside alfresco/WEB-INF/lib/alfresco-share-services-6.0.x.jar

- Option 3: Normally you need to define search configuration for a custom type, but we only saw that you defined an aspect. Try to define first as less properties as possible for your custom type, in your form. Then you should have content with the type and the aspect applied.

Hope this helps.

--C.