mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2026-04-20 22:14:34 -04:00
Download clients now use thingy provider
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
'use strict';
|
||||
|
||||
define(
|
||||
[
|
||||
'marionette',
|
||||
'Settings/DownloadClient/DownloadClientCollection',
|
||||
'Settings/DownloadClient/DownloadClientCollectionView',
|
||||
'Mixins/AsModelBoundView',
|
||||
'Mixins/AutoComplete',
|
||||
'bootstrap'
|
||||
], function (Marionette, DownloadClientCollection, DownloadClientCollectionView, AsModelBoundView) {
|
||||
|
||||
var view = Marionette.Layout.extend({
|
||||
template : 'Settings/DownloadClient/DownloadClientLayoutTemplate',
|
||||
|
||||
regions: {
|
||||
downloadClients: '#x-download-clients-region'
|
||||
},
|
||||
|
||||
ui: {
|
||||
droneFactory: '.x-path'
|
||||
},
|
||||
|
||||
events: {
|
||||
'change .x-download-client': 'downloadClientChanged'
|
||||
},
|
||||
|
||||
initialize: function () {
|
||||
this.downloadClientCollection = new DownloadClientCollection();
|
||||
this.downloadClientCollection.fetch();
|
||||
},
|
||||
|
||||
onShow: function () {
|
||||
this.downloadClients.show(new DownloadClientCollectionView({ collection: this.downloadClientCollection }));
|
||||
this.ui.droneFactory.autoComplete('/directories');
|
||||
}
|
||||
});
|
||||
|
||||
return AsModelBoundView.call(view);
|
||||
});
|
||||
Reference in New Issue
Block a user