Fixed bug: App.PrettyDate.humanTime generates broken HTML markup if escalation flag is true.
This commit is contained in:
parent
178f0dfa17
commit
0f484d0ed5
1 changed files with 5 additions and 5 deletions
|
@ -36,7 +36,7 @@ class App.PrettyDate
|
||||||
if type is 'timestamp'
|
if type is 'timestamp'
|
||||||
string = App.i18n.translateTimestamp(time)
|
string = App.i18n.translateTimestamp(time)
|
||||||
if escalation
|
if escalation
|
||||||
string = "<span #{style}>#{string}</b>"
|
string = "<span #{style}>#{string}</span>"
|
||||||
return string
|
return string
|
||||||
|
|
||||||
if type is 'absolute' && (direction is 'past' || direction is 'future')
|
if type is 'absolute' && (direction is 'past' || direction is 'future')
|
||||||
|
@ -59,7 +59,7 @@ class App.PrettyDate
|
||||||
else
|
else
|
||||||
string = "#{App.i18n.translateInline(weekday)} #{App.i18n.translateTimestamp(time)}"
|
string = "#{App.i18n.translateInline(weekday)} #{App.i18n.translateTimestamp(time)}"
|
||||||
if escalation
|
if escalation
|
||||||
string = "<span #{style}>#{string}</b>"
|
string = "<span #{style}>#{string}</span>"
|
||||||
return string
|
return string
|
||||||
|
|
||||||
if direction is 'past' && !escalation && diff > ( 60 * 60 * 24 * 7 )
|
if direction is 'past' && !escalation && diff > ( 60 * 60 * 24 * 7 )
|
||||||
|
@ -86,7 +86,7 @@ class App.PrettyDate
|
||||||
else
|
else
|
||||||
string = App.i18n.translateInline('in %s', string)
|
string = App.i18n.translateInline('in %s', string)
|
||||||
if escalation
|
if escalation
|
||||||
string = "<span #{style}>#{string}</b>"
|
string = "<span #{style}>#{string}</span>"
|
||||||
return string
|
return string
|
||||||
|
|
||||||
# hours
|
# hours
|
||||||
|
@ -110,7 +110,7 @@ class App.PrettyDate
|
||||||
else
|
else
|
||||||
string = App.i18n.translateInline('in %s', string)
|
string = App.i18n.translateInline('in %s', string)
|
||||||
if escalation
|
if escalation
|
||||||
string = "<span #{style}>#{string}</b>"
|
string = "<span #{style}>#{string}</span>"
|
||||||
return string
|
return string
|
||||||
|
|
||||||
# minutes
|
# minutes
|
||||||
|
@ -130,7 +130,7 @@ class App.PrettyDate
|
||||||
else
|
else
|
||||||
string = App.i18n.translateInline('in %s', string)
|
string = App.i18n.translateInline('in %s', string)
|
||||||
if escalation
|
if escalation
|
||||||
string = "<span #{style}>#{string}</b>"
|
string = "<span #{style}>#{string}</span>"
|
||||||
return string
|
return string
|
||||||
|
|
||||||
@s: (num, digits) ->
|
@s: (num, digits) ->
|
||||||
|
|
Loading…
Reference in a new issue