From bd0b9c5fcd7debc47e0c68f25c8c90fbac177460 Mon Sep 17 00:00:00 2001 From: Kevin Roast Date: Thu, 7 Jun 2007 11:44:20 +0000 Subject: [PATCH] OpenSearch results shown in the web-client now have an icon to pop-up the AJAX document preview panel for the item. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@5878 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261 --- .../repository/keywordsearch.get.atom.ftl | 3 ++- source/web/css/opensearch.css | 3 +-- source/web/scripts/ajax/opensearch.js | 15 ++++++++++++--- 3 files changed, 15 insertions(+), 6 deletions(-) diff --git a/config/alfresco/templates/webscripts/org/alfresco/repository/keywordsearch.get.atom.ftl b/config/alfresco/templates/webscripts/org/alfresco/repository/keywordsearch.get.atom.ftl index a3d9c9e5bd..927afc6d27 100644 --- a/config/alfresco/templates/webscripts/org/alfresco/repository/keywordsearch.get.atom.ftl +++ b/config/alfresco/templates/webscripts/org/alfresco/repository/keywordsearch.get.atom.ftl @@ -1,5 +1,5 @@ - + Alfresco (${server.edition}) Alfresco Keyword Search: ${search.searchTerms} ${xmldate(date)} @@ -29,6 +29,7 @@ ${absurl(url.context)}${row.icon16} <#comment>TODO: What's the standard for entry icons? urn:uuid:${row.id} + ${row.nodeRef} ${xmldate(row.properties.modified)} ${row.properties.description!""} diff --git a/source/web/css/opensearch.css b/source/web/css/opensearch.css index 28f34b3021..1f8cd72adc 100644 --- a/source/web/css/opensearch.css +++ b/source/web/css/opensearch.css @@ -64,8 +64,7 @@ .osResultIcon { - padding-right: 6px; - padding-top: 6px; + padding: 4px 4px 0px 4px; } .osResultTitle diff --git a/source/web/scripts/ajax/opensearch.js b/source/web/scripts/ajax/opensearch.js index 3836aeecc0..5d277d8bb8 100644 --- a/source/web/scripts/ajax/opensearch.js +++ b/source/web/scripts/ajax/opensearch.js @@ -467,7 +467,7 @@ Alfresco.OpenSearchClient.prototype = { if (link != null) { - sb[sb.length] = ""; } @@ -476,13 +476,22 @@ Alfresco.OpenSearchClient.prototype = { sb[sb.length] = ""; } + var noderef = Alfresco.Dom.getElementTextByTagNameNS(elResult, "http://www.alfresco.org/opensearch/1.0/", "alf", "noderef"); + if (noderef != null) + { + sb[sb.length] = ""; + sb[sb.length] = ""; + sb[sb.length] = ""; + } } - sb[sb.length] = "
"; + sb[sb.length] = "
"; if (summary != null) { + sb[sb.length] = "
"; sb[sb.length] = summary; + sb[sb.length] = "
"; } - sb[sb.length] = ""; + sb[sb.length] = ""; } // close the table