Merge pull request #176 from emorozov/master

Support proper translation of placeholders using ugettext_lazy.
This commit is contained in:
Johannes Hoppe 2015-06-08 11:02:59 +02:00
commit 1224b8d65c

View file

@ -142,6 +142,8 @@ class Select2Mixin(object):
options = dict(self.options)
if options.get('allowClear', None) is not None:
options['allowClear'] = not self.is_required
if options.get('placeholder'):
options['placeholder'] = force_text(options['placeholder'])
return options
def render_js_code(self, id_, *args):