1
0
mirror of https://gitlab.crans.org/bde/nk20-scripts synced 2025-07-02 02:48:29 +02:00

Compare commits

..

1 Commits

Author SHA1 Message Date
9ad207f1e7 Merge branch 'add_year_tag' into 'master'
Extraction ML Adhérents des années N et N-years

See merge request bde/nk20-scripts!3
2023-03-19 01:53:20 +01:00

View File

@ -32,7 +32,7 @@ class Command(BaseCommand):
notes = Note.objects.filter(
Q(noteuser__user__memberships__date_end__gte=
date.today() - timedelta(days=int(365.25 * options['add_years'])))
| (Q(noteclub__isnull=False) & ~Q(noteclub__club__name__icontains='- BDE')),
| Q(noteclub__isnull=False),
balance__lte=-options["negative_amount"],
is_active=True,
).order_by('balance').distinct().all()