Web Scripts:

- filename convention changed from _ to .

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@5793 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
David Caruana
2007-05-29 09:32:04 +00:00
parent c3b15747fa
commit 3e0cee8351
50 changed files with 105 additions and 75 deletions

View File

@@ -268,14 +268,17 @@ public class RepoStore implements WebScriptStore, ApplicationContextAware, Appli
int baseDirLength = baseDir.length() +1;
List<String> documentPaths = new ArrayList<String>();
String query = "PATH:\"" + repoPath + "//*\" AND @cm\\:name:\"*_desc.xml\"";
String query = "PATH:\"" + repoPath + "//*\" AND @cm\\:name:\"*desc.xml\"";
ResultSet resultSet = searchService.query(repoStore, SearchService.LANGUAGE_LUCENE, query);
List<NodeRef> nodes = resultSet.getNodeRefs();
for (NodeRef nodeRef : nodes)
{
String nodeDir = getPath(nodeRef);
String documentPath = nodeDir.substring(baseDirLength);
documentPaths.add(documentPath);
if (nodeDir.endsWith(".desc.xml"))
{
String documentPath = nodeDir.substring(baseDirLength);
documentPaths.add(documentPath);
}
}
return documentPaths.toArray(new String[documentPaths.size()]);