Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #91 from atmire/discovery-default

[DS-1272] Setting discovery to be the default search/browse engine
  • Loading branch information...
commit 235e1a1309d1d59fb6718ae8989711dd10791d95 2 parents 6bb3212 + 2cb2fa0
@mdiggory mdiggory authored
Showing with 421 additions and 490 deletions.
  1. +2 −51 dspace-xmlui/src/main/java/org/dspace/app/xmlui/aspect/artifactbrowser/CollectionViewer.java
  2. +3 −53 dspace-xmlui/src/main/java/org/dspace/app/xmlui/aspect/artifactbrowser/CommunityViewer.java
  3. +93 −0 dspace-xmlui/src/main/java/org/dspace/app/xmlui/aspect/browseArtifacts/CollectionBrowse.java
  4. +93 −0 dspace-xmlui/src/main/java/org/dspace/app/xmlui/aspect/browseArtifacts/CommunityBrowse.java
  5. +48 −15 .../main/java/org/dspace/app/xmlui/aspect/discovery/{CollectionSearch.java → CollectionSearchBrowse.java}
  6. +51 −23 ...rc/main/java/org/dspace/app/xmlui/aspect/discovery/{CommunitySearch.java → CommunitySearchBrowse.java}
  7. +107 −3 dspace-xmlui/src/main/java/org/dspace/app/xmlui/aspect/discovery/Navigation.java
  8. +0 −28 dspace-xmlui/src/main/resources/aspects/ArtifactBrowser/dspace-home.xml
  9. +0 −295 dspace-xmlui/src/main/resources/aspects/ArtifactBrowser/sitemap.xmap
  10. +4 −0 dspace-xmlui/src/main/resources/aspects/BrowseArtifacts/sitemap.xmap
  11. +8 −4 dspace-xmlui/src/main/resources/aspects/Discovery/sitemap.xmap
  12. +1 −3 dspace/config/dspace.cfg
  13. +7 −0 dspace/config/launcher.xml
  14. +1 −1  dspace/config/modules/discovery.cfg
  15. +3 −14 dspace/config/xmlui.xconf
View
53 dspace-xmlui/src/main/java/org/dspace/app/xmlui/aspect/artifactbrowser/CollectionViewer.java
@@ -10,8 +10,6 @@
import java.io.IOException;
import java.io.Serializable;
import java.sql.SQLException;
-import java.util.Map;
-import java.util.HashMap;
import org.apache.cocoon.caching.CacheableProcessingComponent;
import org.apache.cocoon.util.HashUtil;
@@ -25,11 +23,8 @@
import org.dspace.app.xmlui.wing.element.Body;
import org.dspace.app.xmlui.wing.element.Division;
import org.dspace.app.xmlui.wing.element.ReferenceSet;
-import org.dspace.app.xmlui.wing.element.List;
import org.dspace.app.xmlui.wing.element.PageMeta;
import org.dspace.authorize.AuthorizeException;
-import org.dspace.browse.BrowseException;
-import org.dspace.browse.BrowseIndex;
import org.dspace.content.Collection;
import org.dspace.content.DSpaceObject;
import org.dspace.core.ConfigurationManager;
@@ -54,19 +49,6 @@
public static final Message T_untitled =
message("xmlui.general.untitled");
-
- private static final Message T_head_browse =
- message("xmlui.ArtifactBrowser.CollectionViewer.head_browse");
-
- private static final Message T_browse_titles =
- message("xmlui.ArtifactBrowser.CollectionViewer.browse_titles");
-
- private static final Message T_browse_authors =
- message("xmlui.ArtifactBrowser.CollectionViewer.browse_authors");
-
- private static final Message T_browse_dates =
- message("xmlui.ArtifactBrowser.CollectionViewer.browse_dates");
-
/** Cached validity object */
private SourceValidity validity;
@@ -218,41 +200,10 @@ public void addBody(Body body) throws SAXException, WingException,
home.setHead(name);
}
- // The search / browse box.
+ // The search / browse box placeholder, this division will be populated either in the browse or discovery aspect
{
-// TODO: move browse stuff out of here
- Division search = home.addDivision("collection-search-browse",
+ home.addDivision("collection-search-browse",
"secondary search-browse");
-
- // Browse by list
- Division browseDiv = search.addDivision("collection-browse","secondary browse");
- List browse = browseDiv.addList("collection-browse", List.TYPE_SIMPLE,
- "collection-browse");
- browse.setHead(T_head_browse);
- String url = contextPath + "/handle/" + collection.getHandle();
-
- try
- {
- // Get a Map of all the browse tables
- BrowseIndex[] bis = BrowseIndex.getBrowseIndices();
- for (BrowseIndex bix : bis)
- {
- // Create a Map of the query parameters for this link
- Map<String, String> queryParams = new HashMap<String, String>();
-
- queryParams.put("type", bix.getName());
-
- // Add a link to this browse
- browse.addItemXref(super.generateURL(url + "/browse", queryParams),
- message("xmlui.ArtifactBrowser.Navigation.browse_" + bix.getName()));
- }
- }
- catch (BrowseException bex)
- {
- browse.addItemXref(url + "/browse?type=title",T_browse_titles);
- browse.addItemXref(url + "/browse?type=author",T_browse_authors);
- browse.addItemXref(url + "/browse?type=dateissued",T_browse_dates);
- }
}
// Add the reference
View
56 dspace-xmlui/src/main/java/org/dspace/app/xmlui/aspect/artifactbrowser/CommunityViewer.java
@@ -10,8 +10,6 @@
import java.io.IOException;
import java.io.Serializable;
import java.sql.SQLException;
-import java.util.Map;
-import java.util.HashMap;
import org.apache.cocoon.caching.CacheableProcessingComponent;
import org.apache.cocoon.util.HashUtil;
@@ -25,12 +23,9 @@
import org.dspace.app.xmlui.wing.element.Body;
import org.dspace.app.xmlui.wing.element.Division;
import org.dspace.app.xmlui.wing.element.ReferenceSet;
-import org.dspace.app.xmlui.wing.element.List;
import org.dspace.app.xmlui.wing.element.Reference;
import org.dspace.app.xmlui.wing.element.PageMeta;
import org.dspace.authorize.AuthorizeException;
-import org.dspace.browse.BrowseException;
-import org.dspace.browse.BrowseIndex;
import org.dspace.browse.ItemCountException;
import org.dspace.browse.ItemCounter;
import org.dspace.content.Collection;
@@ -59,20 +54,7 @@
public static final Message T_untitled =
message("xmlui.general.untitled");
- private static final Message T_head_browse =
- message("xmlui.ArtifactBrowser.CommunityViewer.head_browse");
-
- private static final Message T_browse_titles =
- message("xmlui.ArtifactBrowser.CommunityViewer.browse_titles");
-
- private static final Message T_browse_authors =
- message("xmlui.ArtifactBrowser.CommunityViewer.browse_authors");
-
- private static final Message T_browse_dates =
- message("xmlui.ArtifactBrowser.CommunityViewer.browse_dates");
-
-
- private static final Message T_head_sub_communities =
+ private static final Message T_head_sub_communities =
message("xmlui.ArtifactBrowser.CommunityViewer.head_sub_communities");
private static final Message T_head_sub_collections =
@@ -261,42 +243,10 @@ public void addBody(Body body) throws SAXException, WingException,
home.setHead(name);
}
- // The search / browse box.
+ // The search / browse box placeholder, this division will be populated either in the browse or discovery aspect
{
- Division search = home.addDivision("community-search-browse",
+ home.addDivision("community-search-browse",
"secondary search-browse");
-
-
-// TODO: move browse stuff out of here
- // Browse by list
- Division browseDiv = search.addDivision("community-browse","secondary browse");
- List browse = browseDiv.addList("community-browse", List.TYPE_SIMPLE,
- "community-browse");
- browse.setHead(T_head_browse);
- String url = contextPath + "/handle/" + community.getHandle();
-
- try
- {
- // Get a Map of all the browse tables
- BrowseIndex[] bis = BrowseIndex.getBrowseIndices();
- for (BrowseIndex bix : bis)
- {
- // Create a Map of the query parameters for this link
- Map<String, String> queryParams = new HashMap<String, String>();
-
- queryParams.put("type", bix.getName());
-
- // Add a link to this browse
- browse.addItemXref(super.generateURL(url + "/browse", queryParams),
- message("xmlui.ArtifactBrowser.Navigation.browse_" + bix.getName()));
- }
- }
- catch (BrowseException bex)
- {
- browse.addItemXref(url + "/browse?type=title",T_browse_titles);
- browse.addItemXref(url + "/browse?type=author",T_browse_authors);
- browse.addItemXref(url + "/browse?type=dateissued",T_browse_dates);
- }
}
// Add main reference:
View
93 dspace-xmlui/src/main/java/org/dspace/app/xmlui/aspect/browseArtifacts/CollectionBrowse.java
@@ -0,0 +1,93 @@
+/**
+ * The contents of this file are subject to the license and copyright
+ * detailed in the LICENSE and NOTICE files at the root of the source
+ * tree and available online at
+ *
+ * http://www.dspace.org/license/
+ */
+package org.dspace.app.xmlui.aspect.browseArtifacts;
+
+import org.apache.cocoon.ProcessingException;
+import org.dspace.app.xmlui.cocoon.AbstractDSpaceTransformer;
+import org.dspace.app.xmlui.utils.HandleUtil;
+import org.dspace.app.xmlui.wing.Message;
+import org.dspace.app.xmlui.wing.WingException;
+import org.dspace.app.xmlui.wing.element.Body;
+import org.dspace.app.xmlui.wing.element.Division;
+import org.dspace.app.xmlui.wing.element.List;
+import org.dspace.authorize.AuthorizeException;
+import org.dspace.browse.BrowseException;
+import org.dspace.browse.BrowseIndex;
+import org.dspace.content.Collection;
+import org.dspace.content.DSpaceObject;
+import org.xml.sax.SAXException;
+
+import java.io.IOException;
+import java.sql.SQLException;
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ * Renders the browse links for a collection
+ *
+ * @author Kevin Van de Velde (kevin at atmire dot com)
+ * @author Mark Diggory (markd at atmire dot com)
+ * @author Ben Bosman (ben at atmire dot com)
+ */
+public class CollectionBrowse extends AbstractDSpaceTransformer {
+
+ private static final Message T_head_browse =
+ message("xmlui.ArtifactBrowser.CollectionViewer.head_browse");
+
+ private static final Message T_browse_titles =
+ message("xmlui.ArtifactBrowser.CollectionViewer.browse_titles");
+
+ private static final Message T_browse_authors =
+ message("xmlui.ArtifactBrowser.CollectionViewer.browse_authors");
+
+ private static final Message T_browse_dates =
+ message("xmlui.ArtifactBrowser.CollectionViewer.browse_dates");
+
+ @Override
+ public void addBody(Body body) throws SAXException, WingException, SQLException, IOException, AuthorizeException, ProcessingException {
+ DSpaceObject dso = HandleUtil.obtainHandle(objectModel);
+ if (!(dso instanceof Collection))
+ {
+ return;
+ }
+
+ // Set up the major variables
+ Collection collection = (Collection) dso;
+
+ Division home = body.addDivision("collection-home", "primary repository collection");
+
+ Division search = home.addDivision("collection-search-browse",
+ "secondary search-browse");
+
+ // Browse by list
+ Division browseDiv = search.addDivision("collection-browse", "secondary browse");
+ List browse = browseDiv.addList("collection-browse", List.TYPE_SIMPLE,
+ "collection-browse");
+ browse.setHead(T_head_browse);
+ String url = contextPath + "/handle/" + collection.getHandle();
+
+ try {
+ // Get a Map of all the browse tables
+ BrowseIndex[] bis = BrowseIndex.getBrowseIndices();
+ for (BrowseIndex bix : bis) {
+ // Create a Map of the query parameters for this link
+ Map<String, String> queryParams = new HashMap<String, String>();
+
+ queryParams.put("type", bix.getName());
+
+ // Add a link to this browse
+ browse.addItemXref(generateURL(url + "/browse", queryParams),
+ message("xmlui.ArtifactBrowser.Navigation.browse_" + bix.getName()));
+ }
+ } catch (BrowseException bex) {
+ browse.addItemXref(url + "/browse?type=title", T_browse_titles);
+ browse.addItemXref(url + "/browse?type=author", T_browse_authors);
+ browse.addItemXref(url + "/browse?type=dateissued", T_browse_dates);
+ }
+ }
+}
View
93 dspace-xmlui/src/main/java/org/dspace/app/xmlui/aspect/browseArtifacts/CommunityBrowse.java
@@ -0,0 +1,93 @@
+/**
+ * The contents of this file are subject to the license and copyright
+ * detailed in the LICENSE and NOTICE files at the root of the source
+ * tree and available online at
+ *
+ * http://www.dspace.org/license/
+ */
+package org.dspace.app.xmlui.aspect.browseArtifacts;
+
+import org.apache.cocoon.ProcessingException;
+import org.dspace.app.xmlui.cocoon.AbstractDSpaceTransformer;
+import org.dspace.app.xmlui.utils.HandleUtil;
+import org.dspace.app.xmlui.wing.Message;
+import org.dspace.app.xmlui.wing.WingException;
+import org.dspace.app.xmlui.wing.element.Body;
+import org.dspace.app.xmlui.wing.element.Division;
+import org.dspace.app.xmlui.wing.element.List;
+import org.dspace.authorize.AuthorizeException;
+import org.dspace.browse.BrowseException;
+import org.dspace.browse.BrowseIndex;
+import org.dspace.content.Community;
+import org.dspace.content.DSpaceObject;
+import org.xml.sax.SAXException;
+
+import java.io.IOException;
+import java.sql.SQLException;
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ * Renders the browse links for a community
+ *
+ * @author Kevin Van de Velde (kevin at atmire dot com)
+ * @author Mark Diggory (markd at atmire dot com)
+ * @author Ben Bosman (ben at atmire dot com)
+ */
+public class CommunityBrowse extends AbstractDSpaceTransformer {
+
+ private static final Message T_head_browse =
+ message("xmlui.ArtifactBrowser.CommunityViewer.head_browse");
+
+ private static final Message T_browse_titles =
+ message("xmlui.ArtifactBrowser.CommunityViewer.browse_titles");
+
+ private static final Message T_browse_authors =
+ message("xmlui.ArtifactBrowser.CommunityViewer.browse_authors");
+
+ private static final Message T_browse_dates =
+ message("xmlui.ArtifactBrowser.CommunityViewer.browse_dates");
+
+ @Override
+ public void addBody(Body body) throws SAXException, WingException, SQLException, IOException, AuthorizeException, ProcessingException {
+ DSpaceObject dso = HandleUtil.obtainHandle(objectModel);
+ if (!(dso instanceof Community))
+ {
+ return;
+ }
+
+ // Set up the major variables
+ Community community = (Community) dso;
+
+ Division home = body.addDivision("community-home", "primary repository community");
+
+ Division search = home.addDivision("community-search-browse",
+ "secondary search-browse");
+
+ // Browse by list
+ Division browseDiv = search.addDivision("community-browse", "secondary browse");
+ List browse = browseDiv.addList("community-browse", List.TYPE_SIMPLE,
+ "community-browse");
+ browse.setHead(T_head_browse);
+ String url = contextPath + "/handle/" + community.getHandle();
+
+ try {
+ // Get a Map of all the browse tables
+ BrowseIndex[] bis = BrowseIndex.getBrowseIndices();
+ for (BrowseIndex bix : bis) {
+ // Create a Map of the query parameters for this link
+ Map<String, String> queryParams = new HashMap<String, String>();
+
+ queryParams.put("type", bix.getName());
+
+ // Add a link to this browse
+ browse.addItemXref(generateURL(url + "/browse", queryParams),
+ message("xmlui.ArtifactBrowser.Navigation.browse_" + bix.getName()));
+ }
+ } catch (BrowseException bex) {
+ browse.addItemXref(url + "/browse?type=title", T_browse_titles);
+ browse.addItemXref(url + "/browse?type=author", T_browse_authors);
+ browse.addItemXref(url + "/browse?type=dateissued", T_browse_dates);
+ }
+ }
+}
View
63 .../app/xmlui/aspect/discovery/CollectionSearch.java → ...mlui/aspect/discovery/CollectionSearchBrowse.java
@@ -10,6 +10,8 @@
import java.io.IOException;
import java.io.Serializable;
import java.sql.SQLException;
+import java.util.HashMap;
+import java.util.Map;
import org.apache.cocoon.caching.CacheableProcessingComponent;
import org.apache.cocoon.util.HashUtil;
@@ -25,16 +27,20 @@
import org.dspace.content.Collection;
import org.dspace.content.DSpaceObject;
import org.dspace.core.ConfigurationManager;
+import org.dspace.discovery.SearchUtils;
+import org.dspace.discovery.configuration.DiscoveryConfiguration;
+import org.dspace.discovery.configuration.DiscoveryConfigurationParameters;
+import org.dspace.discovery.configuration.DiscoverySearchFilterFacet;
import org.xml.sax.SAXException;
/**
- * Renders the search box for a collection
+ * Renders the search box & browse urls for a collection
*
* @author Kevin Van de Velde (kevin at atmire dot com)
* @author Mark Diggory (markd at atmire dot com)
* @author Ben Bosman (ben at atmire dot com)
*/
-public class CollectionSearch extends AbstractDSpaceTransformer implements CacheableProcessingComponent
+public class CollectionSearchBrowse extends AbstractDSpaceTransformer implements CacheableProcessingComponent
{
/** Language Strings */
private static final Message T_dspace_home =
@@ -43,6 +49,9 @@
private static final Message T_full_text_search =
message("xmlui.ArtifactBrowser.CollectionViewer.full_text_search");
+ private static final Message T_head_browse =
+ message("xmlui.ArtifactBrowser.CommunityViewer.head_browse");
+
private static final Message T_go =
message("xmlui.general.go");
@@ -219,11 +228,38 @@ public void addBody(Body body) throws SAXException, WingException,
// The search / browse box.
{
- Division search = home.addDivision("collection-search-browse",
+ Division searchBrowseDivision = home.addDivision("collection-search-browse",
"secondary search-browse");
+ List browse = searchBrowseDivision.addList("community-browse", List.TYPE_SIMPLE,
+ "community-browse");
+ browse.setHead(T_head_browse);
+ String url = contextPath + "/handle/" + collection.getHandle();
+
+ addBrowseTitle(browse, url);
+ // Get a Map of all the browse tables
+ DiscoveryConfiguration discoveryConfiguration = SearchUtils.getDiscoveryConfiguration(collection);
+ java.util.List<DiscoverySearchFilterFacet> facets = discoveryConfiguration.getSidebarFacets();
+ for (DiscoverySearchFilterFacet facet : facets)
+ {
+ if(facet.getType().equals(DiscoveryConfigurationParameters.TYPE_DATE))
+ {
+ //Browse by date isn't support for our facets.
+ continue;
+ }
+
+ // Create a Map of the query parameters for this link
+ Map<String, String> queryParams = new HashMap<String, String>();
+
+ queryParams.put("field", facet.getIndexFieldName());
+
+ // Add a link to this browse
+ browse.addItemXref(generateURL(url + "/search-filter", queryParams),
+ message("xmlui.ArtifactBrowser.Navigation.browse_" + facet.getIndexFieldName()));
+ }
+
// Search query
- Division query = search.addInteractiveDivision("collection-search",
+ Division query = searchBrowseDivision.addInteractiveDivision("collection-search",
contextPath + "/handle/" + collection.getHandle() + "/discover",
Division.METHOD_POST, "secondary search");
@@ -233,21 +269,18 @@ public void addBody(Body body) throws SAXException, WingException,
para.addText("query");
para.addContent(" ");
para.addButton("submit").setValue(T_go);
- //query.addPara().addXref(contextPath + "/handle/" + collection.getHandle()+ "/advanced-search", T_advanced_search_link);
-
- // Browse by list
- //Division browseDiv = search.addDivision("collection-browse","secondary browse");
- //List browse = browseDiv.addList("collection-browse", List.TYPE_SIMPLE,
- // "collection-browse");
- //browse.setHead(T_head_browse);
- //String url = contextPath + "/handle/" + collection.getHandle();
- //browse.addItemXref(url + "/browse?type=title",T_browse_titles);
- //browse.addItemXref(url + "/browse?type=author",T_browse_authors);
- //browse.addItemXref(url + "/browse?type=dateissued",T_browse_dates);
}
}
+ private void addBrowseTitle(List browse, String url) throws WingException {
+ Map<String, String> browseTitleParams = new HashMap<String, String>();
+ browseTitleParams.put("sort_by", "dc.title_sort");
+ browseTitleParams.put("order", "asc");
+ browse.addItemXref(generateURL(url + "/discover", browseTitleParams),
+ message("xmlui.ArtifactBrowser.AdvancedSearch.type_title"));
+ }
+
/**
* Recycle
View
74 ...e/app/xmlui/aspect/discovery/CommunitySearch.java → ...xmlui/aspect/discovery/CommunitySearchBrowse.java
@@ -10,6 +10,8 @@
import java.io.IOException;
import java.io.Serializable;
import java.sql.SQLException;
+import java.util.HashMap;
+import java.util.Map;
import org.apache.cocoon.caching.CacheableProcessingComponent;
import org.apache.cocoon.util.HashUtil;
@@ -21,32 +23,36 @@
import org.dspace.app.xmlui.utils.UIException;
import org.dspace.app.xmlui.wing.Message;
import org.dspace.app.xmlui.wing.WingException;
-import org.dspace.app.xmlui.wing.element.Body;
-import org.dspace.app.xmlui.wing.element.Division;
-import org.dspace.app.xmlui.wing.element.PageMeta;
-import org.dspace.app.xmlui.wing.element.Para;
+import org.dspace.app.xmlui.wing.element.*;
import org.dspace.authorize.AuthorizeException;
import org.dspace.content.Collection;
import org.dspace.content.Community;
import org.dspace.content.DSpaceObject;
import org.dspace.core.LogManager;
+import org.dspace.discovery.SearchUtils;
+import org.dspace.discovery.configuration.DiscoveryConfiguration;
+import org.dspace.discovery.configuration.DiscoveryConfigurationParameters;
+import org.dspace.discovery.configuration.DiscoverySearchFilterFacet;
import org.xml.sax.SAXException;
/**
- * Renders the search box for a community
+ * Renders the search box & browse urls for a community
*
* @author Kevin Van de Velde (kevin at atmire dot com)
* @author Mark Diggory (markd at atmire dot com)
* @author Ben Bosman (ben at atmire dot com)
*/
-public class CommunitySearch extends AbstractDSpaceTransformer implements CacheableProcessingComponent
+public class CommunitySearchBrowse extends AbstractDSpaceTransformer implements CacheableProcessingComponent
{
- private static final Logger log = Logger.getLogger(CommunitySearch.class);
+ private static final Logger log = Logger.getLogger(CommunitySearchBrowse.class);
/** Language Strings */
private static final Message T_full_text_search =
message("xmlui.ArtifactBrowser.CommunityViewer.full_text_search");
+ private static final Message T_head_browse =
+ message("xmlui.ArtifactBrowser.CommunityViewer.head_browse");
+
private static final Message T_go =
message("xmlui.general.go");
@@ -181,11 +187,38 @@ public void addBody(Body body) throws SAXException, WingException,
// The search / browse box.
{
- Division search = home.addDivision("community-search-browse",
+ Division searchBrowseDivision = home.addDivision("community-search-browse",
"secondary search-browse");
+ List browse = searchBrowseDivision.addList("community-browse", List.TYPE_SIMPLE,
+ "community-browse");
+ browse.setHead(T_head_browse);
+ String url = contextPath + "/handle/" + community.getHandle();
+
+ addBrowseTitle(browse, url);
+ // Get a Map of all the browse tables
+ DiscoveryConfiguration discoveryConfiguration = SearchUtils.getDiscoveryConfiguration(community);
+ java.util.List<DiscoverySearchFilterFacet> facets = discoveryConfiguration.getSidebarFacets();
+ for (DiscoverySearchFilterFacet facet : facets)
+ {
+ if(facet.getType().equals(DiscoveryConfigurationParameters.TYPE_DATE))
+ {
+ //Browse by date isn't support for our facets.
+ continue;
+ }
+
+ // Create a Map of the query parameters for this link
+ Map<String, String> queryParams = new HashMap<String, String>();
+
+ queryParams.put("field", facet.getIndexFieldName());
+
+ // Add a link to this browse
+ browse.addItemXref(generateURL(url + "/search-filter", queryParams),
+ message("xmlui.ArtifactBrowser.Navigation.browse_" + facet.getIndexFieldName()));
+ }
+
// Search query
- Division query = search.addInteractiveDivision("community-search",
+ Division query = searchBrowseDivision.addInteractiveDivision("community-search",
contextPath + "/handle/" + community.getHandle() + "/discover",
Division.METHOD_POST, "secondary search");
@@ -196,20 +229,18 @@ public void addBody(Body body) throws SAXException, WingException,
para.addContent(" ");
para.addButton("submit").setValue(T_go);
//query.addPara().addXref(contextPath + "/handle/" + community.getHandle() + "/advanced-search", T_advanced_search_link);
-
- // Browse by list
- // Division browseDiv = search.addDivision("community-browse","secondary browse");
- // List browse = browseDiv.addList("community-browse", List.TYPE_SIMPLE,
- // "community-browse");
- // browse.setHead(T_head_browse);
- // String url = contextPath + "/handle/" + community.getHandle();
- // browse.addItemXref(url + "/browse?type=title",T_browse_titles);
- // browse.addItemXref(url + "/browse?type=author",T_browse_authors);
-// browse.addItemXref(url + "/browse?type=dateissued",T_browse_dates);
}
}
+ private void addBrowseTitle(List browse, String url) throws WingException {
+ Map<String, String> browseTitleParams = new HashMap<String, String>();
+ browseTitleParams.put("sort_by", "dc.title_sort");
+ browseTitleParams.put("order", "asc");
+ browse.addItemXref(generateURL(url + "/discover", browseTitleParams),
+ message("xmlui.ArtifactBrowser.AdvancedSearch.type_title"));
+ }
+
/**
* Recycle
*/
@@ -219,7 +250,4 @@ public void recycle()
this.validity = null;
super.recycle();
}
-
-
-
-}
+}
View
110 dspace-xmlui/src/main/java/org/dspace/app/xmlui/aspect/discovery/Navigation.java
@@ -10,6 +10,8 @@
import java.io.IOException;
import java.io.Serializable;
import java.sql.SQLException;
+import java.util.HashMap;
+import java.util.Map;
import org.apache.cocoon.caching.CacheableProcessingComponent;
import org.apache.cocoon.environment.ObjectModelHelper;
@@ -20,11 +22,20 @@
import org.dspace.app.xmlui.cocoon.AbstractDSpaceTransformer;
import org.dspace.app.xmlui.utils.HandleUtil;
import org.dspace.app.xmlui.utils.UIException;
+import org.dspace.app.xmlui.wing.Message;
import org.dspace.app.xmlui.wing.WingException;
+import org.dspace.app.xmlui.wing.element.List;
import org.dspace.app.xmlui.wing.element.Options;
import org.dspace.app.xmlui.wing.element.PageMeta;
import org.dspace.authorize.AuthorizeException;
+import org.dspace.content.Collection;
+import org.dspace.content.Community;
import org.dspace.content.DSpaceObject;
+import org.dspace.content.Item;
+import org.dspace.discovery.SearchUtils;
+import org.dspace.discovery.configuration.DiscoveryConfiguration;
+import org.dspace.discovery.configuration.DiscoveryConfigurationParameters;
+import org.dspace.discovery.configuration.DiscoverySearchFilterFacet;
import org.xml.sax.SAXException;
/**
@@ -36,6 +47,22 @@
*/
public class Navigation extends AbstractDSpaceTransformer implements CacheableProcessingComponent
{
+ /** Language Strings */
+ private static final Message T_head_all_of_dspace =
+ message("xmlui.ArtifactBrowser.Navigation.head_all_of_dspace");
+
+ private static final Message T_head_browse =
+ message("xmlui.ArtifactBrowser.Navigation.head_browse");
+
+ private static final Message T_communities_and_collections =
+ message("xmlui.ArtifactBrowser.Navigation.communities_and_collections");
+
+ private static final Message T_head_this_collection =
+ message("xmlui.ArtifactBrowser.Navigation.head_this_collection");
+
+ private static final Message T_head_this_community =
+ message("xmlui.ArtifactBrowser.Navigation.head_this_community");
+
/**
* Generate the unique caching key.
* This key must be unique inside the space of this component.
@@ -121,19 +148,96 @@ public void addOptions(Options options) throws SAXException, WingException,
*/
/* regulate the ordering */
+ List browse = options.addList("browse");
options.addList("discovery");
- options.addList("browse");
options.addList("account");
options.addList("context");
options.addList("administrative");
+ browse.setHead(T_head_browse);
+
+ List browseGlobal = browse.addList("global");
+ List browseContext = browse.addList("context");
+
+ browseGlobal.setHead(T_head_all_of_dspace);
+
+ browseGlobal.addItemXref(contextPath + "/community-list",T_communities_and_collections);
+
+ Map<String, String> browseTitleParams = new HashMap<String, String>();
+ browseTitleParams.put("sort_by", "dc.title_sort");
+ browseTitleParams.put("order", "asc");
+
+ browseGlobal.addItemXref(generateURL(contextPath + "/discover", browseTitleParams),
+ message("xmlui.ArtifactBrowser.AdvancedSearch.type_title"));
+
+ // Add the configured browse lists for 'top level' browsing
+ addBrowseOptions(browseGlobal, contextPath + "/search-filter", null);
+
+ DSpaceObject dso = HandleUtil.obtainHandle(objectModel);
+ if (dso != null)
+ {
+ if (dso instanceof Item)
+ {
+ // If we are an item change the browse scope to the parent
+ // collection.
+ dso = ((Item) dso).getOwningCollection();
+ }
+
+ if (dso instanceof Collection)
+ {
+ browseContext.setHead(T_head_this_collection);
+ }
+ if (dso instanceof Community)
+ {
+ browseContext.setHead(T_head_this_community);
+ }
+
+ // Add the configured browse lists for scoped browsing
+ String handle = dso.getHandle();
+ browseContext.addItemXref(generateURL(contextPath + "/handle/" + handle + "/discover", browseTitleParams),
+ message("xmlui.ArtifactBrowser.AdvancedSearch.type_title"));
+ addBrowseOptions(browseContext, contextPath + "/handle/" + handle + "/search-filter", dso);
+ }
+ }
+
+ /**
+ * Add navigation for the configured browse tables to the supplied list.
+ *
+ * @param browseList
+ * @param browseURL
+ * @throws WingException
+ */
+ private void addBrowseOptions(List browseList, String browseURL, DSpaceObject scope) throws WingException
+ {
+ // Get a Map of all the browse tables
+ DiscoveryConfiguration discoveryConfiguration = SearchUtils.getDiscoveryConfiguration(scope);
+ java.util.List<DiscoverySearchFilterFacet> facets = discoveryConfiguration.getSidebarFacets();
+
+ for (DiscoverySearchFilterFacet facet : facets)
+ {
+ if(facet.getType().equals(DiscoveryConfigurationParameters.TYPE_DATE))
+ {
+ //Browse by date isn't support for our facets.
+ continue;
+ }
+
+ // Create a Map of the query parameters for this link
+ Map<String, String> queryParams = new HashMap<String, String>();
+
+ queryParams.put("field", facet.getIndexFieldName());
+
+ // Add a link to this browse
+ browseList.addItemXref(generateURL(browseURL, queryParams),
+ message("xmlui.ArtifactBrowser.AdvancedSearch.type_" + facet.getIndexFieldName()));
+ }
}
+
/**
* Ensure that the context path is added to the page meta.
*/
public void addPageMeta(PageMeta pageMeta) throws SAXException,
- WingException, UIException, SQLException, IOException,
+ WingException, SQLException, IOException,
AuthorizeException
{
@@ -146,4 +250,4 @@ public void addPageMeta(PageMeta pageMeta) throws SAXException,
}
-}
+}
View
28 dspace-xmlui/src/main/resources/aspects/ArtifactBrowser/dspace-home.xml
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
-
- The contents of this file are subject to the license and copyright
- detailed in the LICENSE and NOTICE files at the root of the source
- tree and available online at
-
- http://www.dspace.org/license/
-
--->
-
-<!--
- The DSpace home page is just a shell into which various bits such as news
- and the Community Browser are inserted, so it is a bit special. This file
- provides title and trail data so that they won't be acquired from those
- other bits.
--->
-<document xmlns="http://di.tamu.edu/DRI/1.0/" xmlns:i18n="http://apache.org/cocoon/i18n/2.1" version="1.1">
-<options/>
-<meta>
-<userMeta/>
-<pageMeta>
- <metadata element="title"><i18n:text>xmlui.general.dspace_home</i18n:text></metadata>
- <trail><i18n:text>xmlui.general.dspace_home</i18n:text></trail>
-</pageMeta>
-<repositoryMeta/>
-</meta>
-</document>
View
295 dspace-xmlui/src/main/resources/aspects/ArtifactBrowser/sitemap.xmap
@@ -1,295 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-
- The contents of this file are subject to the license and copyright
- detailed in the LICENSE and NOTICE files at the root of the source
- tree and available online at
-
- http://www.dspace.org/license/
-
--->
-
-<!--
-@deprecated: the Artifact Browser has been devided into ViewArtifacts,
- BrowseArtifacts, SearchArtifacts
-
-The ArtifactBrowser Aspect is responsible for browsing communities /
-collections / items / and bitstreams, viewing an individual item,
-and searching the repository.
-
--->
-<map:sitemap xmlns:map="http://apache.org/cocoon/sitemap/1.0">
- <map:components>
-
-
- <map:transformers>
- <map:transformer name="Navigation" src="org.dspace.app.xmlui.aspect.artifactbrowser.Navigation"/>
- <map:transformer name="CommunityBrowser" src="org.dspace.app.xmlui.aspect.artifactbrowser.CommunityBrowser"/>
- <map:transformer name="CommunityViewer" src="org.dspace.app.xmlui.aspect.artifactbrowser.CommunityViewer"/>
- <map:transformer name="CollectionViewer" src="org.dspace.app.xmlui.aspect.artifactbrowser.CollectionViewer"/>
- <map:transformer name="ItemViewer" src="org.dspace.app.xmlui.aspect.artifactbrowser.ItemViewer"/>
- <map:transformer name="ConfigurableBrowse" src="org.dspace.app.xmlui.aspect.artifactbrowser.ConfigurableBrowse"/>
- <map:transformer name="SimpleSearch" src="org.dspace.app.xmlui.aspect.artifactbrowser.SimpleSearch"/>
- <map:transformer name="AdvancedSearch" src="org.dspace.app.xmlui.aspect.artifactbrowser.AdvancedSearch"/>
- <map:transformer name="FeedbackForm" src="org.dspace.app.xmlui.aspect.artifactbrowser.FeedbackForm"/>
- <map:transformer name="FeedbackSent" src="org.dspace.app.xmlui.aspect.artifactbrowser.FeedbackSent"/>
- <map:transformer name="Contact" src="org.dspace.app.xmlui.aspect.artifactbrowser.Contact"/>
- <map:transformer name="RestrictedItem" src="org.dspace.app.xmlui.aspect.artifactbrowser.RestrictedItem"/>
- <map:transformer name="FrontPageSearch" src="org.dspace.app.xmlui.aspect.artifactbrowser.FrontPageSearch"/>
-
- <map:transformer name="Statistics" src="org.dspace.app.xmlui.aspect.artifactbrowser.StatisticsViewer"/>
- </map:transformers>
-
-
- <map:matchers default="wildcard">
- <map:matcher name="HandleTypeMatcher" src="org.dspace.app.xmlui.aspect.general.HandleTypeMatcher"/>
- <map:matcher name="HandleAuthorizedMatcher" src="org.dspace.app.xmlui.aspect.general.HandleAuthorizedMatcher"/>
- </map:matchers>
-
-
- <map:actions>
- <map:action name="SendFeedbackAction" src="org.dspace.app.xmlui.aspect.artifactbrowser.SendFeedbackAction"/>
- <map:action name="UsageLoggerAction" src="org.dspace.app.xmlui.cocoon.UsageLoggerAction"/>
- <map:action name="NotModifiedAction" src="org.dspace.app.xmlui.aspect.general.NotModifiedAction"/>
- </map:actions>
-
-
- <map:selectors>
- <map:selector name="AuthenticatedSelector" src="org.dspace.app.xmlui.aspect.general.AuthenticatedSelector"/>
- <map:selector name="IfModifiedSinceSelector" src="org.dspace.app.xmlui.aspect.general.IfModifiedSinceSelector"/>
- </map:selectors>
-
- </map:components>
- <map:pipelines>
- <map:pipeline>
-
-
- <map:generate/>
-
- <!--
- Add the basic navigation content to everypage. This includes:
-
- 1) Metadata about the current page (really just what the current
- context path is)
- 2) Navigation links to browse the repository.
- - This includes links that are relative to the currently
- selected community or collection.
- 3) Metadata about the search urls.
- -->
- <map:transform type="Navigation"/>
-
-
- <!--
- Display the DSpace homepage. This includes the news.xml file
- along with a list of top level communities in DSpace.
- -->
- <map:match pattern="">
- <map:transform type="Include" src="resource://aspects/ArtifactBrowser/dspace-home.xml" />
- <!--
- DSpacePropertyFileReader will read the DSpace property file and
- place the selected properties' value in this scope
- -->
- <map:act type="DSpacePropertyFileReader">
- <map:parameter name="dspace.dir" value="dspace.dir" />
- <map:transform type="Include" src="file://{dspace.dir}/config/news-xmlui.xml" />
- </map:act>
-
- <map:transform type="FrontPageSearch"/>
- <map:transform type="CommunityBrowser">
- <map:parameter name="depth" value="1"/>
- </map:transform>
- <map:serialize type="xml"/>
- </map:match>
-
-
- <!-- List all communities & collections in DSpace -->
- <map:match pattern="community-list">
- <map:transform type="CommunityBrowser">
- <map:parameter name="depth" value="999"/>
- </map:transform>
- <map:serialize type="xml"/>
- </map:match>
-
-
- <!-- Search -->
- <map:match pattern="search">
- <map:transform type="SimpleSearch"/>
- <map:serialize type="xml"/>
- </map:match>
- <map:match pattern="simple-search">
- <map:transform type="SimpleSearch"/>
- <map:serialize type="xml"/>
- </map:match>
- <map:match pattern="advanced-search">
- <map:transform type="AdvancedSearch"/>
- <map:serialize type="xml"/>
- </map:match>
-
-
- <!-- Browse (by anything) -->
- <map:match pattern="browse">
- <map:transform type="ConfigurableBrowse"/>
- <map:serialize type="xml"/>
- </map:match>
-
- <!-- Display statistics -->
- <map:match pattern="statistics">
- <map:transform type="Statistics"/>
- <map:serialize type="xml"/>
- </map:match>
-
-
- <!-- restricted resource -->
- <map:match pattern="restricted-resource">
- <map:transform type="RestrictedItem"/>
- <map:serialize type="xml"/>
- </map:match>
-
-
- <!-- Handle specific features -->
- <map:match pattern="handle/*/**">
-
- <!-- Inform the user that the item they are viewing is a restricted resource -->
- <map:match pattern="handle/*/*/restricted-resource">
- <map:transform type="RestrictedItem"/>
- <map:serialize type="xml"/>
- </map:match>
-
- <!-- Scoped browse by features -->
- <map:match type="HandleAuthorizedMatcher" pattern="READ">
- <map:match type="HandleTypeMatcher" pattern="community,collection">
-
- <!-- Browse (by anything) -->
- <map:match pattern="handle/*/*/browse">
- <map:transform type="ConfigurableBrowse"/>
- <map:serialize type="xml"/>
- </map:match>
-
- <!-- Simple search -->
- <map:match pattern="handle/*/*/search">
- <map:transform type="SimpleSearch"/>
- <map:serialize type="xml"/>
- </map:match>
-
- <!-- Simple search again, but this time they said it -->
- <map:match pattern="handle/*/*/simple-search">
- <map:transform type="SimpleSearch"/>
- <map:serialize type="xml"/>
- </map:match>
-
- <!-- Advanced search -->
- <map:match pattern="handle/*/*/advanced-search">
- <map:transform type="AdvancedSearch"/>
- <map:serialize type="xml"/>
- </map:match>
-
- </map:match> <!-- End match community or collection -->
- </map:match> <!-- End match can read -->
-
-
- <!-- Community, Collection, and Item Viewers -->
- <map:match pattern="handle/*/*">
- <map:match type="HandleAuthorizedMatcher" pattern="READ">
- <map:match type="HandleTypeMatcher" pattern="community">
- <map:act type="UsageLoggerAction">
- <map:parameter name="type" value="community"/>
- <map:parameter name="eventType" value="view"/>
- </map:act>
- <map:transform type="CommunityViewer"/>
- <map:serialize type="xml"/>
- </map:match>
- <map:match type="HandleTypeMatcher" pattern="collection">
- <map:act type="UsageLoggerAction">
- <map:parameter name="type" value="collection"/>
- <map:parameter name="eventType" value="view"/>
- </map:act>
- <map:transform type="CollectionViewer"/>
- <map:serialize type="xml"/>
- </map:match>
- <map:match type="HandleTypeMatcher" pattern="item">
- <map:act type="UsageLoggerAction">
- <map:parameter name="type" value="item"/>
- <map:parameter name="eventType" value="view"/>
- </map:act>
- <!-- Implement HTTP If-Modified-Since protocol (commonly used by search
- - engine crawlers): return 304 NOT MODIFIED status if Item's
- - last-modified date is before If-Modified-Since header.
- -
- - NOTE: Do NOT do this for interactive users since it might encourage
- - browser to cache a view that is only shown to authenticated users.
- - ONLY do this when user-agent is a spider (search-engine crawler robot)
- - since they should only ever have "anonymous" access.
- -
- - NOTE: Cocoon always automatically sets Last-Modified: header on its
- - transformed pages with the current timestamp, which we cannot override.
- - It won't prevent a spider's If-Modified-Since from working, though.
- -->
- <map:select type="browser">
- <map:when test="spider">
- <map:select type="IfModifiedSinceSelector">
- <map:when test="true">
- <map:act type="NotModifiedAction"/>
- <map:serialize/>
- </map:when>
- <map:otherwise>
- <map:transform type="ItemViewer"/>
- <map:serialize type="xml"/>
- </map:otherwise>
- </map:select>
- </map:when>
- <map:otherwise>
- <map:transform type="ItemViewer"/>
- <map:serialize type="xml"/>
- </map:otherwise>
- </map:select>
- </map:match>
- </map:match>
-
- <map:match type="HandleAuthorizedMatcher" pattern="!READ">
- <map:transform type="RestrictedItem">
- <map:parameter name="header" value="xmlui.ArtifactBrowser.RestrictedItem.auth_header"/>
- <map:parameter name="message" value="xmlui.ArtifactBrowser.RestrictedItem.auth_message"/>
- </map:transform>
- <map:serialize type="xml"/>
- </map:match>
- </map:match>
-
-
- </map:match> <!-- End match handle/*/** -->
-
-
- <!--
- A simple feedback utility that presents the user with a form to fill out,
- the results of which are emailed to the site administrator.
- -->
- <map:match pattern="feedback">
- <map:act type="SendFeedbackAction">
- <map:transform type="FeedbackForm">
- <map:parameter name="comments" value="{comments}"/>
- <map:parameter name="email" value="{email}"/>
- <map:parameter name="page" value="{page}"/>
- </map:transform>
-
- <map:serialize type="xml"/>
- </map:act>
- <map:transform type="FeedbackSent"/>
- <map:serialize type="xml"/>
- </map:match>
-
- <!--
- The most basic & generic contact us page. It is expected that most
- themes will override this page and replace it with a more detailed
- version.
- -->
- <map:match pattern="contact">
- <map:transform type="Contact"/>
- <map:serialize type="xml"/>
- </map:match>
-
-
- <!-- Not a URL we care about, so just pass it on. -->
- <map:serialize type="xml"/>
-
- </map:pipeline>
- </map:pipelines>
-</map:sitemap>
View
4 dspace-xmlui/src/main/resources/aspects/BrowseArtifacts/sitemap.xmap
@@ -23,6 +23,8 @@ collections / items / and bitstreams.
<map:transformer name="CommunityBrowser" src="org.dspace.app.xmlui.aspect.artifactbrowser.CommunityBrowser"/>
<map:transformer name="CommunityRecentSubmissions" src="org.dspace.app.xmlui.aspect.artifactbrowser.CommunityRecentSubmissions"/>
<map:transformer name="CollectionRecentSubmissions" src="org.dspace.app.xmlui.aspect.artifactbrowser.CollectionRecentSubmissions"/>
+ <map:transformer name="CommunityBrowse" src="org.dspace.app.xmlui.aspect.browseArtifacts.CommunityBrowse"/>
+ <map:transformer name="CollectionBrowse" src="org.dspace.app.xmlui.aspect.browseArtifacts.CollectionBrowse"/>
<map:transformer name="ConfigurableBrowse" src="org.dspace.app.xmlui.aspect.artifactbrowser.ConfigurableBrowse"/>
<map:transformer name="StaticPage" src="org.dspace.app.xmlui.aspect.browseArtifacts.StaticPage"/>
</map:transformers>
@@ -81,12 +83,14 @@ collections / items / and bitstreams.
<map:match type="HandleTypeMatcher" pattern="community">
<map:match pattern="handle/*/*">
+ <map:transform type="CommunityBrowse"/>
<map:transform type="CommunityRecentSubmissions"/>
</map:match>
</map:match>
<map:match type="HandleTypeMatcher" pattern="collection">
<map:match pattern="handle/*/*">
+ <map:transform type="CollectionBrowse"/>
<map:transform type="CollectionRecentSubmissions"/>
</map:match>
</map:match>
View
12 dspace-xmlui/src/main/resources/aspects/Discovery/sitemap.xmap
@@ -23,6 +23,7 @@ and searching the repository.
<map:transformers>
<map:transformer name="Navigation" src="org.dspace.app.xmlui.aspect.discovery.Navigation"/>
+ <map:transformer name="CommunityBrowser" src="org.dspace.app.xmlui.aspect.artifactbrowser.CommunityBrowser"/>
<map:transformer name="SimpleSearch" src="org.dspace.app.xmlui.aspect.discovery.SimpleSearch"/>
<map:transformer name="BrowseFacet" src="org.dspace.app.xmlui.aspect.discovery.BrowseFacet"/>
<map:transformer name="SearchFacetFilter" src="org.dspace.app.xmlui.aspect.discovery.SearchFacetFilter"/>
@@ -31,11 +32,11 @@ and searching the repository.
<map:transformer name="SidebarFacetsTransformer" src="org.dspace.app.xmlui.aspect.discovery.SidebarFacetsTransformer"/>
- <map:transformer name="CommunitySearch" src="org.dspace.app.xmlui.aspect.discovery.CommunitySearch"/>
+ <map:transformer name="CommunitySearch" src="org.dspace.app.xmlui.aspect.discovery.CommunitySearchBrowse"/>
<map:transformer name="CommunityRecentSubmissions" src="org.dspace.app.xmlui.aspect.discovery.CommunityRecentSubmissions"/>
- <map:transformer name="CollectionSearch" src="org.dspace.app.xmlui.aspect.discovery.CollectionSearch"/>
+ <map:transformer name="CollectionSearch" src="org.dspace.app.xmlui.aspect.discovery.CollectionSearchBrowse"/>
<map:transformer name="CollectionRecentSubmissions" src="org.dspace.app.xmlui.aspect.discovery.CollectionRecentSubmissions"/>
@@ -81,6 +82,9 @@ and searching the repository.
-->
<map:match pattern="">
<map:transform type="SidebarFacetsTransformer"/>
+ <map:transform type="CommunityBrowser">
+ <map:parameter name="depth" value="1"/>
+ </map:transform>
<map:transform type="FrontPageSearch"/>
<map:transform type="SiteRecentSubmissions"/>
@@ -89,13 +93,13 @@ and searching the repository.
</map:match>
- <!-- List all communities & collections in DSpace
+ <!-- List all communities & collections in DSpace -->
<map:match pattern="community-list">
<map:transform type="CommunityBrowser">
<map:parameter name="depth" value="999"/>
</map:transform>
<map:serialize type="xml"/>
- </map:match> -->
+ </map:match>
<!-- Search -->
View
4 dspace/config/dspace.cfg
@@ -631,9 +631,7 @@ event.dispatcher.default.class = org.dspace.event.BasicDispatcher
#
# uncomment below and comment out original property to enable discovery indexing
-# event.dispatcher.default.consumers = versioning, search, browse, discovery, eperson, harvester
-#
-event.dispatcher.default.consumers = versioning, search, browse, eperson, harvester
+event.dispatcher.default.consumers = versioning, search, browse, discovery, eperson, harvester
# The noindex dispatcher will not create search or browse indexes (useful for batch item imports)
event.dispatcher.noindex.class = org.dspace.event.BasicDispatcher
View
7 dspace/config/launcher.xml
@@ -142,6 +142,10 @@
<class>org.dspace.search.DSIndexer</class>
<argument>-b</argument>
</step>
+ <step passuserargs="false">
+ <class>org.dspace.discovery.IndexClient</class>
+ <argument>-f</argument>
+ </step>
</command>
<command>
@@ -157,6 +161,9 @@
<step passuserargs="false">
<class>org.dspace.search.DSIndexer</class>
</step>
+ <step passuserargs="false">
+ <class>org.dspace.discovery.IndexClient</class>
+ </step>
</command>
<command>
View
2  dspace/config/modules/discovery.cfg
@@ -5,7 +5,7 @@
# faceted-search system. #
#---------------------------------------------------------------#
##### Search Indexing #####
-search.server = http://localhost:8080/solr/search
+search.server = ${solr.server}/search
#Char used to ensure that the sidebar facets are case insensitive
#solr.facets.split.char=\n|||\n
View
17 dspace/config/xmlui.xconf
@@ -59,15 +59,11 @@
/xmlui/cocoon/aspects/ directory followed by a slash.
-->
<aspects>
- <!--
- @deprecated: the Artifact Browser has been devided into ViewArtifacts,
- BrowseArtifacts, SearchArtifacts
- <aspect name="Artifact Browser" path="resource://aspects/ArtifactBrowser/" />
- -->
<aspect name="Versioning Aspect" path="resource://aspects/Versioning/" />
<aspect name="Displaying Artifacts" path="resource://aspects/ViewArtifacts/" />
- <aspect name="Browsing Artifacts" path="resource://aspects/BrowseArtifacts/" />
- <aspect name="Searching Artifacts" path="resource://aspects/SearchArtifacts/" />
+ <!--<aspect name="Browsing Artifacts" path="resource://aspects/BrowseArtifacts/" />-->
+ <!--<aspect name="Searching Artifacts" path="resource://aspects/SearchArtifacts/" />-->
+ <aspect name="Discovery" path="resource://aspects/Discovery/" />
<aspect name="Administration" path="resource://aspects/Administrative/" />
<aspect name="E-Person" path="resource://aspects/EPerson/" />
<aspect name="Submission and Workflow" path="resource://aspects/Submission/" />
@@ -75,13 +71,6 @@
<aspect name="Statistics - Elastic Search" path="resource://aspects/StatisticsElasticSearch/" />
<aspect name="Original Workflow" path="resource://aspects/Workflow/" />
<!--<aspect name="XMLWorkflow" path="resource://aspects/XMLWorkflow/" />-->
- <!--
- To enable Discovery, uncomment this Aspect that will enable it
- within your existing XMLUI
- Also make sure to comment the SearchArtifacts aspect
- as leaving it on together with discovery will cause UI overlap issues
- <aspect name="Discovery" path="resource://aspects/Discovery/" />
- -->
<!--<aspect name="SwordClient" path="resource://aspects/SwordClient/" />-->
<!--
Please sign in to comment.
Something went wrong with that request. Please try again.