jazzband / django-formtools

A set of high-level abstractions for Django forms
https://django-formtools.readthedocs.io
BSD 3-Clause "New" or "Revised" License
814 stars 136 forks source link

Form meta option not working #138

Open Guilouf opened 5 years ago

Guilouf commented 5 years ago

I set up a mutlistepform, which is working great but it does not take into account the widgets options of the class meta:

class MyFormStep1(forms.Form):
    slug = forms.SlugField()
    date_start = forms.DateTimeField()  # type date not rendered in html
    date_end = forms.DateTimeField(
        widget=forms.DateInput(attrs={'type': 'date'}))  # this is working

    class Meta:
        widgets = {
            'date_start': forms.DateInput(attrs={'type': 'date'}),  # not working
            }

I use this `Meta``widgets options in all my other forms and it's working, but not in formtools, at least form multisteps forms.