diff --git a/financeplanner/static/financeplanner/style.css b/financeplanner/static/financeplanner/style.css index ff4f4e2..3150e56 100644 --- a/financeplanner/static/financeplanner/style.css +++ b/financeplanner/static/financeplanner/style.css @@ -148,6 +148,13 @@ tr:hover { color: #CC6622; } +#date-panel { + width: 80%; + opacity: 50%; + font-size: 1.5em; + text-align: center; +} + #graph { flex: 0 0 300px; width: 100%; @@ -216,29 +223,3 @@ tr:hover { box-shadow: #FFFCF9 0 0 12px; opacity: 100%; } - -.tooltip { - position: relative; - display: inline-block; -} - -.tooltip .tooltiptext { - visibility: hidden; - opacity: 90%; - width: 150px; - min-height: 50px; - background-color: #131211; - padding: 6px; - border-radius: 4px; - position: absolute; - bottom: 100%; - margin-bottom: 3px; - left: 50%; - margin-left: -75px; - z-index: 1; -} - -.tooltip:hover .tooltiptext { - visibility: visible; -} - diff --git a/financeplanner/templates/financeplanner/index.html b/financeplanner/templates/financeplanner/index.html index 8d04fb6..0770d37 100644 --- a/financeplanner/templates/financeplanner/index.html +++ b/financeplanner/templates/financeplanner/index.html @@ -19,17 +19,19 @@
{% if graph_data %} -

Data from {{ range_start }} til {{ range_end }}

+
-
{% for date, stat in graph_data.items %} {% if stat.div_percentage is None %} -
- {{ date }}
unknown
+
{% else %} -
- {{ date }}
{{ stat.amount }}€
+
{% endif %} {% endfor %} @@ -120,36 +122,45 @@
diff --git a/financeplanner/views.py b/financeplanner/views.py index f63bdcb..178e6be 100644 --- a/financeplanner/views.py +++ b/financeplanner/views.py @@ -151,6 +151,7 @@ def _build_graph_data(range_start, range_end, calculation_start, balance_list, a stats = _trim_stats(stats, range_start) amount_limit = _calculate_scale(stats) for date in stats.keys(): + stats[date]["date_string"] = format_date(date) amount = stats[date]["amount"] if amount is None: stats[date]["div_percentage"] = None