mirror of https://github.com/logos-co/open-law.git
BaseCollectionForm
This commit is contained in:
parent
5af7933674
commit
c9bf181638
|
@ -3,15 +3,14 @@ from wtforms import StringField, SubmitField
|
||||||
from wtforms.validators import DataRequired, Length
|
from wtforms.validators import DataRequired, Length
|
||||||
|
|
||||||
|
|
||||||
class CreateCollectionForm(FlaskForm):
|
class BaseCollectionForm(FlaskForm):
|
||||||
label = StringField("Label", [DataRequired(), Length(3, 256)])
|
label = StringField("Label", [DataRequired(), Length(3, 256)])
|
||||||
about = StringField("About")
|
about = StringField("About")
|
||||||
|
|
||||||
|
|
||||||
|
class CreateCollectionForm(BaseCollectionForm):
|
||||||
submit = SubmitField("Create")
|
submit = SubmitField("Create")
|
||||||
|
|
||||||
|
|
||||||
class EditCollectionForm(FlaskForm):
|
class EditCollectionForm(BaseCollectionForm):
|
||||||
label = StringField("Label", [Length(3, 256)])
|
|
||||||
about = StringField("About")
|
|
||||||
|
|
||||||
submit = SubmitField("Edit")
|
submit = SubmitField("Edit")
|
||||||
|
|
Loading…
Reference in New Issue