Skip to content

Commit

Permalink
Merge pull request 52North#302 from ridoo/fix/issue-301_broken-filter…
Browse files Browse the repository at this point in the history
…-and-collections

Fix/issue 301 broken filter and collections
  • Loading branch information
ridoo authored Mar 7, 2017
2 parents 142cc28 + f25e7c3 commit 3056672
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -329,13 +329,13 @@ private Type getGeometryType(String geometryType) {

public Criteria addDetachedFilters(String propertyName, Criteria criteria) {
DetachedCriteria filter = DetachedCriteria.forClass(DatasetEntity.class)
.setProjection(Property.forName("pkid"));
.setProjection(projectionList().add(property(propertyName)));

filterWithSingularParmameters(filter); // stay backwards compatible
addHierarchicalFilterRestriction(parameters.getPhenomena(), "phenomenon", filter);
addFilterRestriction(parameters.getPhenomena(), "phenomenon", filter);
addHierarchicalFilterRestriction(parameters.getProcedures(), "procedure", filter);
addHierarchicalFilterRestriction(parameters.getOfferings(), "offering", filter);
addHierarchicalFilterRestriction(parameters.getFeatures(), "feature", filter);
addFilterRestriction(parameters.getFeatures(), "feature", filter);
addFilterRestriction(parameters.getCategories(), "category", filter);
addFilterRestriction(parameters.getDatasets(), filter);
addFilterRestriction(parameters.getSeries(), filter);
Expand Down

0 comments on commit 3056672

Please sign in to comment.