From 170a7b0ed5c804db63468c91d5b9f9d3e734ff88 Mon Sep 17 00:00:00 2001 From: Marcio Mazza Date: Mon, 20 Jul 2015 15:32:06 -0300 Subject: [PATCH] Fix i18n setup for models --- base/models.py | 2 +- comissoes/models.py | 2 +- legacy/scripts/scrap_original_forms.py | 2 +- lexml/models.py | 2 +- materia/models.py | 2 +- norma/models.py | 2 +- parlamentares/models.py | 2 +- protocoloadm/models.py | 2 +- sessao/models.py | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) diff --git a/base/models.py b/base/models.py index e99785acc..61abbbf89 100644 --- a/base/models.py +++ b/base/models.py @@ -1,5 +1,5 @@ from django.db import models -from django.utils.translation import ugettext as _ +from django.utils.translation import ugettext_lazy as _ class CasaLegislativa(models.Model): diff --git a/comissoes/models.py b/comissoes/models.py index d15855fbf..6502ac7c0 100644 --- a/comissoes/models.py +++ b/comissoes/models.py @@ -1,5 +1,5 @@ from django.db import models -from django.utils.translation import ugettext as _ +from django.utils.translation import ugettext_lazy as _ from parlamentares.models import Parlamentar from sapl.utils import make_choices diff --git a/legacy/scripts/scrap_original_forms.py b/legacy/scripts/scrap_original_forms.py index ed059587c..f7a126b28 100644 --- a/legacy/scripts/scrap_original_forms.py +++ b/legacy/scripts/scrap_original_forms.py @@ -180,7 +180,7 @@ def print_app_with_verbose_names(app): continue elif line == 'from django.db import models': header += '''from django.db import models -from django.utils.translation import ugettext as _ +from django.utils.translation import ugettext_lazy as _ ''' elif 'class' in line: break diff --git a/lexml/models.py b/lexml/models.py index b1ce636ec..0c085c64a 100644 --- a/lexml/models.py +++ b/lexml/models.py @@ -1,5 +1,5 @@ from django.db import models -from django.utils.translation import ugettext as _ +from django.utils.translation import ugettext_lazy as _ class LexmlProvedor(models.Model): # LexmlRegistroProvedor diff --git a/materia/models.py b/materia/models.py index c6947f5d3..ae456c88d 100644 --- a/materia/models.py +++ b/materia/models.py @@ -1,5 +1,5 @@ from django.db import models -from django.utils.translation import ugettext as _ +from django.utils.translation import ugettext_lazy as _ from comissoes.models import Comissao from parlamentares.models import Parlamentar, Partido diff --git a/norma/models.py b/norma/models.py index 9b716ef04..b692cddd9 100644 --- a/norma/models.py +++ b/norma/models.py @@ -1,5 +1,5 @@ from django.db import models -from django.utils.translation import ugettext as _ +from django.utils.translation import ugettext_lazy as _ from materia.models import MateriaLegislativa from sapl.utils import make_choices diff --git a/parlamentares/models.py b/parlamentares/models.py index a071fd3f1..76c0d742b 100644 --- a/parlamentares/models.py +++ b/parlamentares/models.py @@ -1,5 +1,5 @@ from django.db import models -from django.utils.translation import ugettext as _ +from django.utils.translation import ugettext_lazy as _ from sapl.utils import make_choices diff --git a/protocoloadm/models.py b/protocoloadm/models.py index 82ca5f3a5..03b2a185d 100644 --- a/protocoloadm/models.py +++ b/protocoloadm/models.py @@ -1,5 +1,5 @@ from django.db import models -from django.utils.translation import ugettext as _ +from django.utils.translation import ugettext_lazy as _ from materia.models import Autor, TipoMateriaLegislativa, UnidadeTramitacao from sapl.utils import make_choices diff --git a/sessao/models.py b/sessao/models.py index e7a1cbb7f..bce1e6733 100644 --- a/sessao/models.py +++ b/sessao/models.py @@ -1,5 +1,5 @@ from django.db import models -from django.utils.translation import ugettext as _ +from django.utils.translation import ugettext_lazy as _ from materia.models import MateriaLegislativa from parlamentares.models import (CargoMesa, Parlamentar, SessaoLegislativa,