7
7
8
8
from .parameters import Parameters
9
9
from .utils import add_date_column
10
+ from .presentation import DATE_FORMAT
10
11
11
12
12
13
def new_admissions_chart (
@@ -26,7 +27,7 @@ def new_admissions_chart(
26
27
tooltip_dict = {False : "day" , True : "date:T" }
27
28
if as_date :
28
29
projection_admits = add_date_column (projection_admits )
29
- x_kwargs = {"shorthand" : "date:T" , "title" : "Date" }
30
+ x_kwargs = {"shorthand" : "date:T" , "title" : "Date" , "axis" : alt . Axis ( format = ( DATE_FORMAT )) }
30
31
else :
31
32
x_kwargs = {"shorthand" : "day" , "title" : "Days from today" }
32
33
@@ -58,7 +59,7 @@ def admitted_patients_chart(
58
59
as_date = parameters .as_date
59
60
if as_date :
60
61
census = add_date_column (census )
61
- x_kwargs = {"shorthand" : "date:T" , "title" : "Date" }
62
+ x_kwargs = {"shorthand" : "date:T" , "title" : "Date" , "axis" : alt . Axis ( format = ( DATE_FORMAT )) }
62
63
idx = "date:T"
63
64
else :
64
65
x_kwargs = {"shorthand" : "day" , "title" : "Days from today" }
@@ -101,7 +102,7 @@ def additional_projections_chart(
101
102
102
103
if as_date :
103
104
dat = add_date_column (dat )
104
- x_kwargs = {"shorthand" : "date:T" , "title" : "Date" }
105
+ x_kwargs = {"shorthand" : "date:T" , "title" : "Date" , "axis" : alt . Axis ( format = ( DATE_FORMAT )) }
105
106
else :
106
107
x_kwargs = {"shorthand" : "day" , "title" : "Days from today" }
107
108
0 commit comments