RM Search enhancements.

- KEYWORDS macro changed to keywords
 - Added macros without cm: namespace for common cm attributes
 - Added macros without recordSearch prefix for search roll-up attributes
 - Made rma default search namespace so say "originator:someone" will work rather than "rma:originator:someone"
 - Fix to minor UI issues when empty results shown

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@16781 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Kevin Roast
2009-10-08 20:24:18 +00:00
parent 30c486621a
commit a2186f9662

View File

@@ -436,7 +436,8 @@ public class Search extends BaseScopableProcessorExtension
* language: string, optional, one of: lucene, xpath, jcr-xpath, fts-alfresco - defaults to 'lucene'
* templates: [], optional, Array of query language template objects (see below) - if supported by the language
* sort: [], optional, Array of sort column objects (see below) - if supported by the language
* page: object optional, paging information object (see below) - if supported by the language
* page: object, optional, paging information object (see below) - if supported by the language
* namespace: string optional, the default namespace for properties
* }
*
* sort
@@ -489,6 +490,7 @@ public class Search extends BaseScopableProcessorExtension
String language = (String)def.get("language");
List<Map<Serializable, Serializable>> sort = (List<Map<Serializable, Serializable>>)def.get("sort");
Map<Serializable, Serializable> page = (Map<Serializable, Serializable>)def.get("page");
String namespace = (String)def.get("namespace");
// extract supplied values
@@ -553,6 +555,10 @@ public class Search extends BaseScopableProcessorExtension
sp.addStore(store != null ? new StoreRef(store) : this.storeRef);
sp.setLanguage(language != null ? language : SearchService.LANGUAGE_LUCENE);
sp.setQuery(query);
if (namespace != null)
{
sp.setNamespace(namespace);
}
if (maxResults > 0)
{
sp.setLimit(maxResults);