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

Add ranking feature to userinfo #256

Merged
merged 9 commits into from
Dec 13, 2021
Merged

Add ranking feature to userinfo #256

merged 9 commits into from
Dec 13, 2021

Conversation

falkecarlsen
Copy link
Member

@falkecarlsen falkecarlsen commented Sep 27, 2021

Users can click 'Rangliste' under userinfo to get their ranking in all categories:
image

For comparison, the SQL queries takes only ~150ms for sales during the last year.

Unfortunately this is slow as molasses, which could be alleviated by caching - but that's effort.
Currently this is all time, should probably also have a 'since Fjulefrokost' or possibly allow users to specify a timerange.

Closes #255

Suggestions and discussions from #163 and #177 should be considered for this PR

Edit: Now even more comprehensive:
image

@codecov-commenter
Copy link

codecov-commenter commented Sep 27, 2021

Codecov Report

Merging #256 (00e7821) into next (92ba538) will decrease coverage by 1.07%.
The diff coverage is 25.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             next     #256      +/-   ##
==========================================
- Coverage   82.44%   81.37%   -1.08%     
==========================================
  Files          30       30              
  Lines        2336     2378      +42     
  Branches      167      174       +7     
==========================================
+ Hits         1926     1935       +9     
- Misses        381      413      +32     
- Partials       29       30       +1     
Impacted Files Coverage Δ
stregsystem/urls.py 75.00% <ø> (ø)
stregsystem/views.py 54.28% <17.14%> (-6.57%) ⬇️
stregsystem/forms.py 70.96% <55.55%> (-6.31%) ⬇️

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 92ba538...00e7821. Read the comment docs.

@falkecarlsen falkecarlsen marked this pull request as ready for review October 6, 2021 11:13
Copy link
Member

@Zaph-x Zaph-x left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image
It is possible to apply a greater from date, than to date

stregsystem/views.py Outdated Show resolved Hide resolved
Co-authored-by: Julian Teu <julian@jtle.dk>
@falkecarlsen
Copy link
Member Author

It is possible to apply a greater from date, than to date

Fixed in a2bb5e6

@falkecarlsen falkecarlsen requested a review from Zaph-x November 26, 2021 12:12
@falkecarlsen falkecarlsen merged commit 890a28f into next Dec 13, 2021
@atjn atjn deleted the feature-ranking branch September 23, 2024 12:57
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.

Make ranking information available under 'bruger info'
4 participants