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

get_filter_name is now a classmethod #775

Merged
merged 1 commit into from
Oct 17, 2017

Conversation

ChristianKreuzberger
Copy link
Contributor

This PR moves get_filter_name from a function to a static class method, which enables developers to override this method for each filter.
This is addressing issue #774, and helps developers that want to define an alias for a field with many comperators, and still want to use the very convenient and intuitive API of the filtering with field_name__gte, field_name__lte, ...

@codecov-io
Copy link

codecov-io commented Sep 6, 2017

Codecov Report

Merging #775 into develop will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@           Coverage Diff            @@
##           develop     #775   +/-   ##
========================================
  Coverage    98.36%   98.36%           
========================================
  Files           15       15           
  Lines         1220     1220           
========================================
  Hits          1200     1200           
  Misses          20       20
Impacted Files Coverage Δ
django_filters/filterset.py 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 978e9ef...b977f9a. Read the comment docs.

@carltongibson carltongibson added this to the Version 1.1 milestone Oct 17, 2017
@carltongibson carltongibson merged commit af4b554 into carltongibson:develop Oct 17, 2017
carltongibson pushed a commit that referenced this pull request Oct 19, 2017
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.

4 participants