From 6bc37150459c779b46ded736a69637188fa95dd7 Mon Sep 17 00:00:00 2001 From: Stanislav Levin Date: Tue, 26 Jun 2018 18:06:21 +0300 Subject: [PATCH] Fix translations at load_page plugin To be translatable text field should be marked with @i18n. Also these messages should be provided by i18n_messages. Fixes: https://pagure.io/freeipa/issue/7559 Reviewed-By: Alexander Bokovoy Reviewed-By: Christian Heimes Reviewed-By: Petr Vobornik --- install/ui/src/freeipa/plugins/load_page.js | 10 +++++----- ipaserver/plugins/internal.py | 1 + 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/install/ui/src/freeipa/plugins/load_page.js b/install/ui/src/freeipa/plugins/load_page.js index 7d8a466bb..eaa10dbeb 100644 --- a/install/ui/src/freeipa/plugins/load_page.js +++ b/install/ui/src/freeipa/plugins/load_page.js @@ -24,10 +24,10 @@ define([ 'dojo/on', '../facets/Facet', '../phases', - '../reg' - + '../reg', + '../text' ], - function(declare, lang, on, Facet, phases, reg) { + function(declare, lang, on, Facet, phases, reg, text) { /** * Load Facet plugin @@ -46,7 +46,7 @@ define([ { $type: 'activity', name: 'activity', - text: 'Loading', + text: text.get('@i18n:login.loading', 'Loading'), visible: true } ] @@ -64,4 +64,4 @@ define([ }); return load; -}); \ No newline at end of file +}); diff --git a/ipaserver/plugins/internal.py b/ipaserver/plugins/internal.py index 8ea56f685..00af70672 100644 --- a/ipaserver/plugins/internal.py +++ b/ipaserver/plugins/internal.py @@ -352,6 +352,7 @@ class i18n_messages(Command): "tickets (obtainable via kinit) and configured the browser " "correctly, then click 'Log in'."), + "loading": _("Loading"), "loading_md": _("Loading data"), "login": _("Log in"), "login_certificate": _("Log In Using Certificate"),