use lazy i18n for edit form
authorraph
Fri, 26 Mar 2010 12:18:33 +0100
changeset 234 b33dd64a57f0
parent 233 528f4267bcfa
child 235 b23aee4dd81d
use lazy i18n for edit form
src/cm/views/texts.py
--- a/src/cm/views/texts.py	Thu Mar 25 17:25:12 2010 +0100
+++ b/src/cm/views/texts.py	Fri Mar 26 12:18:33 2010 +0100
@@ -615,14 +615,14 @@
         fields = ('title', 'content', 'format')
 
 class EditTextForm(ModelForm):
-    title = forms.CharField(label=_("Title"), widget=forms.TextInput)
+    title = forms.CharField(label=ugettext_lazy("Title"), widget=forms.TextInput)
     #format = forms.CharField(label=_("Format"))
     #content = forms.TextField(label=_("Content"))
 
-    note = forms.CharField(label=_("Note (optional)"),
+    note = forms.CharField(label=ugettext_lazy("Note (optional)"),
                            widget=forms.TextInput,
                            required=False,
-                           help_text=_("Add a note to explain the modifications made to the text")
+                           help_text=ugettext_lazy("Add a note to explain the modifications made to the text")
                            )
 
     #tags = forms.CharField(label=_("Tags (optional)"),
@@ -632,16 +632,16 @@
     #                       )
 
 
-    new_version = forms.BooleanField(label=_("New version (optional)"),
+    new_version = forms.BooleanField(label=ugettext_lazy("New version (optional)"),
                            required=False,
                            initial=True,
-                           help_text=_("Create a new version of this text (recommended)")
+                           help_text=ugettext_lazy("Create a new version of this text (recommended)")
                            )
 
     keep_comments = forms.BooleanField(label=_("Keep comments (optional)"),
                            required=False,
                            initial=True,
-                           help_text=_("Keep comments (if not affected by the edit)")
+                           help_text=ugettext_lazy("Keep comments (if not affected by the edit)")
                            )
     
     class Meta: