From d478c848e69fe004bc95b4e24de7d32df6ab2a69 Mon Sep 17 00:00:00 2001 From: Christian Beeznest Date: Mon, 3 Feb 2025 20:31:49 -0500 Subject: [PATCH] Internal: Fix language terms and translations --- public/main/inc/ajax/statistics.ajax.php | 10 +++++----- public/main/my_space/myStudents.php | 2 +- .../default/tracking/tracking_course_log.html.twig | 4 ++-- public/main/tracking/exams.php | 4 ++-- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/public/main/inc/ajax/statistics.ajax.php b/public/main/inc/ajax/statistics.ajax.php index 7504b8dbdf..7bfa5666f1 100644 --- a/public/main/inc/ajax/statistics.ajax.php +++ b/public/main/inc/ajax/statistics.ajax.php @@ -205,7 +205,7 @@ switch ($action) { } elseif ('courses' == $action) { $courseCategoryRepo = Container::getCourseCategoryRepository(); $categories = $courseCategoryRepo->findAll(); - $statsName = 'CountCours'; + $statsName = 'Total number of courses'; // total amount of courses $all = []; foreach ($categories as $category) { @@ -213,7 +213,7 @@ switch ($action) { $all[$category->getTitle()] = $category->getCourses()->count(); } } elseif ('courses_by_language' == $action) { - $statsName = 'CountCourseByLanguage'; + $statsName = 'Count course by language'; $all = Statistics::printCourseByLanguageStats(); // use slightly different colors than previous chart for ($k = 0; $k < 3; $k++) { @@ -221,7 +221,7 @@ switch ($action) { array_push($palette, $item); } } elseif ('users' == $action) { - $statsName = 'NumberOfUsers'; + $statsName = 'Number of users'; $countInvisible = isset($_GET['count_invisible']) ? (int) $_GET['count_invisible'] : null; $all = [ get_lang('Trainers') => Statistics::countUsers(COURSEMANAGER, null, $countInvisible), @@ -286,7 +286,7 @@ switch ($action) { $list = []; $palette = ChamiloApi::getColorPalette(true, true); - $statsName = 'NumberOfUsers'; + $statsName = 'Number of users'; $filter = $_REQUEST['filter']; $startDate = $_REQUEST['date_start']; @@ -617,7 +617,7 @@ switch ($action) { $list = []; $palette = ChamiloApi::getColorPalette(true, true); - $statsName = 'NumberOfUsers'; + $statsName = 'Number of users'; $filter = $_REQUEST['filter']; $startDate = Database::escape_string($_REQUEST['date_start']); diff --git a/public/main/my_space/myStudents.php b/public/main/my_space/myStudents.php index 69fca2ae0e..d20d5f766d 100644 --- a/public/main/my_space/myStudents.php +++ b/public/main/my_space/myStudents.php @@ -2032,7 +2032,7 @@ if (empty($details)) { $i++; } } else { - echo ''.get_lang('NoTest').''; + echo ''.get_lang('There is no test for the moment').''; } echo ''; } diff --git a/public/main/template/default/tracking/tracking_course_log.html.twig b/public/main/template/default/tracking/tracking_course_log.html.twig index fcff776589..36f5a7c775 100644 --- a/public/main/template/default/tracking/tracking_course_log.html.twig +++ b/public/main/template/default/tracking/tracking_course_log.html.twig @@ -58,7 +58,7 @@ $(() => { data: { labels: ["0-9%", "10-19%", "20-29%", "30-39%", "40-49%", "50-59%", "60-69%", "70-79%", "80-89%", "90-100%"], datasets: [{ - label: '{{ "NumberOfUsers"|get_lang|e('js') }}', + label: '{{ "Number of users"|get_lang|e('js') }}', data: {{ score_distribution|raw }}, backgroundColor: {{ chart_colors|raw }}, borderColor: {{ chart_colors|raw }}, @@ -74,7 +74,7 @@ $(() => { y: { position: "left", title: { - text: '{{ "NumberOfUsers"|get_lang|e('js') }}', + text: '{{ "Number of users"|get_lang|e('js') }}', display: true }, ticks: { diff --git a/public/main/tracking/exams.php b/public/main/tracking/exams.php index 9b14c53293..b279d33d5e 100644 --- a/public/main/tracking/exams.php +++ b/public/main/tracking/exams.php @@ -376,7 +376,7 @@ if (!empty($courseList)) { } else { $html .= " - ".get_lang('NoTest')." + ".get_lang('There is no test for the moment')." "; @@ -384,7 +384,7 @@ if (!empty($courseList)) { } else { $html .= " - ".get_lang('NoTest')." + ".get_lang('There is no test for the moment')." ";