From 0dcc6b92a4b6088a1bdaeb821e73130177755316 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Barrag=C3=A1n=20Merino?= Date: Sat, 20 Jun 2015 22:15:32 +0200 Subject: [PATCH] Improve the tooltips of the burndown graph --- app/coffee/modules/backlog/main.coffee | 8 ++++---- app/locales/locale-en.json | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/app/coffee/modules/backlog/main.coffee b/app/coffee/modules/backlog/main.coffee index 845f33a7..bdafb0fd 100644 --- a/app/coffee/modules/backlog/main.coffee +++ b/app/coffee/modules/backlog/main.coffee @@ -995,16 +995,16 @@ BurndownBacklogGraphDirective = ($translate) -> tooltipOpts: { content: (label, xval, yval, flotItem) -> if flotItem.seriesIndex == 1 - ctx = {xval: xval, yval: yval} + ctx = {sprintName: dataToDraw.milestones[xval].name, value: Math.abs(yval)} return $translate.instant("BACKLOG.CHART.OPTIMAL", ctx) else if flotItem.seriesIndex == 2 - ctx = {xval: xval, yval: yval} + ctx = {sprintName: dataToDraw.milestones[xval].name, value: Math.abs(yval)} return $translate.instant("BACKLOG.CHART.REAL", ctx) else if flotItem.seriesIndex == 3 - ctx = {xval: xval, yval: Math.abs(yval)} + ctx = {sprintName: dataToDraw.milestones[xval].name, value: Math.abs(yval)} return $translate.instant("BACKLOG.CHART.INCREMENT_TEAM", ctx) else - ctx = {xval: xval, yval: Math.abs(yval)} + ctx = {sprintName: dataToDraw.milestones[xval].name, value: Math.abs(yval)} return $translate.instant("BACKLOG.CHART.INCREMENT_CLIENT", ctx) } } diff --git a/app/locales/locale-en.json b/app/locales/locale-en.json index c684c476..b619d1fc 100644 --- a/app/locales/locale-en.json +++ b/app/locales/locale-en.json @@ -894,10 +894,10 @@ "CHART": { "XAXIS_LABEL": "Sprints", "YAXIS_LABEL": "Points", - "OPTIMAL": "Optimal pending points for sprint {{xval}} should be {{yval}}", - "REAL": "Real pending points for sprint {{xval}} is {{yval}}", - "INCREMENT_TEAM": "Incremented points by team requirements for sprint {{xval}} is {{yval}}", - "INCREMENT_CLIENT": "Incremented points by client requirements for sprint {{xval}} is {{yval}}" + "OPTIMAL": "Optimal pending points for sprint \"{{sprintName}}\" should be {{value}}", + "REAL": "Real pending points for sprint \"{{sprintName}}\" is {{value}}", + "INCREMENT_TEAM": "Incremented points by team requirements for sprint \"{{sprintName}}\" is {{value}}", + "INCREMENT_CLIENT": "Incremented points by client requirements for sprint \"{{sprintName}}\" is {{value}}" }, "TAGS": { "TOGGLE": "Toggle tags visibility",