Add gettext
This commit is contained in:
parent
c881a51c12
commit
ad5ae4ceb0
@ -173,6 +173,7 @@ $js_messages['strDividedBy'] = __('Divided by %s:');
|
||||
$js_messages['strFromSlowLog'] = __('From slow log');
|
||||
$js_messages['strFromGeneralLog'] = __('From general log');
|
||||
$js_messages['strAnalysingLogs'] = __('Analysing & loading logs. This may take a while.');
|
||||
$js_messages['strCancelRequest'] = __('Cancel request');
|
||||
$js_messages['strCountColumnExplanation'] = __('This column shows the amount of identical queries that are grouped together. However only the SQL query itself has been used as a grouping criteria, so the other attributes of queries, such as start time, may differ.');
|
||||
$js_messages['strMoreCountColumnExplanation'] = __('Since grouping of INSERTs queries has been selected, INSERT queries into the same table are also being grouped together, disregarding of the inserted data.');
|
||||
$js_messages['strLogDataLoaded'] = __('Log data loaded. Queries executed in this time span:');
|
||||
@ -180,6 +181,15 @@ $js_messages['strLogDataLoaded'] = __('Log data loaded. Queries executed in this
|
||||
$js_messages['strJumpToTable'] = __('Jump to Log table');
|
||||
$js_messages['strNoDataFound'] = __('Log analysed, but no data found in this time span.');
|
||||
|
||||
$js_messages['strAnalyzing'] = __('Analyzing...');
|
||||
$js_messages['strExplainOutput'] = __('Explain output');
|
||||
$js_messages['strStatus'] = __('Status');
|
||||
$js_messages['strTime'] = __('Time');
|
||||
$js_messages['strTotalTime'] = __('Total time:');
|
||||
$js_messages['strProfilingResults'] = __('Profiling results');
|
||||
$js_messages['strTable'] = _pgettext('Display format', 'Table');
|
||||
$js_messages['strChart'] = __('Chart');
|
||||
|
||||
/* l10n: A collection of available filters */
|
||||
$js_messages['strFiltersForLogTable'] = __('Log table filter options');
|
||||
/* l10n: Filter as in "Start Filtering" */
|
||||
|
||||
@ -1339,19 +1339,20 @@ $(function() {
|
||||
$('#emptyDialog').html(PMA_messages['strAnalysingLogs'] +
|
||||
' <img class="ajaxIcon" src="' + pmaThemeImage +
|
||||
'ajax_clock_small.gif" alt="">');
|
||||
var dlgBtns = {};
|
||||
|
||||
dlgBtns[PMA_messages['strCancelRequest']] = function() {
|
||||
if (logRequest != null) {
|
||||
logRequest.abort();
|
||||
}
|
||||
|
||||
$(this).dialog("close");
|
||||
}
|
||||
|
||||
$('#emptyDialog').dialog({
|
||||
width: 'auto',
|
||||
height: 'auto',
|
||||
buttons: {
|
||||
'Cancel request': function() {
|
||||
if (logRequest != null) {
|
||||
logRequest.abort();
|
||||
}
|
||||
|
||||
$(this).dialog("close");
|
||||
}
|
||||
}
|
||||
buttons: dlgBtns
|
||||
});
|
||||
|
||||
|
||||
@ -1731,7 +1732,7 @@ $(function() {
|
||||
var db = rowData.db || '';
|
||||
|
||||
$('div#queryAnalyzerDialog div.placeHolder').html(
|
||||
'Analyzing... ' + '<img class="ajaxIcon" src="' +
|
||||
PMA_messages['strAnalyzing'] + ' <img class="ajaxIcon" src="' +
|
||||
pmaThemeImage + 'ajax_clock_small.gif" alt="">');
|
||||
|
||||
$.post('server_status.php?' + url_query, {
|
||||
@ -1752,7 +1753,7 @@ $(function() {
|
||||
$('div#queryAnalyzerDialog div.placeHolder')
|
||||
.html('<table width="100%" border="0"><tr><td class="explain"></td><td class="chart"></td></tr></table>');
|
||||
|
||||
var explain = '<b>Explain output</b> ' + explain_docu;
|
||||
var explain = '<b>' + PMA_messages['strExplainOutput'] + '</b> ' + explain_docu;
|
||||
if (data.explain.length > 1) {
|
||||
explain += ' (';
|
||||
for (var i = 0; i < data.explain.length; i++) {
|
||||
@ -1792,7 +1793,7 @@ $(function() {
|
||||
|
||||
if (data.profiling) {
|
||||
var chartData = [];
|
||||
var numberTable = '<table class="queryNums"><thead><tr><th>Status</th><th>Time</th></tr></thead><tbody>';
|
||||
var numberTable = '<table class="queryNums"><thead><tr><th>' + PMA_messages['strStatus'] + '</th><th>' + PMA_messages['strTime'] + '</th></tr></thead><tbody>';
|
||||
var duration;
|
||||
|
||||
for (var i = 0; i < data.profiling.length; i++) {
|
||||
@ -1803,10 +1804,13 @@ $(function() {
|
||||
|
||||
numberTable += '<tr><td>' + data.profiling[i].state + ' </td><td> ' + PMA_prettyProfilingNum(duration, 2) + '</td></tr>';
|
||||
}
|
||||
numberTable += '<tr><td><b>Total time:</b></td><td>' + PMA_prettyProfilingNum(totalTime, 2) + '</td></tr>';
|
||||
numberTable += '<tr><td><b>' + PMA_messages['strTotalTime'] + '</b></td><td>' + PMA_prettyProfilingNum(totalTime, 2) + '</td></tr>';
|
||||
numberTable += '</tbody></table>';
|
||||
|
||||
$('div#queryAnalyzerDialog div.placeHolder td.chart').append('<b>Profiling results ' + profiling_docu + '</b> (<a href="#showNums">Table</a>, <a href="#showChart">Chart</a>)<br/>' + numberTable + ' <div id="queryProfiling"></div>');
|
||||
$('div#queryAnalyzerDialog div.placeHolder td.chart').append(
|
||||
'<b>' + PMA_messages['strProfilingResults'] + ' ' + profiling_docu + '</b> ' +
|
||||
'(<a href="#showNums">' + PMA_messages['strTable'] + '</a>, <a href="#showChart">' + PMA_messages['strChart'] + '</a>)<br/>' +
|
||||
numberTable + ' <div id="queryProfiling"></div>');
|
||||
|
||||
$('div#queryAnalyzerDialog div.placeHolder a[href="#showNums"]').click(function() {
|
||||
$('div#queryAnalyzerDialog div#queryProfiling').hide();
|
||||
|
||||
@ -323,16 +323,16 @@ function PMA_bytime($num, $precision)
|
||||
{
|
||||
$per = '';
|
||||
if ($num >= 1) { // per second
|
||||
$per = "per second";
|
||||
$per = __('per second');
|
||||
} elseif ($num*60 >= 1) { // per minute
|
||||
$num = $num*60;
|
||||
$per = "per minute";
|
||||
$per = __('per minute');
|
||||
} elseif ($num*60*60 >=1 ) { // per hour
|
||||
$num = $num*60*60;
|
||||
$per = "per hour";
|
||||
$per = __('per hour');
|
||||
} else {
|
||||
$num = $num*60*60*24;
|
||||
$per = "per day";
|
||||
$per = __('per day');
|
||||
}
|
||||
|
||||
$num = round($num, $precision);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user