Bugfix
* fixes bug in excel report creation * fixes order in laws of generated excel sheet
This commit is contained in:
parent
c9485bc8e0
commit
9d0677e170
@ -17,6 +17,7 @@ from compensation.models import Compensation, Payment, EcoAccountDeduction, EcoA
|
|||||||
from intervention.models import Intervention
|
from intervention.models import Intervention
|
||||||
from konova.models import Geometry
|
from konova.models import Geometry
|
||||||
from konova.sub_settings.django_settings import BASE_DIR, DEFAULT_DATE_FORMAT
|
from konova.sub_settings.django_settings import BASE_DIR, DEFAULT_DATE_FORMAT
|
||||||
|
from konova.sub_settings.lanis_settings import DEFAULT_SRID_RLP
|
||||||
|
|
||||||
|
|
||||||
class TimespanReport:
|
class TimespanReport:
|
||||||
@ -103,9 +104,9 @@ class TimespanReport:
|
|||||||
"iterable": self.evaluated_laws,
|
"iterable": self.evaluated_laws,
|
||||||
"attrs": [
|
"attrs": [
|
||||||
"short_name",
|
"short_name",
|
||||||
|
"num",
|
||||||
"num_checked",
|
"num_checked",
|
||||||
"num_recorded",
|
"num_recorded",
|
||||||
"num",
|
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"i_laws_checked": self.law_sum_checked,
|
"i_laws_checked": self.law_sum_checked,
|
||||||
@ -333,7 +334,7 @@ class TimespanReport:
|
|||||||
return Geometry.objects.filter(
|
return Geometry.objects.filter(
|
||||||
id__in=ids
|
id__in=ids
|
||||||
).annotate(
|
).annotate(
|
||||||
geom_cast=Cast("geom", MultiPolygonField())
|
geom_cast=Cast("geom", MultiPolygonField(srid=DEFAULT_SRID_RLP))
|
||||||
).annotate(
|
).annotate(
|
||||||
num=NumGeometries("geom_cast")
|
num=NumGeometries("geom_cast")
|
||||||
).aggregate(
|
).aggregate(
|
||||||
|
Loading…
Reference in New Issue
Block a user