mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
update startup wizard
This commit is contained in:
parent
681639cc95
commit
b4c8cb07c9
16 changed files with 256 additions and 70 deletions
35
dashboard-ui/scripts/wizardcontroller.js
Normal file
35
dashboard-ui/scripts/wizardcontroller.js
Normal file
|
@ -0,0 +1,35 @@
|
|||
define([], function () {
|
||||
|
||||
function navigateToComponents() {
|
||||
var apiClient = ApiClient;
|
||||
|
||||
apiClient.getJSON(apiClient.getUrl('Startup/Info')).then(function (info) {
|
||||
|
||||
if (info.HasMediaEncoder) {
|
||||
navigateToService();
|
||||
|
||||
} else {
|
||||
Dashboard.navigate('wizardcomponents.html');
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function navigateToService() {
|
||||
var apiClient = ApiClient;
|
||||
|
||||
apiClient.getJSON(apiClient.getUrl('Startup/Info')).then(function (info) {
|
||||
|
||||
if (info.SupportsRunningAsService) {
|
||||
Dashboard.navigate('wizardservice.html');
|
||||
|
||||
} else {
|
||||
Dashboard.navigate('wizardagreement.html');
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
return {
|
||||
navigateToComponents: navigateToComponents,
|
||||
navigateToService: navigateToService
|
||||
};
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue