mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
remove legacy jquery function from source
This commit is contained in:
parent
ca4001f5b7
commit
739473c0fb
11 changed files with 76 additions and 103 deletions
|
@ -1,16 +1,8 @@
|
|||
define(['jQuery', 'loading', 'globalize', 'fnchecked', 'emby-checkbox', 'emby-textarea', 'emby-input', 'emby-select', 'emby-button'], function ($, loading, globalize) {
|
||||
define(['jQuery', 'loading', 'globalize', 'emby-checkbox', 'emby-textarea', 'emby-input', 'emby-select', 'emby-button'], function ($, loading, globalize) {
|
||||
'use strict';
|
||||
|
||||
function loadPage(page, config, languageOptions, systemInfo) {
|
||||
page.querySelector('#txtServerName').value = systemInfo.ServerName;
|
||||
$('#chkAutoRunWebApp', page).checked(config.AutoRunWebApp);
|
||||
|
||||
if (systemInfo.CanLaunchWebBrowser) {
|
||||
page.querySelector('#fldAutoRunWebApp').classList.remove('hide');
|
||||
} else {
|
||||
page.querySelector('#fldAutoRunWebApp').classList.add('hide');
|
||||
}
|
||||
|
||||
page.querySelector('#txtCachePath').value = systemInfo.CachePath || '';
|
||||
$('#txtMetadataPath', page).val(systemInfo.InternalMetadataPath || '');
|
||||
$('#txtMetadataNetworkPath', page).val(systemInfo.MetadataNetworkPath || '');
|
||||
|
@ -18,11 +10,6 @@ define(['jQuery', 'loading', 'globalize', 'fnchecked', 'emby-checkbox', 'emby-te
|
|||
return '<option value="' + language.Value + '">' + language.Name + '</option>';
|
||||
})).val(config.UICulture);
|
||||
currentLanguage = config.UICulture;
|
||||
if (systemInfo.CanSelfRestart || systemInfo.CanSelfUpdate) {
|
||||
$('.autoUpdatesContainer', page).removeClass('hide');
|
||||
} else {
|
||||
$('.autoUpdatesContainer', page).addClass('hide');
|
||||
}
|
||||
|
||||
loading.hide();
|
||||
}
|
||||
|
@ -38,7 +25,6 @@ define(['jQuery', 'loading', 'globalize', 'fnchecked', 'emby-checkbox', 'emby-te
|
|||
config.MetadataPath = $('#txtMetadataPath', form).val();
|
||||
config.MetadataNetworkPath = $('#txtMetadataNetworkPath', form).val();
|
||||
var requiresReload = config.UICulture !== currentLanguage;
|
||||
config.AutoRunWebApp = $('#chkAutoRunWebApp', form).checked();
|
||||
ApiClient.updateServerConfiguration(config).then(function() {
|
||||
ApiClient.getNamedConfiguration(brandingConfigKey).then(function(brandingConfig) {
|
||||
brandingConfig.LoginDisclaimer = form.querySelector('#txtLoginDisclaimer').value;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue