Hi Pablo, you need to configure your sort order in the dspace.cfg and put in the jsp tag just the number associated with your new sort option. Create a SortOption object doesn't work if it is not configured in the dspace.cfg and the system properly reindexed. Andrea
Il 02/06/2015 09.22, Pablo Buenaposada ha scritto: > Hi, > > I want to order the researcher results that a custom jsp returns in a > specific tab. > I see that the jstl line which prints the results is this : > <dspace:browselist items="<%= (BrowseItem[])info.getItems() %>" > config="crisrp" /> > > this works nice but the order is not alphabetical, I saw in another default > jsp (persons.jsp) that you can add the options > sortBy="<%= new Integer(info.getSo().getNumber()).toString() %>" > and > order="<%= info.getOrder() %>" > > so I add a new SortOption object to the info instance: > SortOption sortOption = new > SortOption(4,"rpname:crisrp.fullName:title"); > info.setSo(sortOption); > > and also the order string to the info instance: > info.setOrder("DESC"); > > and the jslt line: > <dspace:browselist items="<%= (BrowseItem[])info.getItems() %>" > config="crisrp" sortBy="<%= new Integer(info.getSo().getNumber()).toString() > %>" order="<%= info.getOrder() %>"/> > > but doesn't order the researcher results, it prints the researchers but > without the alpabetical order... any hint? > > > > > -- > View this message in context: > http://dspace.2283337.n4.nabble.com/dspace-cris-ordering-in-custom-jsp-tp4678159.html > Sent from the DSpace - Tech mailing list archive at Nabble.com. > > ------------------------------------------------------------------------------ > _______________________________________________ > DSpace-tech mailing list > DSpace-tech@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/dspace-tech > List Etiquette: > https://wiki.duraspace.org/display/DSPACE/Mailing+List+Etiquette -- Andrea Bollini Soluzioni per la Ricerca Istituzionale Cineca Via dei Tizii, 6 00185 Roma, Italy tel. +39 06 44 486 087 - mob. +39 348 82 77 525 http://www.cineca.it ------------------------------------------------------------------------------ _______________________________________________ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech List Etiquette: https://wiki.duraspace.org/display/DSPACE/Mailing+List+Etiquette