# Reduces db access
* reduces number of queries performed on detail views of intervention, compensation and eco_account
* renders deductable_rest of eco account beneath progressbar on eco account index view
* clarifies ordering logic of related column
This commit is contained in:
@@ -204,7 +204,11 @@ def detail_view(request: HttpRequest, id: str):
|
||||
"""
|
||||
template = "compensation/detail/compensation/view.html"
|
||||
comp = get_object_or_404(
|
||||
Compensation,
|
||||
Compensation.objects.select_related(
|
||||
"modified",
|
||||
"created",
|
||||
"geometry"
|
||||
),
|
||||
id=id,
|
||||
deleted=None,
|
||||
intervention__deleted=None,
|
||||
|
||||
Reference in New Issue
Block a user