Replaces ugettext with ugettext_lazy in the dashboard-related files

While most files correctly import ugettext_lazy, some are importing ugettext instead.
This is causing some parts of the dashboard to not translate correctly when a user
switches languages. The core cause of this is because ugettext will translate the
string once when the django application starts. ugettext_lazy will translate when the
string is retrieved.

Change-Id: Ibbdef60b3616d13aa7c2c5449ca592bf214a5f71
Fixes: bug #1124276
This commit is contained in:
Joe Topjian 2013-02-13 21:44:49 +00:00
parent 900572260b
commit d107e4d9b5
5 changed files with 5 additions and 5 deletions

View File

@ -17,7 +17,7 @@
import logging import logging
from django.core.urlresolvers import reverse from django.core.urlresolvers import reverse
from django.utils.translation import ugettext as _ from django.utils.translation import ugettext_lazy as _
from horizon import exceptions from horizon import exceptions

View File

@ -20,7 +20,7 @@
from django.conf import settings from django.conf import settings
from django.utils.translation import ugettext as _ from django.utils.translation import ugettext_lazy as _
from django.core.urlresolvers import reverse from django.core.urlresolvers import reverse
from horizon import exceptions from horizon import exceptions

View File

@ -22,7 +22,7 @@ import json
import logging import logging
from django.utils.text import normalize_newlines from django.utils.text import normalize_newlines
from django.utils.translation import ugettext as _ from django.utils.translation import ugettext_lazy as _
from horizon import exceptions from horizon import exceptions
from horizon import forms from horizon import forms

View File

@ -19,7 +19,7 @@ import logging
import netaddr import netaddr
from django.core.urlresolvers import reverse from django.core.urlresolvers import reverse
from django.utils.translation import ugettext as _ from django.utils.translation import ugettext_lazy as _
from horizon import exceptions from horizon import exceptions
from horizon import forms from horizon import forms

View File

@ -19,7 +19,7 @@ import logging
import netaddr import netaddr
from django.core.urlresolvers import reverse from django.core.urlresolvers import reverse
from django.utils.translation import ugettext as _ from django.utils.translation import ugettext_lazy as _
from horizon import exceptions from horizon import exceptions
from horizon import forms from horizon import forms