Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make sure string filtering is case insensitive for WFS requests #3107

Merged
merged 2 commits into from
Nov 16, 2017

Conversation

asaunier
Copy link
Member

Related to #2855

It seems there are no unit tests for the RuleHelper service and I see no other test that could be related.

Documentation of the ol.format.filter.like function, whose arguments are edited in this PR to explicitly add matchCase=false (default value is undefined => this attribute didn't appear previously in the WFS request):
http://openlayers.org/en/latest/apidoc/ol.format.filter.html#.like

Posted WFS GetFeature request formerly contained:

<PropertyIsLike wildCard="*" singleChar="." escapeChar="!"><PropertyName>name</PropertyName><Literal>linde</Literal></PropertyIsLike>

Now is:

<PropertyIsLike wildCard="*" singleChar="." escapeChar="!" matchCase="false"><PropertyName>name</PropertyName><Literal>linde</Literal></PropertyIsLike>

=> returns results whose name are eg. "Linde", "Lindenpark", ....

@asaunier
Copy link
Member Author

@sbrunner Thanks for reviewing: merging...

@asaunier asaunier merged commit 12a5f00 into master Nov 16, 2017
@asaunier asaunier deleted the wfsfilter-caseinsensitive branch November 16, 2017 15:46
@asaunier
Copy link
Member Author

@sbrunner My PR was against the master branch. Is it OK or should it be pushed to ngeo 2.2 instead?

@sbrunner sbrunner added this to the 2.3 milestone Apr 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants