week_day field lookup is not working on `MultilingualQuerySet`
janezicmatej opened this issue · 2 comments
janezicmatej commented
Lets say i have a model called Entry
class Entry(models.Model):
name = models.CharField(max_length=100)
day = models.DateField()
which i register for translations like this
@register(Entry)
class EntryTranslationOptions(TranslationOptions):
fields = ("name",)
querying
some_query = Entry.objects.filter(day__week_day=1)
always returns empty MultilingualQuerySet
last-partizan commented
Please fork django-modeltranslation
and add test for your case. If you can reproduce issue, i can try to fix it.
Or create empty repo with minimal reproduction.
janezicmatej commented
Well this is embarassing, turns out I got my django lookups mixed up. I forgot Django numbers days 1-7 for sunday through saturday.
Thanks for being prepared to help!
I'll mark this issue as closed now.