rollerverbrauch/app/forms/consumable.py

26 lines
859 B
Python

from flask_wtf import FlaskForm
from wtforms import SelectField, StringField, SubmitField
from wtforms.validators import Length
class SelectConsumableForm(FlaskForm):
consumable = SelectField('Consumable', coerce=int)
submit = SubmitField(label='Do it!')
class CreateConsumableForm(FlaskForm):
name = StringField('Name', validators=[Length(1, 255)])
ext_id = SelectField('Tankerkönig ID', coerce=int)
unit = StringField('Unit', validators=[Length(1, 255)])
submit = SubmitField(label='Do it!')
class EditConsumableForm(FlaskForm):
name = StringField('Name', validators=[Length(1, 255)])
ext_id = SelectField('Tankerkönig ID', coerce=int)
unit = StringField('Unit', validators=[Length(1, 255)])
submit = SubmitField(label='Do it!')
class DeletConsumableForm(FlaskForm):
submit = SubmitField(label='Do it!')