from django.db.models.functions import Extract
from django.db import models


@models.DateTimeField.register_lookup
class ExtractWeek(Extract):
    lookup_name = 'week'
Django queryset filtering by ISO week number