aboutsummaryrefslogtreecommitdiff
path: root/app/forms/app_forms.py
blob: 92913d6123a6de79ff5535ff5962ded941be924d (plain)
1
2
3
4
5
6
7
8
9
10
from flask_wtf import FlaskForm
from wtforms import StringField, TextAreaField
from wtforms.fields.html5 import EmailField
from wtforms.validators import DataRequired, Email

class MyForm(FlaskForm):
    name = StringField('Name', validators=[DataRequired()])
    email = EmailField('Email', validators=[DataRequired(), Email()])
    subject = StringField('Subject', validators=[DataRequired()])
    body = TextAreaField('Message', validators=[DataRequired()])