Merged HEAD-BUG-FIX (4.3/Cloud) to HEAD (4.3/Cloud)

57482: Merged V4.2-BUG-FIX (4.2.1) to HEAD-BUG-FIX (Cloud/4.3)
      57300: Merged V4.1-BUG-FIX (4.1.7) to V4.2-BUG-FIX (4.2.1)
         57249: Merged DEV to V4.1-BUG-FIX (4.1.7)
            57248: MNT-8557: Escaping space in JS search query sort column ID
               Added explicit space replacing in SOLR url query and reverse replacing to get property definition.


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@61824 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Alan Davis
2014-02-11 20:48:20 +00:00
parent 0995ee2824
commit 8f2dbdb642

View File

@@ -291,7 +291,8 @@ public class SolrQueryHTTPClient implements BeanFactoryAware
{
sortBuffer.append(encoder.encode(", ", "UTF-8"));
}
sortBuffer.append(encoder.encode(sortDefinition.getField(), "UTF-8")).append(encoder.encode(" ", "UTF-8"));
// MNT-8557 fix, manually replace ' ' with '%20'
sortBuffer.append(encoder.encode(sortDefinition.getField().replaceAll(" ", "%20"), "UTF-8")).append(encoder.encode(" ", "UTF-8"));
if (sortDefinition.isAscending())
{
sortBuffer.append(encoder.encode("asc", "UTF-8"));