Commit fb378836 authored by Matija Obreza's avatar Matija Obreza

Merge branch 'ui-220-display-number-of-accessions' into 'master'

Added accessionCount to accession overview

See merge request genesys-pgr/genesys-server!358
parents 146bc457 07962ec6
......@@ -204,8 +204,9 @@ public class AccessionController {
}
Map<String, TermResult> overview = elasticsearchService.termStatisticsAuto(Accession.class, filter, 10, terms.toArray(new String[] {}));
long accessionCount = accessionService.countAccessions(filter);
return AccessionOverview.from(filterCode, filter, overview);
return AccessionOverview.from(filterCode, filter, overview, accessionCount);
}
/**
......@@ -551,13 +552,15 @@ public class AccessionController {
public static class AccessionOverview {
public String filterCode;
public AccessionFilter filter;
public long accessionCount;
public Map<String, TermResult> overview;
private static AccessionOverview from(String filterCode, AccessionFilter filter, Map<String, TermResult> overview) {
private static AccessionOverview from(String filterCode, AccessionFilter filter, Map<String, TermResult> overview, long accessionCount) {
AccessionOverview res = new AccessionOverview();
res.filterCode = filterCode;
res.filter = filter;
res.overview = overview;
res.accessionCount = accessionCount;
return res;
}
......
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