mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
aadd sync services tab
This commit is contained in:
parent
b013e62f2e
commit
90804e8145
6 changed files with 114 additions and 17 deletions
38
dashboard-ui/scripts/syncservices.js
Normal file
38
dashboard-ui/scripts/syncservices.js
Normal file
|
@ -0,0 +1,38 @@
|
|||
(function ($, document) {
|
||||
|
||||
function reloadList(page) {
|
||||
|
||||
Dashboard.showLoadingMsg();
|
||||
|
||||
var promise1 = ApiClient.getAvailablePlugins({
|
||||
TargetSystems: 'Server'
|
||||
});
|
||||
|
||||
var promise2 = ApiClient.getInstalledPlugins();
|
||||
|
||||
$.when(promise1, promise2).done(function (response1, response2) {
|
||||
populateList(page, response1[0], response2[0]);
|
||||
});
|
||||
}
|
||||
|
||||
function populateList(page, availablePlugins, installedPlugins) {
|
||||
|
||||
PluginCatalog.renderCatalog({
|
||||
|
||||
catalogElement: $('.catalog', page),
|
||||
availablePlugins: availablePlugins,
|
||||
installedPlugins: installedPlugins,
|
||||
categories: ['Sync'],
|
||||
showCategory: false
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
$(document).on('pageshow', "#syncServicesPage", function () {
|
||||
|
||||
var page = this;
|
||||
|
||||
reloadList(page);
|
||||
});
|
||||
|
||||
})(jQuery, document);
|
Loading…
Add table
Add a link
Reference in a new issue