mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
merge from dev
This commit is contained in:
parent
1c8f02ce0f
commit
33b01d778c
911 changed files with 34157 additions and 57125 deletions
|
@ -20,7 +20,7 @@
|
|||
|
||||
Dashboard.showLoadingMsg();
|
||||
|
||||
ApiClient.getServerConfiguration().done(function (config) {
|
||||
ApiClient.getServerConfiguration().then(function (config) {
|
||||
|
||||
config.ImageSavingConvention = $('#selectImageSavingConvention', form).val();
|
||||
|
||||
|
@ -29,7 +29,7 @@
|
|||
config.PreferredMetadataLanguage = $('#selectLanguage', form).val();
|
||||
config.MetadataCountryCode = $('#selectCountry', form).val();
|
||||
|
||||
ApiClient.updateServerConfiguration(config).done(Dashboard.processServerConfigurationUpdateResult);
|
||||
ApiClient.updateServerConfiguration(config).then(Dashboard.processServerConfigurationUpdateResult);
|
||||
});
|
||||
|
||||
// Disable default form submission
|
||||
|
@ -52,23 +52,55 @@
|
|||
var allCultures;
|
||||
var allCountries;
|
||||
|
||||
ApiClient.getServerConfiguration().done(function (result) {
|
||||
ApiClient.getServerConfiguration().then(function (result) {
|
||||
|
||||
config = result;
|
||||
load(page, config, allCultures, allCountries);
|
||||
});
|
||||
|
||||
ApiClient.getCultures().done(function (result) {
|
||||
function populateLanguages(select, languages) {
|
||||
|
||||
Dashboard.populateLanguages($('#selectLanguage', page), result);
|
||||
var html = "";
|
||||
|
||||
html += "<option value=''></option>";
|
||||
|
||||
for (var i = 0, length = languages.length; i < length; i++) {
|
||||
|
||||
var culture = languages[i];
|
||||
|
||||
html += "<option value='" + culture.TwoLetterISOLanguageName + "'>" + culture.DisplayName + "</option>";
|
||||
}
|
||||
|
||||
select.innerHTML = html;
|
||||
}
|
||||
|
||||
function populateCountries(select, allCountries) {
|
||||
|
||||
var html = "";
|
||||
|
||||
html += "<option value=''></option>";
|
||||
|
||||
for (var i = 0, length = allCountries.length; i < length; i++) {
|
||||
|
||||
var culture = allCountries[i];
|
||||
|
||||
html += "<option value='" + culture.TwoLetterISORegionName + "'>" + culture.DisplayName + "</option>";
|
||||
}
|
||||
|
||||
select.innerHTML = html;
|
||||
}
|
||||
|
||||
ApiClient.getCultures().then(function (result) {
|
||||
|
||||
populateLanguages(page.querySelector('#selectLanguage'), result);
|
||||
|
||||
allCultures = result;
|
||||
load(page, config, allCultures, allCountries);
|
||||
});
|
||||
|
||||
ApiClient.getCountries().done(function (result) {
|
||||
ApiClient.getCountries().then(function (result) {
|
||||
|
||||
Dashboard.populateCountries($('#selectCountry', page), result);
|
||||
populateCountries(page.querySelector('#selectCountry'), result);
|
||||
|
||||
allCountries = result;
|
||||
load(page, config, allCultures, allCountries);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue