mirror of
https://github.com/Sonarr/Sonarr.git
synced 2024-12-16 11:37:58 +02:00
33 lines
723 B
JavaScript
33 lines
723 B
JavaScript
'use strict';
|
|
|
|
define(
|
|
[
|
|
'backgrid'
|
|
], function (Backgrid) {
|
|
return Backgrid.Cell.extend({
|
|
|
|
className: 'download-report-cell',
|
|
|
|
events: {
|
|
'click': '_onClick'
|
|
},
|
|
|
|
_onClick: function () {
|
|
|
|
var self = this;
|
|
|
|
this.$el.html('<i class =\'icon-spinner icon-spin\' />');
|
|
this.model.save().always(function () {
|
|
self.$el.html('<i class =\'icon-download-alt\' />');
|
|
});
|
|
},
|
|
|
|
render: function () {
|
|
|
|
this.$el.html('<i class =\'icon-download-alt\' />');
|
|
return this;
|
|
|
|
}
|
|
});
|
|
});
|