AnsweredAssumed Answered

Search sort_by with multiple properties

Question asked by openpj Moderator on Sep 24, 2008
I have a webscript FTL dedicated to render all the search results.
This webscript (FTL) executes the query and I would like to add a sort_by depending on multiple properties of the content model.
I have modified the default content model correctly and all the searches works well.

Now I have implemented this order condition in this way:

<#assign docs=companyhome.childrenByLuceneSearch[query]?sort_by(["properties","cm:MyCustomProperty1"], ["properties","cm:MyCustomProperty2"])>
But in this way it seems not ordering well, it seems to order only on the first property MyCustomProperty1.

Can I use the sort_by instruction with multiple properties of the custom content model?
Perhaps the notation is wrong?

Thank you for your support.

Outcomes