adamcharnock / django-hordak

Double entry accounting in Django
http://django-hordak.readthedocs.io
MIT License
238 stars 55 forks source link

TransactionAdmin: make it faster by caching description values #105

Closed PetrDlouhy closed 3 months ago

codecov-commenter commented 1 year ago

Codecov Report

Patch coverage: 73.33% and project coverage change: -0.16% :warning:

Comparison is base (79703ea) 92.97% compared to head (f13e807) 92.81%. Report is 1 commits behind head on master.

:exclamation: Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #105 +/- ## ========================================== - Coverage 92.97% 92.81% -0.16% ========================================== Files 59 59 Lines 3829 3844 +15 Branches 250 254 +4 ========================================== + Hits 3560 3568 +8 - Misses 224 229 +5 - Partials 45 47 +2 ``` | [Files Changed](https://app.codecov.io/gh/adamcharnock/django-hordak/pull/105?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Adam+Charnock) | Coverage Δ | | |---|---|---| | [hordak/admin.py](https://app.codecov.io/gh/adamcharnock/django-hordak/pull/105?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Adam+Charnock#diff-aG9yZGFrL2FkbWluLnB5) | `92.70% <73.33%> (-7.30%)` | :arrow_down: |

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

adamcharnock commented 3 months ago

@PetrDlouhy – As part of my work on #127 I realise that I removed description from list_filter. I removed it because it seemed like the kind of field I would normally search against, but not filter against. However I'm guessing you've been using it as a category field of some kind?

I'm inclined to continue omitting description from list_filter, but could you extend the TransactionAdmin class on your site and customise it as you need?

I think there is also a wider conversation to be had regarding customisability. In particular people wanting to add fields to models. (UPDATE: Created #132)

PetrDlouhy commented 3 months ago

@adamcharnock You are right, that having only few different descriptions would be rather project specific. So yes, I would add it to my TransactionAdmin extension.

adamcharnock commented 3 months ago

Ok, thanks! I'll go ahead and close this then.