Commit c1469965 authored by Matija Obreza's avatar Matija Obreza

Merge branch...

Merge branch 'ui-417-counter-on-dataset-overview-page-displays-value-of-all-datasets-when-result-should-be-0' into 'master'

Fix: Counter on dataset overview page displays value of all datasets when result should be 0.

Closes genesys-ui#417

See merge request genesys-pgr/genesys-server!431
parents 70fd9c7d 4ca14ea0
......@@ -570,6 +570,9 @@ public class DatasetServiceImpl implements DatasetService {
*/
@Override
public long countDatasets(DatasetFilter filter) {
if (filter.isFulltextQuery()) {
return elasticsearchService.count(Dataset.class, filter);
}
return datasetRepository.count(filter.buildPredicate());
}
......
......@@ -103,6 +103,9 @@ public class DescriptorListServiceImpl implements DescriptorListService {
*/
@Override
public long countDescriptorLists(DescriptorListFilter filter) {
if (filter.isFulltextQuery()) {
return elasticsearchService.count(DescriptorList.class, filter);
}
return descriptorListRepository.count(filter.buildPredicate());
}
......
......@@ -610,6 +610,9 @@ public class DescriptorServiceImpl implements DescriptorService {
@Override
public long countDescriptors(DescriptorFilter filter) {
if (filter.isFulltextQuery()) {
return elasticsearchService.count(DescriptorList.class, filter);
}
return descriptorRepository.count(filter.buildPredicate());
}
......
......@@ -173,6 +173,9 @@ public class SubsetServiceImpl implements SubsetService {
@Override
public long countSubsets(SubsetFilter filter) {
if (filter.isFulltextQuery()) {
return elasticsearchService.count(Subset.class, filter);
}
return subsetRepository.count(filter.buildPredicate());
}
......
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