mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-16 10:03:51 -07:00
Added spinner to add series buttons
This commit is contained in:
parent
8713ebefd6
commit
2c519a7dcd
4 changed files with 18 additions and 3 deletions
|
@ -20,6 +20,8 @@ define(['app', 'Series/SeriesCollection'], function (app) {
|
|||
},
|
||||
|
||||
addSeries: function () {
|
||||
var icon = this.ui.addButton.find('icon');
|
||||
icon.removeClass('icon-plus').addClass('icon-spin icon-spinner disabled');
|
||||
|
||||
var quality = this.ui.qualityProfile.val();
|
||||
var rootFolderId = this.ui.rootFolder.val();
|
||||
|
@ -32,11 +34,15 @@ define(['app', 'Series/SeriesCollection'], function (app) {
|
|||
this.model.save(undefined, {
|
||||
url : NzbDrone.Series.SeriesCollection.prototype.url,
|
||||
success: function () {
|
||||
icon.removeClass('icon-spin icon-spinner disabled').addClass('icon-search');
|
||||
NzbDrone.Shared.Messenger.show({
|
||||
message: 'Added: ' + self.model.get('title')
|
||||
});
|
||||
|
||||
NzbDrone.vent.trigger(NzbDrone.Events.SeriesAdded, { existing: false, series: self.model });
|
||||
},
|
||||
fail: function () {
|
||||
icon.removeClass('icon-spin icon-spinner disabled').addClass('icon-search');
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue