Fix completed percent in metatags

stable
David Barragán Merino 2015-06-10 17:11:32 +02:00
parent 09754d3df8
commit 7083e78a22
1 changed files with 1 additions and 1 deletions

View File

@ -67,7 +67,7 @@ class UserStoryDetailController extends mixOf(taiga.Controller, taiga.PageMixin)
_setMeta: ->
totalTasks = @scope.tasks.length
closedTasks = _.filter(@scope.tasks, (t) => @scope.taskStatusById[t.status].is_closed).length
progressPercentage = if totalTasks > 0 then 100 * closedTasks / totalTasks else 0
progressPercentage = if totalTasks > 0 then Math.round(100 * closedTasks / totalTasks) else 0
title = @translate.instant("US.PAGE_TITLE", {
userStoryRef: "##{@scope.us.ref}"