diff options
author | NavaL <mnandri@thoughtworks.com> | 2016-01-11 17:54:53 +0100 |
---|---|---|
committer | NavaL <mnandri@thoughtworks.com> | 2016-01-11 17:54:53 +0100 |
commit | 0c6c8bed304884ab5f3ade69fb0d68d2cbe043e6 (patch) | |
tree | 1d95481fe628ac4878bc1c0670c9e4b50a10e9cc /web-ui/app/js/mail_view/ui/attachment_list.js | |
parent | 058d14143c179d9923eea433fc63094f4f9059aa (diff) |
format attachment size
Issue #573
Diffstat (limited to 'web-ui/app/js/mail_view/ui/attachment_list.js')
-rw-r--r-- | web-ui/app/js/mail_view/ui/attachment_list.js | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/web-ui/app/js/mail_view/ui/attachment_list.js b/web-ui/app/js/mail_view/ui/attachment_list.js index 32a48d0b..632242ca 100644 --- a/web-ui/app/js/mail_view/ui/attachment_list.js +++ b/web-ui/app/js/mail_view/ui/attachment_list.js @@ -17,10 +17,11 @@ define( [ - 'page/events' + 'page/events', + 'helpers/view_helper' ], - function (events) { + function (events, viewHelper) { 'use strict'; function attachmentList() { @@ -54,7 +55,7 @@ define( this.buildAttachmentListItem = function (attachment) { return '<a href="' + this.attr.attachmentBaseUrl + '/' + attachment.ident + '?filename=' + - attachment.name + '&encoding=' + attachment.encoding + '">' + attachment.name + ' (' + humanReadable(attachment.size) + ')' + + attachment.name + '&encoding=' + attachment.encoding + '">' + attachment.name + ' (' + viewHelper.formatSize(attachment.size) + ')' + '</a>'; }; |