Skip to content

Commit c9d7089

Browse files
committed
Fix tooltip on overview chart
- Legacy-Id: 13269
1 parent 365143f commit c9d7089

2 files changed

Lines changed: 3 additions & 4 deletions

File tree

ietf/stats/views.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -878,7 +878,7 @@ def get_country_mapping(registrations):
878878
series_data.sort(key=lambda t: t[0])
879879
table_data.sort(key=lambda t: t[0], reverse=True)
880880

881-
chart_data.append({ "data": series_data })
881+
chart_data.append({ "name": "Registrations", "data": series_data })
882882

883883

884884
elif stats_type == "country":
@@ -924,7 +924,6 @@ def get_country_mapping(registrations):
924924

925925
return render(request, "stats/meeting_stats.html", {
926926
"chart_data": mark_safe(json.dumps(chart_data)),
927-
"use_legend": chart_data and chart_data[0].get("name"),
928927
"piechart_data": mark_safe(json.dumps(piechart_data)),
929928
"table_data": table_data,
930929
"stats_title": stats_title,

ietf/templates/stats/meeting_stats_overview.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ <h3>{{ stats_title }}</h3>
1515
animation: false
1616
}
1717
},
18-
{% if use_legend %}
18+
{% if stats_type != "overview" %}
1919
legend: {
2020
align: "right",
2121
verticalAlign: "middle",
@@ -40,7 +40,7 @@ <h3>{{ stats_title }}</h3>
4040
},
4141
tooltip: {
4242
formatter: function () {
43-
var s = '<b>' + this.x + '</b>';
43+
var s = '<b>' + "IETF " + this.x + '</b>';
4444

4545
$.each(this.points, function () {
4646
s += '<br/>' + this.series.name + ': ' + this.y;

0 commit comments

Comments
 (0)