Files
orion/app/modules/orders/locales/en.json
Samir Boulahtit dad02695f6 fix(i18n): add missing menu translations and fix admin language resolution
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>
2026-02-07 23:37:13 +01:00

84 lines
3.0 KiB
JSON

{
"orders": {
"title": "Orders",
"order": "Order",
"order_id": "Order ID",
"order_number": "Order Number",
"order_date": "Order Date",
"order_status": "Order Status",
"order_details": "Order Details",
"order_items": "Order Items",
"order_total": "Order Total",
"subtotal": "Subtotal",
"shipping": "Shipping",
"tax": "Tax",
"discount": "Discount",
"customer": "Customer",
"shipping_address": "Shipping Address",
"billing_address": "Billing Address",
"payment_method": "Payment Method",
"payment_status": "Payment Status",
"tracking": "Tracking",
"tracking_number": "Tracking Number",
"carrier": "Carrier",
"no_orders": "No orders found",
"search_orders": "Search orders...",
"filter_by_status": "Filter by status",
"status_pending": "Pending",
"status_processing": "Processing",
"status_shipped": "Shipped",
"status_delivered": "Delivered",
"status_cancelled": "Cancelled",
"status_refunded": "Refunded",
"status_confirmed": "Confirmed",
"status_rejected": "Rejected",
"confirm_order": "Confirm Order",
"reject_order": "Reject Order",
"set_tracking": "Set Tracking",
"view_details": "View Details"
},
"messages": {
"order_status_updated": "Order status updated",
"item_shipped_successfully": "Item shipped successfully",
"all_items_shipped": "All items shipped",
"invoice_downloaded": "Invoice downloaded",
"failed_to_load_order_details": "Failed to load order details.",
"order_status_updated_successfully": "Order status updated successfully.",
"order_marked_as_shipped_successfully": "Order marked as shipped successfully.",
"no_shipping_label_url_available_for_this": "No shipping label URL available for this order."
},
"features": {
"orders_per_month": {
"name": "Monthly Orders",
"description": "Maximum orders per month",
"unit": "orders/month"
},
"order_history_months": {
"name": "Order History",
"description": "Months of order history retained",
"unit": "months"
},
"order_management": {
"name": "Order Management",
"description": "Full order management capabilities"
},
"order_bulk_actions": {
"name": "Bulk Actions",
"description": "Perform bulk actions on orders"
},
"order_export": {
"name": "Order Export",
"description": "Export order data"
},
"automation_rules": {
"name": "Automation Rules",
"description": "Automated order processing rules"
}
},
"menu": {
"store_operations": "Store Operations",
"sales_orders": "Sales & Orders",
"orders": "Orders"
}
}