Update plural forms
This commit is contained in:
parent
bbc4e35bb2
commit
56ee242b2c
@ -8,3 +8,6 @@ class Language(models.Model):
|
|||||||
|
|
||||||
def __unicode__(self):
|
def __unicode__(self):
|
||||||
return self.name
|
return self.name
|
||||||
|
|
||||||
|
def get_plural_form(self):
|
||||||
|
return 'nplurals=%d; plural=%s;' % (self.nplurals, self.pluralequation)
|
||||||
|
@ -11,6 +11,7 @@ import logging
|
|||||||
import git
|
import git
|
||||||
import traceback
|
import traceback
|
||||||
from translate.storage import factory
|
from translate.storage import factory
|
||||||
|
from datetime import datetime
|
||||||
|
|
||||||
import trans
|
import trans
|
||||||
from trans.managers import TranslationManager, UnitManager
|
from trans.managers import TranslationManager, UnitManager
|
||||||
@ -289,6 +290,7 @@ class Translation(models.Model):
|
|||||||
store.updateheader(
|
store.updateheader(
|
||||||
add = True,
|
add = True,
|
||||||
last_translator = author,
|
last_translator = author,
|
||||||
|
plural_forms = self.language.get_plural_form(),
|
||||||
x_generator = 'Weblate %s' % trans.VERSION
|
x_generator = 'Weblate %s' % trans.VERSION
|
||||||
)
|
)
|
||||||
store.save()
|
store.save()
|
||||||
|
Loading…
Reference in New Issue
Block a user