Skip to content
Snippets Groups Projects
Commit 10f8be5a authored by Mattia Mancini's avatar Mattia Mancini
Browse files

OSB-28: change dateformat string

parent 04c48e56
No related branches found
No related tags found
2 merge requests!89Monitoring maintenance Epic branch merge,!1Resolve OSB-13 "Monitoringmaintenance "
...@@ -515,13 +515,13 @@ result: ...@@ -515,13 +515,13 @@ result:
annotate(n_errors=Count('observation__station__name')) annotate(n_errors=Count('observation__station__name'))
errors_per_station_in_bin = dict() errors_per_station_in_bin = dict()
central_time_str = central_time.strftime('%Y-%m-%d')
if test_type in ['S', 'B']: if test_type in ['S', 'B']:
for result in station_test_results: for result in station_test_results:
station_name = result['station_test__station__name'] station_name = result['station_test__station__name']
errors_per_station_in_bin[station_name] = dict(station_name=station_name, errors_per_station_in_bin[station_name] = dict(station_name=station_name,
n_errors=result['n_errors'], n_errors=result['n_errors'],
time=central_time) time=central_time_str)
if test_type in ['R', 'B']: if test_type in ['R', 'B']:
for result in rtsm_results: for result in rtsm_results:
...@@ -529,7 +529,7 @@ result: ...@@ -529,7 +529,7 @@ result:
if station_name not in errors_per_station_in_bin: if station_name not in errors_per_station_in_bin:
errors_per_station_in_bin[station_name] = dict(station_name=station_name, errors_per_station_in_bin[station_name] = dict(station_name=station_name,
n_errors=result['n_errors'], n_errors=result['n_errors'],
time=central_time) time=central_time_str)
else: else:
errors_per_station_in_bin[station_name]['n_errors'] += result['n_errors'] errors_per_station_in_bin[station_name]['n_errors'] += result['n_errors']
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment