Skip to content

Commit

Permalink
Améliorer les performances de la page événement
Browse files Browse the repository at this point in the history
  • Loading branch information
Anto59290 committed Feb 28, 2025
1 parent 84d2ebd commit da9dab9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion sv/tests/test_evenement_performance_details.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,5 +151,5 @@ def test_fiche_zone_delimitee_with_multiple_zone_infestee(

client.get(evenement.get_absolute_url())

with django_assert_num_queries(BASE_NUM_QUERIES + 25):
with django_assert_num_queries(BASE_NUM_QUERIES + 23):
client.get(evenement.get_absolute_url())
1 change: 1 addition & 0 deletions sv/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ def get_queryset(self):
.order_by("numero_detection_only"),
),
"detections__createur",
"detections__contexte",
Prefetch(
"detections__lieux__prelevements",
queryset=Prelevement.objects.select_related(
Expand Down

0 comments on commit da9dab9

Please sign in to comment.