Skip to content

Fix formdata default value on ModelForm <-> FlaskForm inheritance. #387

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 2 commits into from
Jun 7, 2020

Conversation

sdayu
Copy link
Contributor

@sdayu sdayu commented May 11, 2020

Normally, when form instantiation using flask-wtf library in flask view. The form has default formdata as _Auto for automatically parsing from request.form and request.files. In ModelForm inherit from FlaskForm, the formdata in constructor default value is None. I try to add _Auto as formdata of ModelForm constructor for flask-wtf behavior compatibility.

Thank,

@insspb
Copy link
Collaborator

insspb commented Jun 7, 2020

@sdayu Thank you for contribution. Merged in master.

@insspb insspb added log:fixed Changelog mark label. Marks fixed bug issues. type: enhancement Enhancement update for old feature labels Jun 7, 2020
@insspb insspb changed the title add _Auto as formdata in constructor for flask-wtf compatition Fix formdata default value on ModelForm <-> FlaskForm inheritance. Jun 7, 2020
@insspb insspb merged commit af4b255 into MongoEngine:master Jun 7, 2020
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
log:fixed Changelog mark label. Marks fixed bug issues. type: enhancement Enhancement update for old feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants