views:

42

answers:

1

I need to resolve problem with word endings in django admin panel. The language I'm using is russian (using utf-8 charset), so some problems occur, for example, there is a problem with the right endings on the "Add" button for some model names. The simplest thing I found is using jQuery to correct endings "on the fly", but this solution is too radical. Maybe there is a simple answer? Just don't want to dig again into deepness of django's sources...

+1  A: 

If I understood the problem correctly, you should just add an appropriate attribute in the meta section of the class.
English example:

class Man(models.Model):
    [...your fields...]

    class Meta:
        verbose_name_plural = "men"

More info can be found in the documentation for Django model options

Agos
The problem is that in russian there is not only plural or singular but also there are cases. So the singular for the word "article" will be "stat'ya" in russian, but "add article" will be "dobavit' stat'yu". The problem is in endings.
Enchantner