Skip to content

Commit

Permalink
Use new plural model to name plural edits
Browse files Browse the repository at this point in the history
Issue #1550

Signed-off-by: Michal Čihař <[email protected]>
  • Loading branch information
nijel committed Jan 29, 2018
1 parent c851662 commit 2de2d9f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions weblate/trans/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,7 @@ def render(self, name, value, attrs=None, renderer=None, **kwargs):
unit = value
values = unit.get_target_plurals()
lang = unit.translation.language
plural = unit.translation.plural
tabindex = self.attrs['tabindex']

# Need to add extra class
Expand Down Expand Up @@ -309,7 +310,7 @@ def render(self, name, value, attrs=None, renderer=None, **kwargs):
else:
label = ugettext('Translation')
else:
label = lang.get_plural_label(idx)
label = plural.get_plural_label(idx)
ret.append(
EDITOR_TEMPLATE.format(
self.get_toolbar(lang, fieldid, unit, idx),
Expand All @@ -331,7 +332,7 @@ def render(self, name, value, attrs=None, renderer=None, **kwargs):
'will be used based on given count (n).'
),
ugettext('Plural equation'),
lang.pluralequation
plural.equation
)
)
)
Expand Down

0 comments on commit 2de2d9f

Please sign in to comment.