|
@@ -77,7 +77,8 @@ class Variable(RowClass):
|
77
|
77
|
def getall_values_of_type_since(type: VariableType, since: int) -> dict:
|
78
|
78
|
floatcast = lambda x: round(float(x) / 10, 2)
|
79
|
79
|
cast_fct = floatcast if type.slabel == 'A' else lambda x: x
|
80
|
|
- type.__dict__.update({'since': since})
|
|
80
|
+ params = type.__dict__.copy()
|
|
81
|
+ params.update({'since': since})
|
81
|
82
|
|
82
|
83
|
return {
|
83
|
84
|
row['address']: cast_fct(row['value'])
|
|
@@ -94,7 +95,7 @@ class Variable(RowClass):
|
94
|
95
|
AND var.address >= :start_address
|
95
|
96
|
AND var.address <= :end_address
|
96
|
97
|
AND var.last_update > :since""",
|
97
|
|
- type.__dict__)
|
|
98
|
+ params)
|
98
|
99
|
|
99
|
100
|
if row['address'] and row['value']
|
100
|
101
|
}
|