Password protection of admin pages, publish-switch and small fixes
This commit is contained in:
@@ -10,11 +10,13 @@ class PageForm(FlaskForm):
|
||||
title = StringField('Title', validators=[DataRequired()])
|
||||
description = TextAreaField('Beskrivning')
|
||||
endpoint = BooleanField('Produkt')
|
||||
published = BooleanField('Publicerad')
|
||||
thumbnail = QuerySelectField('Bild', get_label=lambda p: '{} ({})'.format(p.alt, p.id))
|
||||
photos = QuerySelectMultipleField('Galleri',
|
||||
option_widget=widgets.CheckboxInput(),
|
||||
widget=widgets.ListWidget(prefix_label=False),
|
||||
get_label = lambda p: '<img src="/thumbnail/{}">'.format(p.id))
|
||||
parent = QuerySelectField('Kategori', get_label = lambda p: '{} - {}'.format(p.permalink, p.title))
|
||||
submit = SubmitField('Ok')
|
||||
|
||||
class PhotoForm(FlaskForm):
|
||||
|
||||
Reference in New Issue
Block a user