diff --git a/loko/assets/locale/en/LC_MESSAGES/djangojs.mo b/loko/assets/locale/en/LC_MESSAGES/djangojs.mo
index 4020d54..8d561b1 100644
Binary files a/loko/assets/locale/en/LC_MESSAGES/djangojs.mo and b/loko/assets/locale/en/LC_MESSAGES/djangojs.mo differ
diff --git a/loko/assets/locale/en/LC_MESSAGES/djangojs.po b/loko/assets/locale/en/LC_MESSAGES/djangojs.po
index 2805ae3..727b478 100644
--- a/loko/assets/locale/en/LC_MESSAGES/djangojs.po
+++ b/loko/assets/locale/en/LC_MESSAGES/djangojs.po
@@ -613,3 +613,107 @@ msgstr "Collapse models"
#: loko/assets/static/assets/unified_index.js:3726
msgid "Bloc replié. Cliquez sur \"Afficher les modèles\" pour voir les options."
msgstr ""
+
+#: loko/assets/static/assets/inspection_map.js:93
+msgid "Rechercher une adresse…"
+msgstr "Search an address…"
+
+msgid "Rechercher une adresse..."
+msgstr "Search an address..."
+
+#: loko/assets/static/assets/inspection_map.js:748
+msgid "Géolocalisation..."
+msgstr "Geolocation..."
+
+#: loko/assets/static/assets/inspection_map.js:769
+msgid "Position actualisée"
+msgstr "Position updated"
+
+#: loko/assets/static/assets/inspection_map.js:773
+msgid "GPS indisponible"
+msgstr "GPS unavailable"
+
+#: loko/assets/static/assets/inspection_map.js:935
+msgid "Inspections (Désactivé)"
+msgstr "Inspections (Disabled)"
+
+#: loko/assets/static/assets/inspection_map.js:936
+msgid "Inspections (1 mois)"
+msgstr "Inspections (1 month)"
+
+#: loko/assets/static/assets/inspection_map.js:937
+msgid "Inspections (3 mois)"
+msgstr "Inspections (3 months)"
+
+#: loko/assets/static/assets/inspection_map.js:938
+msgid "Inspections (6 mois)"
+msgstr "Inspections (6 months)"
+
+#: loko/assets/static/assets/inspection_map.js:939
+msgid "Inspections (1 an)"
+msgstr "Inspections (1 year)"
+
+#: loko/assets/static/assets/inspection_map.js:940
+msgid "Inspections (Tout)"
+msgstr "Inspections (All)"
+
+msgid "Panneau"
+msgstr "Sign"
+
+msgid "Supprimer ce panneau"
+msgstr "Delete this sign"
+
+msgid "Mention (ex: Sauf riverains)"
+msgstr "Mention (e.g. Except local traffic)"
+
+msgid "Propreté :"
+msgstr "Cleanliness:"
+
+msgid "Propre"
+msgstr "Clean"
+
+msgid "Sale"
+msgstr "Dirty"
+
+msgid "Végétation"
+msgstr "Vegetation"
+
+msgid "Dégradé"
+msgstr "Damaged"
+
+msgid "Coordonnées GPS manquantes."
+msgstr "Missing GPS coordinates."
+
+msgid "Veuillez ajouter au moins un panneau."
+msgstr "Please add at least one sign."
+
+msgid "Panneaux créés avec succès !"
+msgstr "Signs created successfully!"
+
+msgid "Erreur : "
+msgstr "Error: "
+
+msgid "Impossible de créer les panneaux."
+msgstr "Unable to create signs."
+
+msgid "Erreur lors de la création : "
+msgstr "Error during creation: "
+
+msgid "Créer et Enregistrer"
+msgstr "Create and Save"
+
+msgid "Inspection enregistrée !"
+msgstr "Inspection saved!"
+
+msgid "Intervention"
+msgstr "Intervention"
+
+msgid "créée."
+msgstr "created."
+
+msgid "Erreur lors de la validation."
+msgstr "Validation error."
+
+msgid "Erreur réseau."
+msgstr "Network error."
+
diff --git a/loko/assets/locale/fr/LC_MESSAGES/djangojs.mo b/loko/assets/locale/fr/LC_MESSAGES/djangojs.mo
index 390f950..03cf3c4 100644
Binary files a/loko/assets/locale/fr/LC_MESSAGES/djangojs.mo and b/loko/assets/locale/fr/LC_MESSAGES/djangojs.mo differ
diff --git a/loko/assets/locale/fr/LC_MESSAGES/djangojs.po b/loko/assets/locale/fr/LC_MESSAGES/djangojs.po
index a939788..807bb46 100644
--- a/loko/assets/locale/fr/LC_MESSAGES/djangojs.po
+++ b/loko/assets/locale/fr/LC_MESSAGES/djangojs.po
@@ -618,3 +618,107 @@ msgstr "Replier les modèles"
#: loko/assets/static/assets/unified_index.js:3726
msgid "Bloc replié. Cliquez sur \"Afficher les modèles\" pour voir les options."
msgstr "Bloc replié. Cliquez sur \"Afficher les modèles\" pour voir les options."
+
+#: loko/assets/static/assets/inspection_map.js:93
+msgid "Rechercher une adresse…"
+msgstr "Rechercher une adresse…"
+
+msgid "Rechercher une adresse..."
+msgstr "Rechercher une adresse..."
+
+#: loko/assets/static/assets/inspection_map.js:748
+msgid "Géolocalisation..."
+msgstr "Géolocalisation..."
+
+#: loko/assets/static/assets/inspection_map.js:769
+msgid "Position actualisée"
+msgstr "Position actualisée"
+
+#: loko/assets/static/assets/inspection_map.js:773
+msgid "GPS indisponible"
+msgstr "GPS indisponible"
+
+#: loko/assets/static/assets/inspection_map.js:935
+msgid "Inspections (Désactivé)"
+msgstr "Inspections (Désactivé)"
+
+#: loko/assets/static/assets/inspection_map.js:936
+msgid "Inspections (1 mois)"
+msgstr "Inspections (1 mois)"
+
+#: loko/assets/static/assets/inspection_map.js:937
+msgid "Inspections (3 mois)"
+msgstr "Inspections (3 mois)"
+
+#: loko/assets/static/assets/inspection_map.js:938
+msgid "Inspections (6 mois)"
+msgstr "Inspections (6 mois)"
+
+#: loko/assets/static/assets/inspection_map.js:939
+msgid "Inspections (1 an)"
+msgstr "Inspections (1 an)"
+
+#: loko/assets/static/assets/inspection_map.js:940
+msgid "Inspections (Tout)"
+msgstr "Inspections (Tout)"
+
+msgid "Panneau"
+msgstr "Panneau"
+
+msgid "Supprimer ce panneau"
+msgstr "Supprimer ce panneau"
+
+msgid "Mention (ex: Sauf riverains)"
+msgstr "Mention (ex: Sauf riverains)"
+
+msgid "Propreté :"
+msgstr "Propreté :"
+
+msgid "Propre"
+msgstr "Propre"
+
+msgid "Sale"
+msgstr "Sale"
+
+msgid "Végétation"
+msgstr "Végétation"
+
+msgid "Dégradé"
+msgstr "Dégradé"
+
+msgid "Coordonnées GPS manquantes."
+msgstr "Coordonnées GPS manquantes."
+
+msgid "Veuillez ajouter au moins un panneau."
+msgstr "Veuillez ajouter au moins un panneau."
+
+msgid "Panneaux créés avec succès !"
+msgstr "Panneaux créés avec succès !"
+
+msgid "Erreur : "
+msgstr "Erreur : "
+
+msgid "Impossible de créer les panneaux."
+msgstr "Impossible de créer les panneaux."
+
+msgid "Erreur lors de la création : "
+msgstr "Erreur lors de la création : "
+
+msgid "Créer et Enregistrer"
+msgstr "Créer et Enregistrer"
+
+msgid "Inspection enregistrée !"
+msgstr "Inspection enregistrée !"
+
+msgid "Intervention"
+msgstr "Intervention"
+
+msgid "créée."
+msgstr "créée."
+
+msgid "Erreur lors de la validation."
+msgstr "Erreur lors de la validation."
+
+msgid "Erreur réseau."
+msgstr "Erreur réseau."
+
diff --git a/loko/assets/locale/nl/LC_MESSAGES/djangojs.mo b/loko/assets/locale/nl/LC_MESSAGES/djangojs.mo
index 89286cb..dc3205d 100644
Binary files a/loko/assets/locale/nl/LC_MESSAGES/djangojs.mo and b/loko/assets/locale/nl/LC_MESSAGES/djangojs.mo differ
diff --git a/loko/assets/locale/nl/LC_MESSAGES/djangojs.po b/loko/assets/locale/nl/LC_MESSAGES/djangojs.po
index 34a8e14..ec79502 100644
--- a/loko/assets/locale/nl/LC_MESSAGES/djangojs.po
+++ b/loko/assets/locale/nl/LC_MESSAGES/djangojs.po
@@ -615,3 +615,107 @@ msgstr "Modellen inklappen"
#: loko/assets/static/assets/unified_index.js:3726
msgid "Bloc replié. Cliquez sur \"Afficher les modèles\" pour voir les options."
msgstr ""
+
+#: loko/assets/static/assets/inspection_map.js:93
+msgid "Rechercher une adresse…"
+msgstr "Zoek een adres…"
+
+msgid "Rechercher une adresse..."
+msgstr "Zoek een adres..."
+
+#: loko/assets/static/assets/inspection_map.js:748
+msgid "Géolocalisation..."
+msgstr "Geolocatie..."
+
+#: loko/assets/static/assets/inspection_map.js:769
+msgid "Position actualisée"
+msgstr "Positie bijgewerkt"
+
+#: loko/assets/static/assets/inspection_map.js:773
+msgid "GPS indisponible"
+msgstr "GPS niet beschikbaar"
+
+#: loko/assets/static/assets/inspection_map.js:935
+msgid "Inspections (Désactivé)"
+msgstr "Inspecties (Uitgeschakeld)"
+
+#: loko/assets/static/assets/inspection_map.js:936
+msgid "Inspections (1 mois)"
+msgstr "Inspecties (1 maand)"
+
+#: loko/assets/static/assets/inspection_map.js:937
+msgid "Inspections (3 mois)"
+msgstr "Inspecties (3 maanden)"
+
+#: loko/assets/static/assets/inspection_map.js:938
+msgid "Inspections (6 mois)"
+msgstr "Inspecties (6 maanden)"
+
+#: loko/assets/static/assets/inspection_map.js:939
+msgid "Inspections (1 an)"
+msgstr "Inspecties (1 jaar)"
+
+#: loko/assets/static/assets/inspection_map.js:940
+msgid "Inspections (Tout)"
+msgstr "Inspecties (Alles)"
+
+msgid "Panneau"
+msgstr "Bord"
+
+msgid "Supprimer ce panneau"
+msgstr "Dit bord verwijderen"
+
+msgid "Mention (ex: Sauf riverains)"
+msgstr "Vermelding (bijv. Uitgezonderd aangelanden)"
+
+msgid "Propreté :"
+msgstr "Netheid:"
+
+msgid "Propre"
+msgstr "Schoon"
+
+msgid "Sale"
+msgstr "Vuil"
+
+msgid "Végétation"
+msgstr "Vegetatie"
+
+msgid "Dégradé"
+msgstr "Beschadigd"
+
+msgid "Coordonnées GPS manquantes."
+msgstr "Ontbrekende gps-coördinaten."
+
+msgid "Veuillez ajouter au moins un panneau."
+msgstr "Voeg minimaal één bord toe."
+
+msgid "Panneaux créés avec succès !"
+msgstr "Borden succesvol aangemaakt!"
+
+msgid "Erreur : "
+msgstr "Fout: "
+
+msgid "Impossible de créer les panneaux."
+msgstr "Kan de borden niet aanmaken."
+
+msgid "Erreur lors de la création : "
+msgstr "Fout bij aanmaken: "
+
+msgid "Créer et Enregistrer"
+msgstr "Aanmaken en opslaan"
+
+msgid "Inspection enregistrée !"
+msgstr "Inspectie opgeslagen!"
+
+msgid "Intervention"
+msgstr "Interventie"
+
+msgid "créée."
+msgstr "aangemaakt."
+
+msgid "Erreur lors de la validation."
+msgstr "Fout bij validatie."
+
+msgid "Erreur réseau."
+msgstr "Netwerkfout."
+
diff --git a/loko/assets/static/assets/inspection_map.js b/loko/assets/static/assets/inspection_map.js
index f0001ac..4dbcdc6 100644
--- a/loko/assets/static/assets/inspection_map.js
+++ b/loko/assets/static/assets/inspection_map.js
@@ -89,9 +89,11 @@
if (typeof AddressSearchControl !== 'undefined') {
const autocompleteUrl = window.AUTOCOMPLETE_STREET_URL || '/common/autocomplete-street/';
+ const i18n = window.INSPECTION_MAP_I18N || {};
+ const placeholder = i18n.searchAddress || (typeof gettext !== 'undefined' ? gettext('Rechercher une adresse…') : 'Rechercher une adresse…');
const searchCtrl = new AddressSearchControl({
autocompleteUrl: autocompleteUrl,
- placeholder: 'Rechercher une adresse...'
+ placeholder: placeholder
});
map.addControl(searchCtrl, 'top-left');
}
@@ -744,8 +746,9 @@
function locateUser() {
if (!navigator.geolocation) return;
+ const i18n = window.INSPECTION_MAP_I18N || {};
const statusText = document.getElementById('gps-status-text');
- if (statusText) statusText.textContent = 'Géolocalisation...';
+ if (statusText) statusText.textContent = i18n.geolocation || (typeof gettext !== 'undefined' ? gettext('Géolocalisation...') : 'Géolocalisation...');
navigator.geolocation.getCurrentPosition(
function(position) {
@@ -766,11 +769,11 @@
map.flyTo({ center: [lng, lat], zoom: 17 });
}
- if (statusText) statusText.textContent = 'Position actualisée';
+ if (statusText) statusText.textContent = i18n.positionUpdated || (typeof gettext !== 'undefined' ? gettext('Position actualisée') : 'Position actualisée');
},
function(err) {
console.warn('GPS error:', err.message);
- if (statusText) statusText.textContent = 'GPS indisponible';
+ if (statusText) statusText.textContent = i18n.gpsUnavailable || (typeof gettext !== 'undefined' ? gettext('GPS indisponible') : 'GPS indisponible');
},
{ enableHighAccuracy: true, timeout: 10000, maximumAge: 5000 }
);
@@ -931,13 +934,17 @@
const STORAGE_HISTORY_PERIOD_KEY = 'loko_insp_history_period';
function getHistoryPeriodLabels() {
+ const i18n = window.INSPECTION_MAP_I18N || {};
+ if (i18n.periodLabels) {
+ return i18n.periodLabels;
+ }
return {
- 'disabled': 'Inspections (Désactivé)',
- '1m': 'Inspections (1 mois)',
- '3m': 'Inspections (3 mois)',
- '6m': 'Inspections (6 mois)',
- '1y': 'Inspections (1 an)',
- 'all': 'Inspections (Tout)'
+ 'disabled': (typeof gettext !== 'undefined' ? gettext('Inspections (Désactivé)') : 'Inspections (Désactivé)'),
+ '1m': (typeof gettext !== 'undefined' ? gettext('Inspections (1 mois)') : 'Inspections (1 mois)'),
+ '3m': (typeof gettext !== 'undefined' ? gettext('Inspections (3 mois)') : 'Inspections (3 mois)'),
+ '6m': (typeof gettext !== 'undefined' ? gettext('Inspections (6 mois)') : 'Inspections (6 mois)'),
+ '1y': (typeof gettext !== 'undefined' ? gettext('Inspections (1 an)') : 'Inspections (1 an)'),
+ 'all': (typeof gettext !== 'undefined' ? gettext('Inspections (Tout)') : 'Inspections (Tout)')
};
}
@@ -959,7 +966,7 @@
}
});
- if (labelEl) labelEl.textContent = labels[period] || 'Inspections (3 mois)';
+ if (labelEl) labelEl.textContent = labels[period] || labels['3m'] || (typeof gettext !== 'undefined' ? gettext('Inspections (3 mois)') : 'Inspections (3 mois)');
if (iconEl) {
if (period === 'disabled') {
iconEl.className = 'bi bi-eye-slash text-muted me-1';
@@ -1980,9 +1987,9 @@
row.innerHTML = `
- #${order} (${labelFr || 'Panneau'})
+ #${order} (${labelFr || (window.gettext ? window.gettext('Panneau') : 'Panneau')})
${confidence ? `` : ''}
-
@@ -1994,23 +2001,23 @@
`;
@@ -2043,13 +2050,13 @@
const lon = document.getElementById('new_sign_lon')?.value;
if (!lat || !lon) {
- alert('Coordonnées GPS manquantes.');
+ alert(window.gettext ? window.gettext('Coordonnées GPS manquantes.') : 'Coordonnées GPS manquantes.');
return;
}
const rows = document.querySelectorAll('.new-sign-panel-row');
if (!rows.length) {
- alert('Veuillez ajouter au moins un panneau.');
+ alert(window.gettext ? window.gettext('Veuillez ajouter au moins un panneau.') : 'Veuillez ajouter au moins un panneau.');
return;
}
@@ -2074,7 +2081,8 @@
newSignPhotos.forEach(p => formData.append('photos', p));
btnSubmit.disabled = true;
- btnSubmit.innerHTML = ' Création en cours...';
+ const creatingMsg = window.gettext ? window.gettext('Création en cours...') : 'Création en cours...';
+ btnSubmit.innerHTML = ` ${creatingMsg}`;
try {
const csrfToken = getCsrfToken();
@@ -2095,7 +2103,7 @@
if (data.success) {
modal.hide();
- alert(data.message || 'Panneaux créés avec succès !');
+ alert(data.message || (window.gettext ? window.gettext('Panneaux créés avec succès !') : 'Panneaux créés avec succès !'));
// Basculer automatiquement sur la thématique Signalisation
localStorage.setItem(STORAGE_THEMATIC_KEY, 'sign');
@@ -2113,13 +2121,17 @@
loadAssets();
loadInspectionsHistory();
} else {
- alert('Erreur : ' + (data.message || 'Impossible de créer les panneaux.'));
+ const errPrefix = window.gettext ? window.gettext('Erreur : ') : 'Erreur : ';
+ const defaultErrMsg = window.gettext ? window.gettext('Impossible de créer les panneaux.') : 'Impossible de créer les panneaux.';
+ alert(errPrefix + (data.message || defaultErrMsg));
}
} catch(err) {
- alert('Erreur lors de la création : ' + err.message);
+ const errCreationMsg = window.gettext ? window.gettext('Erreur lors de la création : ') : 'Erreur lors de la création : ';
+ alert(errCreationMsg + err.message);
} finally {
btnSubmit.disabled = false;
- btnSubmit.innerHTML = ' Créer et Enregistrer';
+ const createAndSaveMsg = window.gettext ? window.gettext('Créer et Enregistrer') : 'Créer et Enregistrer';
+ btnSubmit.innerHTML = ` ${createAndSaveMsg}`;
}
});
}
@@ -2176,19 +2188,22 @@
const modal = bootstrap.Modal.getInstance(modalEl);
if (modal) modal.hide();
- let msg = data.message || 'Inspection enregistrée !';
+ let msg = data.message || (window.gettext ? window.gettext('Inspection enregistrée !') : 'Inspection enregistrée !');
if (data.created_intervention_code) {
- msg += ' Intervention ' + data.created_intervention_code + ' créée.';
+ const intervLabel = window.gettext ? window.gettext('Intervention') : 'Intervention';
+ const createdLabel = window.gettext ? window.gettext('créée.') : 'créée.';
+ msg += ` ${intervLabel} ${data.created_intervention_code} ${createdLabel}`;
}
alert(msg);
loadAssets();
} else {
- alertDiv.textContent = data.error || 'Erreur lors de la validation.';
+ const defaultValError = window.gettext ? window.gettext('Erreur lors de la validation.') : 'Erreur lors de la validation.';
+ alertDiv.textContent = data.error || defaultValError;
alertDiv.classList.remove('d-none');
}
})
.catch(err => {
- alertDiv.textContent = 'Erreur réseau.';
+ alertDiv.textContent = window.gettext ? window.gettext('Erreur réseau.') : 'Erreur réseau.';
alertDiv.classList.remove('d-none');
})
.finally(() => {
diff --git a/loko/common/locale/en/LC_MESSAGES/djangojs.mo b/loko/common/locale/en/LC_MESSAGES/djangojs.mo
index aed1603..0e4a5b2 100644
Binary files a/loko/common/locale/en/LC_MESSAGES/djangojs.mo and b/loko/common/locale/en/LC_MESSAGES/djangojs.mo differ
diff --git a/loko/common/locale/en/LC_MESSAGES/djangojs.po b/loko/common/locale/en/LC_MESSAGES/djangojs.po
index 21b682a..58a779a 100644
--- a/loko/common/locale/en/LC_MESSAGES/djangojs.po
+++ b/loko/common/locale/en/LC_MESSAGES/djangojs.po
@@ -133,3 +133,11 @@ msgstr "@"
#: loko/common/static/common/jquery-ui.min.js:6
msgid "!"
msgstr "!"
+
+#: loko/common/static/common/address_search_control.js:148
+msgid "Rechercher une adresse…"
+msgstr "Search an address…"
+
+msgid "Rechercher une adresse..."
+msgstr "Search an address..."
+
diff --git a/loko/common/locale/fr/LC_MESSAGES/djangojs.mo b/loko/common/locale/fr/LC_MESSAGES/djangojs.mo
index 7eaeef1..467727e 100644
Binary files a/loko/common/locale/fr/LC_MESSAGES/djangojs.mo and b/loko/common/locale/fr/LC_MESSAGES/djangojs.mo differ
diff --git a/loko/common/locale/fr/LC_MESSAGES/djangojs.po b/loko/common/locale/fr/LC_MESSAGES/djangojs.po
index 2387c43..6ce3a1c 100644
--- a/loko/common/locale/fr/LC_MESSAGES/djangojs.po
+++ b/loko/common/locale/fr/LC_MESSAGES/djangojs.po
@@ -133,3 +133,11 @@ msgstr "@"
#: loko/common/static/common/jquery-ui.min.js:6
msgid "!"
msgstr "!"
+
+#: loko/common/static/common/address_search_control.js:148
+msgid "Rechercher une adresse…"
+msgstr "Rechercher une adresse…"
+
+msgid "Rechercher une adresse..."
+msgstr "Rechercher une adresse..."
+
diff --git a/loko/common/locale/nl/LC_MESSAGES/djangojs.mo b/loko/common/locale/nl/LC_MESSAGES/djangojs.mo
index 9defc0e..bc6f175 100644
Binary files a/loko/common/locale/nl/LC_MESSAGES/djangojs.mo and b/loko/common/locale/nl/LC_MESSAGES/djangojs.mo differ
diff --git a/loko/common/locale/nl/LC_MESSAGES/djangojs.po b/loko/common/locale/nl/LC_MESSAGES/djangojs.po
index 2ba1389..5cada44 100644
--- a/loko/common/locale/nl/LC_MESSAGES/djangojs.po
+++ b/loko/common/locale/nl/LC_MESSAGES/djangojs.po
@@ -135,3 +135,11 @@ msgstr "@"
#: loko/common/static/common/jquery-ui.min.js:6
msgid "!"
msgstr "!"
+
+#: loko/common/static/common/address_search_control.js:148
+msgid "Rechercher une adresse…"
+msgstr "Zoek een adres…"
+
+msgid "Rechercher une adresse..."
+msgstr "Zoek een adres..."
+
diff --git a/loko/common/static/common/address_search_control.js b/loko/common/static/common/address_search_control.js
index fba4f82..bf76f4a 100644
--- a/loko/common/static/common/address_search_control.js
+++ b/loko/common/static/common/address_search_control.js
@@ -144,8 +144,9 @@
*/
constructor(opts = {}) {
super();
+ const defaultPlaceholder = (typeof gettext !== 'undefined' ? gettext('Rechercher une adresse…') : 'Rechercher une adresse…');
this._opts = Object.assign({
- placeholder : 'Rechercher une adresse…',
+ placeholder : defaultPlaceholder,
minChars : 2,
debounce : 250,
markerColor : '#0d6efd',
diff --git a/loko/inspections/locale/en/LC_MESSAGES/django.mo b/loko/inspections/locale/en/LC_MESSAGES/django.mo
index 8c770f6..584da1b 100644
Binary files a/loko/inspections/locale/en/LC_MESSAGES/django.mo and b/loko/inspections/locale/en/LC_MESSAGES/django.mo differ
diff --git a/loko/inspections/locale/en/LC_MESSAGES/django.po b/loko/inspections/locale/en/LC_MESSAGES/django.po
index d847cac..9026af3 100644
--- a/loko/inspections/locale/en/LC_MESSAGES/django.po
+++ b/loko/inspections/locale/en/LC_MESSAGES/django.po
@@ -2027,3 +2027,70 @@ msgstr "Team"
#~ msgid "Présence de sédiments dans le bassin d'orage ?"
#~ msgstr "Presence of sediment in stormwater basin?"
+
+#: inspections/templates/inspections/quick_inspection_map.html:505
+msgid "Position actualisée"
+msgstr "Position updated"
+
+#: inspections/templates/inspections/quick_inspection_map.html:506
+msgid "Géolocalisation..."
+msgstr "Geolocation..."
+
+#: inspections/templates/inspections/quick_inspection_map.html:507
+msgid "GPS indisponible"
+msgstr "GPS unavailable"
+
+#: inspections/templates/inspections/quick_inspection_map.html:508
+msgid "Rechercher une adresse…"
+msgstr "Search an address…"
+
+#: inspections/templates/inspections/quick_inspection_map.html:510
+msgid "Inspections (Désactivé)"
+msgstr "Inspections (Disabled)"
+
+#: inspections/templates/inspections/quick_inspection_map.html:511
+msgid "Inspections (1 mois)"
+msgstr "Inspections (1 month)"
+
+#: inspections/templates/inspections/quick_inspection_map.html:513
+msgid "Inspections (6 mois)"
+msgstr "Inspections (6 months)"
+
+#: inspections/templates/inspections/quick_inspection_map.html:514
+msgid "Inspections (1 an)"
+msgstr "Inspections (1 year)"
+
+#: inspections/templates/inspections/quick_inspection_map.html:515
+msgid "Inspections (Tout)"
+msgstr "Inspections (All)"
+
+msgid "Plein écran"
+msgstr "Full screen"
+
+msgid "Photo"
+msgstr "Photo"
+
+msgid "Détail"
+msgstr "Detail"
+
+msgid "Voir l'inspection"
+msgstr "View inspection"
+
+msgid "Équipement"
+msgstr "Equipment"
+
+msgid "inspections"
+msgstr "inspections"
+
+msgid "Aperçu mât"
+msgstr "Pole preview"
+
+msgid "Panneau"
+msgstr "Sign"
+
+msgid "Précédent"
+msgstr "Previous"
+
+msgid "Suivant"
+msgstr "Next"
+
diff --git a/loko/inspections/locale/fr/LC_MESSAGES/django.mo b/loko/inspections/locale/fr/LC_MESSAGES/django.mo
index 9cf3ed3..a670c6c 100644
Binary files a/loko/inspections/locale/fr/LC_MESSAGES/django.mo and b/loko/inspections/locale/fr/LC_MESSAGES/django.mo differ
diff --git a/loko/inspections/locale/fr/LC_MESSAGES/django.po b/loko/inspections/locale/fr/LC_MESSAGES/django.po
index f6df44f..61753f7 100644
--- a/loko/inspections/locale/fr/LC_MESSAGES/django.po
+++ b/loko/inspections/locale/fr/LC_MESSAGES/django.po
@@ -2040,3 +2040,70 @@ msgstr "Équipe"
#~ msgid "Présence de sédiments dans le bassin d'orage ?"
#~ msgstr "Présence de sédiments dans le bassin d'orage ?"
+
+#: inspections/templates/inspections/quick_inspection_map.html:505
+msgid "Position actualisée"
+msgstr "Position actualisée"
+
+#: inspections/templates/inspections/quick_inspection_map.html:506
+msgid "Géolocalisation..."
+msgstr "Géolocalisation..."
+
+#: inspections/templates/inspections/quick_inspection_map.html:507
+msgid "GPS indisponible"
+msgstr "GPS indisponible"
+
+#: inspections/templates/inspections/quick_inspection_map.html:508
+msgid "Rechercher une adresse…"
+msgstr "Rechercher une adresse…"
+
+#: inspections/templates/inspections/quick_inspection_map.html:510
+msgid "Inspections (Désactivé)"
+msgstr "Inspections (Désactivé)"
+
+#: inspections/templates/inspections/quick_inspection_map.html:511
+msgid "Inspections (1 mois)"
+msgstr "Inspections (1 mois)"
+
+#: inspections/templates/inspections/quick_inspection_map.html:513
+msgid "Inspections (6 mois)"
+msgstr "Inspections (6 mois)"
+
+#: inspections/templates/inspections/quick_inspection_map.html:514
+msgid "Inspections (1 an)"
+msgstr "Inspections (1 an)"
+
+#: inspections/templates/inspections/quick_inspection_map.html:515
+msgid "Inspections (Tout)"
+msgstr "Inspections (Tout)"
+
+msgid "Plein écran"
+msgstr "Plein écran"
+
+msgid "Photo"
+msgstr "Photo"
+
+msgid "Détail"
+msgstr "Détail"
+
+msgid "Voir l'inspection"
+msgstr "Voir l'inspection"
+
+msgid "Équipement"
+msgstr "Équipement"
+
+msgid "inspections"
+msgstr "inspections"
+
+msgid "Aperçu mât"
+msgstr "Aperçu mât"
+
+msgid "Panneau"
+msgstr "Panneau"
+
+msgid "Précédent"
+msgstr "Précédent"
+
+msgid "Suivant"
+msgstr "Suivant"
+
diff --git a/loko/inspections/locale/nl/LC_MESSAGES/django.mo b/loko/inspections/locale/nl/LC_MESSAGES/django.mo
index 09e44b3..55c3074 100644
Binary files a/loko/inspections/locale/nl/LC_MESSAGES/django.mo and b/loko/inspections/locale/nl/LC_MESSAGES/django.mo differ
diff --git a/loko/inspections/locale/nl/LC_MESSAGES/django.po b/loko/inspections/locale/nl/LC_MESSAGES/django.po
index 58ccec2..c92e198 100644
--- a/loko/inspections/locale/nl/LC_MESSAGES/django.po
+++ b/loko/inspections/locale/nl/LC_MESSAGES/django.po
@@ -2028,3 +2028,70 @@ msgstr "Team"
#~ msgid "Présence de sédiments dans le bassin d'orage ?"
#~ msgstr "Aanwezigheid van sediment in het stormbekken?"
+
+#: inspections/templates/inspections/quick_inspection_map.html:505
+msgid "Position actualisée"
+msgstr "Positie bijgewerkt"
+
+#: inspections/templates/inspections/quick_inspection_map.html:506
+msgid "Géolocalisation..."
+msgstr "Geolocatie..."
+
+#: inspections/templates/inspections/quick_inspection_map.html:507
+msgid "GPS indisponible"
+msgstr "GPS niet beschikbaar"
+
+#: inspections/templates/inspections/quick_inspection_map.html:508
+msgid "Rechercher une adresse…"
+msgstr "Zoek een adres…"
+
+#: inspections/templates/inspections/quick_inspection_map.html:510
+msgid "Inspections (Désactivé)"
+msgstr "Inspecties (Uitgeschakeld)"
+
+#: inspections/templates/inspections/quick_inspection_map.html:511
+msgid "Inspections (1 mois)"
+msgstr "Inspecties (1 maand)"
+
+#: inspections/templates/inspections/quick_inspection_map.html:513
+msgid "Inspections (6 mois)"
+msgstr "Inspecties (6 maanden)"
+
+#: inspections/templates/inspections/quick_inspection_map.html:514
+msgid "Inspections (1 an)"
+msgstr "Inspecties (1 jaar)"
+
+#: inspections/templates/inspections/quick_inspection_map.html:515
+msgid "Inspections (Tout)"
+msgstr "Inspecties (Alles)"
+
+msgid "Plein écran"
+msgstr "Volledig scherm"
+
+msgid "Photo"
+msgstr "Foto"
+
+msgid "Détail"
+msgstr "Detail"
+
+msgid "Voir l'inspection"
+msgstr "Inspectie bekijken"
+
+msgid "Équipement"
+msgstr "Uitrusting"
+
+msgid "inspections"
+msgstr "inspecties"
+
+msgid "Aperçu mât"
+msgstr "Overzicht paal"
+
+msgid "Panneau"
+msgstr "Bord"
+
+msgid "Précédent"
+msgstr "Vorige"
+
+msgid "Suivant"
+msgstr "Volgende"
+
diff --git a/loko/inspections/templates/inspections/components/asset_details/_signpanel.html b/loko/inspections/templates/inspections/components/asset_details/_signpanel.html
index 15fb638..c6d06ac 100644
--- a/loko/inspections/templates/inspections/components/asset_details/_signpanel.html
+++ b/loko/inspections/templates/inspections/components/asset_details/_signpanel.html
@@ -11,7 +11,7 @@
diff --git a/loko/inspections/templates/inspections/components/asset_fields/_signpanel.html b/loko/inspections/templates/inspections/components/asset_fields/_signpanel.html
index 5d230e4..578d106 100644
--- a/loko/inspections/templates/inspections/components/asset_fields/_signpanel.html
+++ b/loko/inspections/templates/inspections/components/asset_fields/_signpanel.html
@@ -8,7 +8,7 @@
{% translate "Contrôle de signalisation routière" %}
- {% if asset.code %}{{ asset.code }}{% elif asset.signpanel_type %}{{ asset.signpanel_type.code }}{% else %}Panneau{% endif %}
+ {% if asset.code %}{{ asset.code }}{% elif asset.signpanel_type %}{{ asset.signpanel_type.code }}{% else %}{% translate "Panneau" %}{% endif %}
@@ -151,7 +151,7 @@
diff --git a/loko/inspections/templates/inspections/components/quick_add_sign_modal.html b/loko/inspections/templates/inspections/components/quick_add_sign_modal.html
index 03be8f2..49f96fa 100644
--- a/loko/inspections/templates/inspections/components/quick_add_sign_modal.html
+++ b/loko/inspections/templates/inspections/components/quick_add_sign_modal.html
@@ -81,7 +81,7 @@
-
![Aperçu mât]()
+
diff --git a/loko/inspections/templates/inspections/inspections_list.html b/loko/inspections/templates/inspections/inspections_list.html
index c03a5fa..2dfe936 100644
--- a/loko/inspections/templates/inspections/inspections_list.html
+++ b/loko/inspections/templates/inspections/inspections_list.html
@@ -179,7 +179,7 @@
{% translate "Détail de l'inspection" %}
-
+
{% if insp.is_cancelled %}
@@ -299,7 +299,7 @@

-
+
@@ -309,11 +309,11 @@
- Précédent
+ {% translate "Précédent" %}
- Suivant
+ {% translate "Suivant" %}
@@ -368,7 +368,7 @@
-
+
@@ -376,11 +376,11 @@
- Précédent
+ {% translate "Précédent" %}
- Suivant
+ {% translate "Suivant" %}
@@ -401,7 +401,7 @@ document.addEventListener('DOMContentLoaded', function() {
imgs.forEach(img => {
imagesData.push({
url: img.getAttribute('src'),
- filename: img.getAttribute('alt') || 'Photo'
+ filename: img.getAttribute('alt') || '{% translate "Photo" %}'
});
});
@@ -434,7 +434,7 @@ document.addEventListener('DOMContentLoaded', function() {
ind.className = 'active';
ind.setAttribute('aria-current', 'true');
}
- ind.setAttribute('aria-label', `Photo ${idx + 1}`);
+ ind.setAttribute('aria-label', `{% translate "Photo" %} ${idx + 1}`);
fsIndicators.appendChild(ind);
}
});
@@ -481,7 +481,7 @@ document.addEventListener('DOMContentLoaded', function() {
{% translate "Carte des résultats d'inspections" %}
-
+
@@ -641,7 +641,7 @@ document.addEventListener('DOMContentLoaded', function() {
${insp.inspector}
${insp.summary}
- Détail
+ {% translate "Détail" %}
`;
@@ -659,8 +659,8 @@ document.addEventListener('DOMContentLoaded', function() {
${insp.inspector}
-
- Détail
+
+ {% translate "Détail" %}
`;
@@ -669,8 +669,8 @@ document.addEventListener('DOMContentLoaded', function() {
contentHtml = `
-
${popupTitle || 'Équipement'}
- ${sortedInspections.length} inspections
+ ${popupTitle || '{% translate "Équipement" %}'}
+ ${sortedInspections.length} {% translate "inspections" %}
${rowsHtml}
diff --git a/loko/inspections/templates/inspections/inspections_list_mobile.html b/loko/inspections/templates/inspections/inspections_list_mobile.html
index 8cff4be..7a7eff5 100644
--- a/loko/inspections/templates/inspections/inspections_list_mobile.html
+++ b/loko/inspections/templates/inspections/inspections_list_mobile.html
@@ -90,7 +90,7 @@
@@ -242,7 +242,7 @@
{% translate "Détail de l'inspection" %}
-
+
{% if insp.is_cancelled %}
@@ -385,7 +385,7 @@

-
+
@@ -395,11 +395,11 @@
- Précédent
+ {% translate "Précédent" %}
- Suivant
+ {% translate "Suivant" %}
@@ -461,7 +461,7 @@
-
+
@@ -469,11 +469,11 @@
- Précédent
+ {% translate "Précédent" %}
- Suivant
+ {% translate "Suivant" %}
@@ -494,7 +494,7 @@ document.addEventListener('DOMContentLoaded', function() {
imgs.forEach(img => {
imagesData.push({
url: img.getAttribute('src'),
- filename: img.getAttribute('alt') || 'Photo'
+ filename: img.getAttribute('alt') || '{% translate "Photo" %}'
});
});
@@ -527,7 +527,7 @@ document.addEventListener('DOMContentLoaded', function() {
ind.className = 'active';
ind.setAttribute('aria-current', 'true');
}
- ind.setAttribute('aria-label', `Photo ${idx + 1}`);
+ ind.setAttribute('aria-label', `{% translate "Photo" %} ${idx + 1}`);
fsIndicators.appendChild(ind);
}
});
@@ -564,7 +564,7 @@ document.addEventListener('DOMContentLoaded', function() {
{% translate "Carte des résultats d'inspections" %}
-
+
@@ -724,7 +724,7 @@ document.addEventListener('DOMContentLoaded', function() {
${insp.inspector}
${insp.summary}
- Détail
+ {% translate "Détail" %}
`;
@@ -742,8 +742,8 @@ document.addEventListener('DOMContentLoaded', function() {
${insp.inspector}
-
- Détail
+
+ {% translate "Détail" %}
`;
@@ -752,8 +752,8 @@ document.addEventListener('DOMContentLoaded', function() {
contentHtml = `
-
${popupTitle || 'Équipement'}
- ${sortedInspections.length} inspections
+ ${popupTitle || '{% translate "Équipement" %}'}
+ ${sortedInspections.length} {% translate "inspections" %}
${rowsHtml}
diff --git a/loko/inspections/templates/inspections/quick_inspection_map.html b/loko/inspections/templates/inspections/quick_inspection_map.html
index 7e58360..d065987 100644
--- a/loko/inspections/templates/inspections/quick_inspection_map.html
+++ b/loko/inspections/templates/inspections/quick_inspection_map.html
@@ -227,7 +227,7 @@
{% translate "Veuillez zoomer sur la carte pour afficher les équipements." %}
-
+
@@ -277,7 +277,7 @@
{% translate "Choisir une thématique" %}
-
+
@@ -309,7 +309,7 @@
{% translate "Filtrer par catégorie" %}
-
+
@@ -337,7 +337,7 @@
{% translate "Historique des inspections sur la carte" %}
-
+
@@ -386,7 +386,7 @@
{% translate "Modifier" %}
-
+
@@ -437,11 +437,11 @@
- Précédent
+ {% translate "Précédent" %}
- Suivant
+ {% translate "Suivant" %}
@@ -461,7 +461,7 @@
-
+
@@ -469,11 +469,11 @@
- Précédent
+ {% translate "Précédent" %}
- Suivant
+ {% translate "Suivant" %}
@@ -501,6 +501,20 @@
window.PRESELECT_LAT = {{ preselect_lat|safe }};
window.PRESELECT_THEMATIC_CODE = {{ preselect_thematic_code|safe }};
window.PRESELECT_CATEGORY_ID = {{ preselect_category_id|safe }};
+ window.INSPECTION_MAP_I18N = {
+ positionUpdated: "{% translate 'Position actualisée' %}",
+ geolocation: "{% translate 'Géolocalisation...' %}",
+ gpsUnavailable: "{% translate 'GPS indisponible' %}",
+ searchAddress: "{% translate 'Rechercher une adresse…' %}",
+ periodLabels: {
+ 'disabled': "{% translate 'Inspections (Désactivé)' %}",
+ '1m': "{% translate 'Inspections (1 mois)' %}",
+ '3m': "{% translate 'Inspections (3 mois)' %}",
+ '6m': "{% translate 'Inspections (6 mois)' %}",
+ '1y': "{% translate 'Inspections (1 an)' %}",
+ 'all': "{% translate 'Inspections (Tout)' %}"
+ }
+ };
{% endblock %}