Задать вопрос

Тел: +7 965 3737 888

439

Просмотров

1

Ответов

Pass db.Field to newforms.Widget

Deprecated. I don't use this any more.

Hi,

I want decimal input which uses a comma as decimal seperator. It was quite complicated, but it works.

It can be used as an example how to create an own subclass of an existing db.Field class and how to pass the dbfield to the widget, and use it in its render() method.

I think my snippet is too complicated, but couldn't find a better solution. If you do, please tell me.

Вопрос полезен? Да0/Нет0
file_5114.py(1.6Кб)
None

Ответы (1):

Ответguettli:17.09.2008
Ответ полезен? Да0/Нет0

This snippet is deprecated. I coded it long ago. Django and my django skills have evolved.