doorcontrol: Improve performance of door access report views
This commit is contained in:
parent
72fa458f6e
commit
70691ff972
@ -61,7 +61,10 @@ class BaseAccessReport(PermissionRequiredMixin, ListView):
|
||||
|
||||
def get_queryset(self):
|
||||
return (
|
||||
super().get_queryset().filter(timestamp__range=self._get_timestamp_range())
|
||||
super()
|
||||
.get_queryset()
|
||||
.filter(timestamp__range=self._get_timestamp_range())
|
||||
.select_related("door")
|
||||
)
|
||||
|
||||
def get_context_data(self, **kwargs):
|
||||
|
Loading…
Reference in New Issue
Block a user