diff --git a/Web/scripts/admin/schedule.js b/Web/scripts/admin/schedule.js index ecbbbcb2ed..0d21f99d8e 100644 --- a/Web/scripts/admin/schedule.js +++ b/Web/scripts/admin/schedule.js @@ -666,7 +666,7 @@ function ScheduleManagement(opts) { allDaySlot: false, initialDate: opts.calendarOptions.defaultDate, initialView: 'dayGridMonth', - locale: (document.documentElement.lang || 'en').replace('_', '-'), + locale: document.documentElement.lang.slice(0, 2) || 'en', views: { dayGridMonth: { buttonText: opts.calendarOptions.buttonText.month }, timeGridWeek: { buttonText: opts.calendarOptions.buttonText.week }, diff --git a/Web/scripts/calendar.js b/Web/scripts/calendar.js index f4df0717f8..64a8484ee1 100644 --- a/Web/scripts/calendar.js +++ b/Web/scripts/calendar.js @@ -16,9 +16,6 @@ function Calendar(opts) { }; // Helper functions for FullCalendar v6 - function normalizeLocale(locale) { - return (locale || document.documentElement.lang || 'en').replace('_', '-'); - } function mapCurrentViewToLegacy(viewType) { switch (viewType) { @@ -93,7 +90,7 @@ function Calendar(opts) { weekNumbers: _options.showWeekNumbers, initialView: mapLegacyViewToCurrent(_options.view), initialDate: _options.defaultDate, - locale: normalizeLocale(_options.locale), + locale: document.documentElement.lang.slice(0, 2) || 'en', events: { url: _options.eventsUrl, extraParams: function () { diff --git a/lang/ar.php b/lang/ar.php index 94ee5f3c65..97a1063b30 100644 --- a/lang/ar.php +++ b/lang/ar.php @@ -1103,6 +1103,6 @@ protected function _LoadLetters() protected function _GetHtmlLangCode() { - return 'en'; + return 'ar'; } } diff --git a/lang/cz.php b/lang/cz.php index 9db541ce23..c46bbee401 100644 --- a/lang/cz.php +++ b/lang/cz.php @@ -911,6 +911,6 @@ protected function _LoadLetters() protected function _GetHtmlLangCode() { - return 'cz'; + return 'cs'; } } diff --git a/lang/du_be.php b/lang/du_be.php index 02c04fe0cd..9c45b6a976 100644 --- a/lang/du_be.php +++ b/lang/du_be.php @@ -481,6 +481,6 @@ protected function _LoadLetters() protected function _GetHtmlLangCode() { - return 'en_us'; + return 'nl-BE'; } } diff --git a/lang/du_nl.php b/lang/du_nl.php index c8b102cbb5..36df2abab9 100644 --- a/lang/du_nl.php +++ b/lang/du_nl.php @@ -1084,6 +1084,6 @@ protected function _LoadLetters() protected function _GetHtmlLangCode() { - return 'du_nl'; + return 'nl-NL'; } } diff --git a/lang/ee_ee.php b/lang/ee_ee.php index c0d2031573..2df0cc2c94 100644 --- a/lang/ee_ee.php +++ b/lang/ee_ee.php @@ -186,7 +186,6 @@ protected function _LoadStrings() $strings['ReservationDescription'] = 'Broneeringu kirjeldus'; $strings['ResourceList'] = 'Broneeritavad väljakud'; $strings['Accessories'] = 'Lisavarustus'; - ; $strings['InvitationList'] = 'Kutsutud inimesed'; $strings['AccessoryName'] = 'Lisavarustuse nimi'; $strings['QuantityAvailable'] = 'Kogus saadaval'; @@ -862,6 +861,6 @@ protected function _LoadLetters() protected function _GetHtmlLangCode() { - return 'ee'; + return 'et'; } } diff --git a/lang/no_no.php b/lang/no_no.php index 4369d0011e..fbba7f4724 100644 --- a/lang/no_no.php +++ b/lang/no_no.php @@ -728,6 +728,6 @@ protected function _LoadLetters() protected function _GetHtmlLangCode() { - return 'no_no'; + return 'nb-NO'; } } diff --git a/lang/si_si.php b/lang/si_si.php index f3ae36e2c6..d3ff6197e0 100644 --- a/lang/si_si.php +++ b/lang/si_si.php @@ -3,7 +3,7 @@ /** Modified by Alenka Kavčič (alenka.kavcic@fri.uni-lj.si), UL FRI, July 2015 Translated and adapted for Slovenian language -*/ + */ require_once('Language.php'); require_once('en_gb.php'); @@ -749,6 +749,6 @@ protected function _LoadLetters() protected function _GetHtmlLangCode() { - return 'si-si'; + return 'sl-SI'; } } diff --git a/lang/tr_tr.php b/lang/tr_tr.php index 00cfe9d836..3efc190332 100644 --- a/lang/tr_tr.php +++ b/lang/tr_tr.php @@ -881,6 +881,6 @@ protected function _LoadLetters() protected function _GetHtmlLangCode() { - return 'en'; + return 'tr'; } } diff --git a/lang/vn_vn.php b/lang/vn_vn.php index 0d9826ccc6..a75e8d0d89 100644 --- a/lang/vn_vn.php +++ b/lang/vn_vn.php @@ -839,6 +839,6 @@ protected function _LoadLetters() protected function _GetHtmlLangCode() { - return 'en'; + return 'vi'; } }