2013-06-22 06:24:24 +00:00
|
|
|
'use strict';
|
2013-06-09 20:51:32 +00:00
|
|
|
|
2013-06-24 23:41:59 +00:00
|
|
|
define(
|
|
|
|
[
|
|
|
|
'backgrid',
|
|
|
|
'Shared/FormatHelpers'
|
|
|
|
], function (Backgrid, FormatHelpers) {
|
|
|
|
return Backgrid.Cell.extend({
|
2013-06-09 20:51:32 +00:00
|
|
|
|
2013-06-24 23:41:59 +00:00
|
|
|
className: 'file-size-cell',
|
2013-06-09 20:51:32 +00:00
|
|
|
|
2013-06-24 23:41:59 +00:00
|
|
|
render: function () {
|
|
|
|
var size = this.model.get(this.column.get('name'));
|
2013-08-04 01:27:12 +00:00
|
|
|
this.$el.html(FormatHelpers.bytes(size));
|
2013-06-24 23:41:59 +00:00
|
|
|
this.delegateEvents();
|
|
|
|
return this;
|
|
|
|
}
|
|
|
|
});
|
2013-06-09 20:51:32 +00:00
|
|
|
});
|