mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-07-21 09:03:38 +02:00
stats: l10n everything and use existing keys as much as possible
This commit is contained in:
+5
-1
@@ -381,6 +381,8 @@ if (count(get_last(60, 'year')) > 1 )
|
||||
);
|
||||
}
|
||||
|
||||
ksort($lang['month']);
|
||||
|
||||
$template->assign(array(
|
||||
'compareYears' => get_month_of_last_years($conf['stat_compare_year_displayed']),
|
||||
'monthStats' => get_month_stats(),
|
||||
@@ -388,7 +390,9 @@ $template->assign(array(
|
||||
'lastDays' => $last_days,
|
||||
'lastMonths' => $last_months,
|
||||
'lastYears' => $last_years,
|
||||
'langCode' => strval($user['language'])
|
||||
'langCode' => strval($user['language']),
|
||||
'month_labels' => join('~', $lang['month']),
|
||||
'ADMIN_PAGE_TITLE' => l10n('History'),
|
||||
));
|
||||
|
||||
$template->assign_var_from_handle('ADMIN_CONTENT', 'stats');
|
||||
|
||||
@@ -116,7 +116,7 @@ function changeData(dataType, options = displayOptions) {
|
||||
yAxes: [{
|
||||
scaleLabel: {
|
||||
display: true,
|
||||
labelString: 'Page visited'
|
||||
labelString: str_number_page_visited
|
||||
},
|
||||
tick: {
|
||||
min: 0
|
||||
@@ -142,7 +142,7 @@ function changeData(dataType, options = displayOptions) {
|
||||
yAxes: [{
|
||||
scaleLabel: {
|
||||
display: true,
|
||||
labelString: 'Page visited'
|
||||
labelString: str_number_page_visited
|
||||
}
|
||||
}]
|
||||
}
|
||||
|
||||
@@ -11,8 +11,9 @@ var str_unit_format = {
|
||||
"day":"dddd",
|
||||
"month":"MMM YYYY"
|
||||
}
|
||||
var str_avg = "{'Average last 12 months'|@translate}"
|
||||
var str_months = ["{'January'|@translate}", "{'February'|@translate}", "{'March'|@translate}", "{'April'|@translate}", "{'May'|@translate}", "{'June'|@translate}", "{'July'|@translate}", "{'August'|@translate}", "{'September'|@translate}", "{'Octobember'|@translate}", "{'November'|@translate}", "{'December'|@translate}"];
|
||||
var str_avg = "{'Average last 12 months'|@translate}";
|
||||
var str_months_tosplit = "{$month_labels}";
|
||||
var str_months = str_months_tosplit.split('~');
|
||||
moment.locale("{$langCode}");
|
||||
{/footer_script}
|
||||
|
||||
@@ -23,10 +24,6 @@ moment.locale("{$langCode}");
|
||||
|
||||
{combine_script id='stats' load='footer' path='admin/themes/default/js/stats.js'}
|
||||
|
||||
<div class="titrePage">
|
||||
<h2>{'History'|@translate}</h2>
|
||||
</div>
|
||||
|
||||
<div class="stat-compare-mode">
|
||||
<label class="switch">
|
||||
<input type="checkbox" id="toggleCompareMode">
|
||||
|
||||
Reference in New Issue
Block a user