mirror of
https://github.com/YunoHost/yunohost-admin.git
synced 2024-09-03 20:06:15 +02:00
[enh] Translate services status and loading state.
This commit is contained in:
parent
353eb156f9
commit
52eb6201fe
4 changed files with 22 additions and 10 deletions
13
src/dist/js/script.min.js
vendored
13
src/dist/js/script.min.js
vendored
File diff suppressed because one or more lines are too long
|
@ -1444,8 +1444,12 @@ var app = Sammy('#main', function (sam) {
|
|||
data2 = { 'services': [] };
|
||||
$.each(data, function(k, v) {
|
||||
v.name = k;
|
||||
// Handlebars want booleans
|
||||
v.is_loaded = (v.loaded=='enabled') ? true : false;
|
||||
v.is_running = (v.status=='running') ? true : false;
|
||||
// Translate status and loaded state
|
||||
v.status = y18n.t(v.status);
|
||||
v.loaded = y18n.t(v.loaded);
|
||||
data2.services.push(v);
|
||||
});
|
||||
c.view('service/service_list', data2);
|
||||
|
@ -1457,9 +1461,12 @@ var app = Sammy('#main', function (sam) {
|
|||
c.api('/services/'+ c.params['service'], function(data) { // ?
|
||||
data2 = { 'service': data };
|
||||
data2.service.name = c.params['service'];
|
||||
// Handlebars want booleans
|
||||
data2.service.is_loaded = (data.loaded=='enabled') ? true : false;
|
||||
data2.service.is_running = (data.status=='running') ? true : false;
|
||||
|
||||
// Translate status and loaded state
|
||||
data2.service.status = y18n.t(data.status);
|
||||
data2.service.loaded = y18n.t(data.loaded);
|
||||
store.clear('slide');
|
||||
c.view('service/service_info', data2);
|
||||
}, 'GET');
|
||||
|
|
|
@ -27,6 +27,8 @@
|
|||
"status" : "Status",
|
||||
"disable" : "Disable",
|
||||
"enable" : "Enable",
|
||||
"disabled" : "Disabled",
|
||||
"enabled" : "Enabled",
|
||||
"start" : "Start",
|
||||
"stop" : "Stop",
|
||||
"log" : "Log",
|
||||
|
@ -156,7 +158,7 @@
|
|||
"count_min" : "%s min",
|
||||
"process" : "Process",
|
||||
"running" : "Running",
|
||||
"sleeping" : "Sleeping",
|
||||
"inactive" : "Inactive",
|
||||
"network" : "Network",
|
||||
"public_ip" : "Public IP: ",
|
||||
"local_ip" : "Local IP",
|
||||
|
|
|
@ -27,6 +27,8 @@
|
|||
"status": "Statut",
|
||||
"disable": "Désactiver",
|
||||
"enable": "Activer",
|
||||
"disabled": "Désactivé",
|
||||
"enabled": "Activé",
|
||||
"start": "Démarrer",
|
||||
"stop": "Arrêter",
|
||||
"log": "Journal",
|
||||
|
@ -147,8 +149,8 @@
|
|||
"cpu_load": "Charge CPU",
|
||||
"count_min": "%s min",
|
||||
"process": "Process",
|
||||
"running": "Running",
|
||||
"sleeping": "Sleeping",
|
||||
"running": "En cours d'execution",
|
||||
"inactive": "Inactif",
|
||||
"network": "Réseau",
|
||||
"public_ip": "IP publique : ",
|
||||
"local_ip": "IP locale",
|
||||
|
|
Loading…
Reference in a new issue