Two issues caused the admin sidebar to show a mix of French and English:
1. Only 3 of 14 modules had "menu" translations in their locale files.
When a key was missing, _translate_label() fell back to English Title
Case from the key name — mixing with French from modules that had
translations. Added menu sections to all 4 languages (en, fr, de, lb)
across 13 modules.
2. The language middleware hardcoded admin to "en" ignoring user preference,
while the menu API fell back to DEFAULT_LANGUAGE ("fr") when
preferred_language was NULL. Fixed middleware to respect user's
preferred_language and menu API to use middleware-resolved language
as fallback.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
42 lines
1.3 KiB
JSON
42 lines
1.3 KiB
JSON
{
|
|
"customers": {
|
|
"title": "Clients",
|
|
"customer": "Client",
|
|
"add_customer": "Ajouter un client",
|
|
"edit_customer": "Modifier le client",
|
|
"customer_name": "Nom du client",
|
|
"customer_email": "E-mail du client",
|
|
"customer_phone": "Téléphone du client",
|
|
"customer_number": "Numéro client",
|
|
"first_name": "Prénom",
|
|
"last_name": "Nom",
|
|
"merchant": "Entreprise",
|
|
"total_orders": "Total des commandes",
|
|
"total_spent": "Total dépensé",
|
|
"last_order": "Dernière commande",
|
|
"registered": "Inscrit",
|
|
"no_customers": "Aucun client trouvé",
|
|
"search_customers": "Rechercher des clients..."
|
|
},
|
|
"features": {
|
|
"customer_view": {
|
|
"name": "Vue client",
|
|
"description": "Voir et gérer les informations clients"
|
|
},
|
|
"customer_export": {
|
|
"name": "Export clients",
|
|
"description": "Exporter les données clients"
|
|
},
|
|
"customer_messaging": {
|
|
"name": "Messagerie clients",
|
|
"description": "Envoyer des messages aux clients"
|
|
}
|
|
},
|
|
"menu": {
|
|
"store_operations": "Opérations du magasin",
|
|
"customers_section": "Clients",
|
|
"customers": "Clients",
|
|
"all_customers": "Tous les clients"
|
|
}
|
|
}
|