Yup, that works! Thank you!
On Friday, February 1, 2019 at 2:17:23 PM UTC-8, Tim Graham wrote:
>
> When you add a form field like that, it removes inheritance of field
> attributes like verbose_name from the model.
>
> Instead, you could override Form.__init__() and set the widget similar to
>
When you add a form field like that, it removes inheritance of field
attributes like verbose_name from the model.
Instead, you could override Form.__init__() and set the widget similar to
what's described at
https://docs.djangoproject.com/en/stable/ref/forms/widgets/ "Or if the
field isn’t
I'm having trouble getting the verbose_name attribute of a model field to
show up when rendering a ModelForm. instead, the label uses the pretty
version of the field name, not the verbose_name. This occurs any time I
specify a field type, and works properly (shows the verbose_name) if I
don't
3 matches
Mail list logo