Commit 9e22d0fb authored by Administrator's avatar Administrator
Browse files

Show required date format in label

/close #48
parent 2d49fcd3
...@@ -134,7 +134,7 @@ class MeetingReminderForm(FlaskForm): ...@@ -134,7 +134,7 @@ class MeetingReminderForm(FlaskForm):
class NewProtocolForm(FlaskForm): class NewProtocolForm(FlaskForm):
protocoltype = SelectField("Typ", choices=[], coerce=int) protocoltype = SelectField("Typ", choices=[], coerce=int)
date = DateField("Datum", validators=[InputRequired("Du musst ein Datum angeben.")], format="%d.%m.%Y") date = DateField("Datum (dd.mm.yyyy)", validators=[InputRequired("Du musst ein Datum angeben.")], format="%d.%m.%Y")
def __init__(self, protocoltypes, **kwargs): def __init__(self, protocoltypes, **kwargs):
super().__init__(**kwargs) super().__init__(**kwargs)
...@@ -165,7 +165,7 @@ class NewProtocolFileUploadForm(FlaskForm): ...@@ -165,7 +165,7 @@ class NewProtocolFileUploadForm(FlaskForm):
self.protocoltype.choices = get_protocoltype_choices(protocoltypes, add_all=False) self.protocoltype.choices = get_protocoltype_choices(protocoltypes, add_all=False)
class ProtocolForm(FlaskForm): class ProtocolForm(FlaskForm):
date = DateField("Datum", validators=[InputRequired("Bitte gib das Datum des Protkolls an.")], format="%d.%m.%Y") date = DateField("Datum (dd.mm.yyyy)", validators=[InputRequired("Bitte gib das Datum des Protkolls an.")], format="%d.%m.%Y")
start_time = DateTimeField("Beginn", format="%H:%M", validators=[Optional()]) start_time = DateTimeField("Beginn", format="%H:%M", validators=[Optional()])
end_time = DateTimeField("Ende", format="%H:%M", validators=[Optional()]) end_time = DateTimeField("Ende", format="%H:%M", validators=[Optional()])
location = StringField("Ort") location = StringField("Ort")
...@@ -192,7 +192,7 @@ class NewTodoForm(FlaskForm): ...@@ -192,7 +192,7 @@ class NewTodoForm(FlaskForm):
who = StringField("Person", validators=[InputRequired("Bitte gib an, wer das Todo erledigen soll.")]) who = StringField("Person", validators=[InputRequired("Bitte gib an, wer das Todo erledigen soll.")])
description = StringField("Aufgabe", validators=[InputRequired("Bitte gib an, was erledigt werden soll.")]) description = StringField("Aufgabe", validators=[InputRequired("Bitte gib an, was erledigt werden soll.")])
state = SelectField("Status", choices=[], coerce=coerce_todostate, validators=[CheckTodoDateByState()]) state = SelectField("Status", choices=[], coerce=coerce_todostate, validators=[CheckTodoDateByState()])
date = DateField("Datum", format="%d.%m.%Y", validators=[Optional()]) date = DateField("Datum (dd.mm.yyyy)", format="%d.%m.%Y", validators=[Optional()])
def __init__(self, protocoltypes, **kwargs): def __init__(self, protocoltypes, **kwargs):
super().__init__(**kwargs) super().__init__(**kwargs)
...@@ -203,7 +203,7 @@ class TodoForm(FlaskForm): ...@@ -203,7 +203,7 @@ class TodoForm(FlaskForm):
who = StringField("Person") who = StringField("Person")
description = StringField("Aufgabe", validators=[InputRequired("Bitte gib an, was erledigt werden soll.")]) description = StringField("Aufgabe", validators=[InputRequired("Bitte gib an, was erledigt werden soll.")])
state = SelectField("Status", choices=[], coerce=coerce_todostate, validators=[CheckTodoDateByState()]) state = SelectField("Status", choices=[], coerce=coerce_todostate, validators=[CheckTodoDateByState()])
date = DateField("Datum", format="%d.%m.%Y", validators=[Optional()]) date = DateField("Datum (dd.mm.yyyy)", format="%d.%m.%Y", validators=[Optional()])
def __init__(self, **kwargs): def __init__(self, **kwargs):
super().__init__(**kwargs) super().__init__(**kwargs)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment