First time here? Check out the FAQ!
1

Make "answer must be ..." translatable
 

In file forms.py (rows 356,357) need change:

self.length_error_template_singular = 'answer must be > %d character'
self.length_error_template_plural = 'answer must be > %d characters'

on

self.length_error_template_singular = _('answer must be > %d character')
self.length_error_template_plural = _('answer must be > %d characters')

To enter a block of code:

  • enter empty line after your previous text
  • paste or type the code
  • select the code and press the button above
Preview: (hide)
wowas's avatar
1
wowas
asked 11 years ago

Comments

see more comments

1 Answer

0

Not sure if this is exactly the way to go - take a look how this phrase is used - it later becomes an argument to ugettext_lazy. Maybe we should add a dummy _() just within that class on top of your changes.

Maybe there is another way to simplify this.

To enter a block of code:

  • enter empty line after your previous text
  • paste or type the code
  • select the code and press the button above
Preview: (hide)
Evgeny's avatar
13.2k
Evgeny
answered 11 years ago
link

Comments

see more comments