Ejemplo n.º 1
0
class BlockForm(Form):
    name = StringField()
    station = QuerySelectField(query_factory=all_stations, allow_blank=False)
    start_time = TimeField()
    end_time = TimeField()
    recurrence = HiddenField()
    submit = SubmitField(_('Save'))
Ejemplo n.º 2
0
class DishForm(ModelForm):
    class Meta:
        model = Dish

    dish_name = StringField('Название блюда', [validators.DataRequired()])
    recipe = StringField('Рецепт', [validators.DataRequired()])
    time = TimeField('Время', [validators.DataRequired()])
    button_save = SubmitField('Сохранить')
Ejemplo n.º 3
0
class ScheduleProgramForm(Form):
    #station = QuerySelectField(query_factory=all_stations,allow_blank=False)
    station = TextField(u'Station')
    program = QuerySelectField(query_factory=all_programs,
                               allow_blank=True,
                               blank_text='- select program -')
    #block = QuerySelectField(query_factory=all_blocks,allow_blank=False) #let user select block?
    air_time = TimeField(description=_("Time to begin airing"))
    recurrence = HiddenField()
    #priority = IntegerField(description=_("Ascending values"))
    # other options for flexibility?
    submit = SubmitField(_('Save'))