diff --git a/app/coffee/modules/common.coffee b/app/coffee/modules/common.coffee
index 02bae5ca..4742b208 100644
--- a/app/coffee/modules/common.coffee
+++ b/app/coffee/modules/common.coffee
@@ -115,7 +115,6 @@ module.directive("tgTagLine", ["$log", TagLineDirective])
#############################################################################
ChangesDirective = ->
- # TODO: i18n
containerTemplate = _.template("""
<% if (showMoreEnabled){ %>
@@ -124,7 +123,7 @@ ChangesDirective = ->
<% } %>
- """)
+ """) # TODO: i18n
commentBaseTemplate = _.template("""
- """)
+ """) # TODO: i18n
descriptionChangeTemplate = _.template("""
@@ -226,7 +225,7 @@ ChangesDirective = ->
<% }); %>
- """)
+ """) # TODO: i18n
attachmentTemplate = _.template("""
@@ -244,10 +243,9 @@ ChangesDirective = ->
buildChangesText = (comment) ->
size = countChanges(comment)
- # TODO: i18n
if size == 1
- return "Made #{size} change"
- return "Made #{size} changes"
+ return "Made #{size} change" # TODO: i18n
+ return "Made #{size} changes" # TODO: i18n
renderEntries = (change, parentDomNode) ->
_.each change.values_diff, (modification, name) ->
@@ -265,10 +263,10 @@ ChangesDirective = ->
if attachmentType == "new"
_.each attachmentChanges, (attachmentChange) ->
parentDomNode.append(attachmentTemplate({
- name: "New attachment"
+ name: "New attachment" # TODO: i18n
description: attachmentChange.filename
}))
- else if attachmentType == "deleted"
+ else if attachmentType == "deleted" # TODO: i18n
_.each attachmentChanges, (attachmentChange) ->
parentDomNode.append(attachmentTemplate({
name: "Deleted attachment"
@@ -278,10 +276,15 @@ ChangesDirective = ->
name = "Updated attachment"
_.each attachmentChanges, (attachmentChange) ->
parentDomNode.append(attachmentTemplate({
- name: "Updated attachment"
+ name: "Updated attachment" # TODO: i18n
description: attachmentChange[0].filename
}))
-
+ else if name == "assigned_to"
+ parentDomNode.append(standardChangeFromToTemplate({
+ name: name
+ from: prettyPrintModification(modification[0]) ? "Unassigned" # TODO: i18n
+ to: prettyPrintModification(modification[1]) ? "Unassigned" # TODO: i18n
+ }))
else
parentDomNode.append(standardChangeFromToTemplate({
name: name
@@ -302,7 +305,6 @@ ChangesDirective = ->
entryDomNode = $(html)
activityContentDom = entryDomNode.find(".comment-content .us-activity")
renderEntries(comment, activityContentDom)
- console.log entryDomNode.html()
containerDomNode.append(entryDomNode)
renderChange = (change, containerDomNode, hidden) ->
@@ -328,12 +330,12 @@ ChangesDirective = ->
if typeIsArray(value)
if value.length == 0
#TODO i18n
- return "None"
+ return "None" # TODO: i18n
return value.join(", ")
if value == ""
#TODO i18n
- return "None"
+ return "None" # TODO: i18n
return value