Commit c60f76d9 authored by Matija Obreza's avatar Matija Obreza
Browse files

Order by seqNo

parent e6fad0a9
......@@ -138,7 +138,7 @@ public class GenesysFilterServiceImpl implements GenesysFilterService {
results.size() == 0 ? new ArrayList<Accession>()
: accessionRepository.listById(results,
// TODO Consider processing the pageable.getSort
new Sort("accessionName")),
pageable.getSort()),
// -- TODO
pageable, totalCount);
} else {
......
......@@ -231,7 +231,7 @@ public class ExplorerController extends BaseController implements InitializingBe
}
model.addAttribute("jsonFilter", appliedFilters.toString());
final Page<AccessionDetails> accessions = filterService.listAccessionDetails(appliedFilters, new PageRequest(page - 1, results, new Sort("acceNumb")));
final Page<AccessionDetails> accessions = filterService.listAccessionDetails(appliedFilters, new PageRequest(page - 1, results, new Sort("seqNo")));
if (_logger.isDebugEnabled()) {
_logger.debug("Got: " + accessions);
......@@ -368,7 +368,7 @@ public class ExplorerController extends BaseController implements InitializingBe
@RequestParam(value = "results", required = true, defaultValue = "50") int results) throws IOException, SearchException {
AppliedFilters appliedFilters = mapper.readValue(jsonFilter, AppliedFilters.class);
return filterService.listAccessionDetails(appliedFilters, new PageRequest(page - 1, results, new Sort("acceNumb")));
return filterService.listAccessionDetails(appliedFilters, new PageRequest(page - 1, results, new Sort("seqNo")));
}
@RequestMapping(value = "/explore/listFilterSuggestions", method = RequestMethod.GET, produces = MediaType.APPLICATION_JSON_VALUE)
......@@ -609,7 +609,7 @@ public class ExplorerController extends BaseController implements InitializingBe
_logger.info(appliedFilters.toString());
model.addAttribute("jsonFilter", appliedFilters.toString());
final Page<AccessionDetails> accessions = elasticService.filter(appliedFilters, new PageRequest(page - 1, 50, new Sort("acceNumb")));
final Page<AccessionDetails> accessions = elasticService.filter(appliedFilters, new PageRequest(page - 1, 50, new Sort("seqNo")));
_logger.info("Got: " + accessions);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment