-
-
Notifications
You must be signed in to change notification settings - Fork 775
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
Add filtering by applicants in bounties explorer #4613
Add filtering by applicants in bounties explorer #4613
Conversation
What is the default state? Thanks! |
dd3044a
to
55280e7
Compare
Codecov Report
@@ Coverage Diff @@
## master #4613 +/- ##
==========================================
- Coverage 30.42% 30.41% -0.01%
==========================================
Files 216 216
Lines 17234 17240 +6
Branches 2333 2335 +2
==========================================
+ Hits 5243 5244 +1
- Misses 11783 11788 +5
Partials 208 208
Continue to review full report at Codecov.
|
@PixelantDesign I've set a default selection to 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 🙌 @rafalkowalski could you ensure travis passes?
e358bba
to
7eb773e
Compare
Thank you! |
Hey @rafalkowalski did you tested this in hackathon explorer? I think the filter will apply also there. |
@octavioamu Applicants filter isn't visible in hackathon explorer |
@rafalkowalski Even though the filter isn't visible, the backend code that handles the request is the same. Since we store the filter in localStorage, we must make sure the same query parameter isn't submitted with the request on the hackathon page (I think this is what @octavioamu is referring to, we've had issues with this in the past) |
7eb773e
to
0677fee
Compare
@rafalkowalski still failing in travis, there are some js lint errors run |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Can you please squash and rebase? Thanks!
bf907f5
to
d28dcaa
Compare
@danlipert I've rebased it :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sweet @rafalkowalski ^_^
d28dcaa
to
b3e8627
Compare
b3e8627
to
7d3c5db
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Hey guys! I just looked at some data and think it's best if we filter by 0 applicants as a default. I don't want to post the data here, but hit me up if you guys want to chat. @rafalkowalski could we make the change to default to 0? Thank you! |
7d3c5db
to
9d080e7
Compare
@@ -267,6 +269,16 @@ def get_queryset(self): | |||
statuses = self.request.query_params.get('status__in').split(',') | |||
queryset = queryset.filter(idx_status__in=statuses) | |||
|
|||
applicants = self.request.query_params.get('applicants') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
did you guys do any testing on performance here? this is a multi table JOIN between bounty + interest tables, and it increases the load time for the API on the explorer from 500ms to 10s+
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
note the diff between the applicants=0
calls here vs the ones that dont have that call in them...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the explorer page defaults to applicants=0, thus making most explorer lookups 10+s
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@owocki I will fix it
Fixes issue #4544
Kindly review
@thelostone-mc
Description
Refers/Fixes
Testing