Skip to content

Commit 35cc4f2

Browse files
author
Jean Cochrane (Lead developer, DataMade)
committed
Ensure downloads page is translated
1 parent ca973b1 commit 35cc4f2

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

sfm_pc/forms.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import uuid
33

44
from django import forms
5-
from django.utils.translation import ugettext as _, get_language
5+
from django.utils.translation import ugettext as _, get_language, gettext_lazy
66
from django.core.exceptions import ObjectDoesNotExist
77

88
from complex_fields.models import ComplexFieldContainer, ComplexFieldListContainer
@@ -561,10 +561,10 @@ def download_types():
561561

562562

563563
class DownloadForm(forms.Form):
564-
download_type = forms.ChoiceField(label=_("Choose a download type"), choices=download_types)
565-
division_id = forms.ChoiceField(label=_("Country"), choices=division_choices)
566-
sources = forms.BooleanField(label=_("Include sources"), required=False)
567-
confidences = forms.BooleanField(label=_("Include confidence scores"), required=False)
564+
download_type = forms.ChoiceField(label=gettext_lazy("Choose a download type"), choices=download_types)
565+
division_id = forms.ChoiceField(label=gettext_lazy("Country"), choices=division_choices)
566+
sources = forms.BooleanField(label=gettext_lazy("Include sources"), required=False)
567+
confidences = forms.BooleanField(label=gettext_lazy("Include confidence scores"), required=False)
568568

569569

570570
class ChangeLogForm(forms.Form):

templates/download.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ <h2>{% trans "Download information about units" %}</h2>
9898
</div>
9999
<div class="row">
100100
<div class="col-sm-12">
101-
<button type="submit" class="btn btn-success">Download</button>
101+
<button type="submit" class="btn btn-success">{% trans "Download" %}</button>
102102
</div>
103103
</div>
104104
</form>

0 commit comments

Comments
 (0)