2011-07-31 10:46:29 +02:00
|
|
|
#!/usr/bin/env python
|
|
|
|
# -*- coding: utf-8 -*-
|
|
|
|
"""
|
2012-04-14 12:52:56 +02:00
|
|
|
openslides.config.forms
|
2011-07-31 10:46:29 +02:00
|
|
|
~~~~~~~~~~~~~~~~~~~~~~~
|
|
|
|
|
2012-04-14 12:52:56 +02:00
|
|
|
Forms for the config app.
|
2011-07-31 10:46:29 +02:00
|
|
|
|
2012-04-25 22:29:19 +02:00
|
|
|
:copyright: 2011, 2012 by OpenSlides team, see AUTHORS.
|
2011-07-31 10:46:29 +02:00
|
|
|
:license: GNU GPL, see LICENSE for more details.
|
|
|
|
"""
|
|
|
|
|
2012-07-07 14:48:21 +02:00
|
|
|
from django import forms
|
2012-02-20 18:44:02 +01:00
|
|
|
|
|
|
|
from utils.forms import CssClassMixin
|
2012-04-14 12:52:56 +02:00
|
|
|
from models import config
|
2012-07-10 01:33:03 +02:00
|
|
|
from utils.translation_ext import ugettext_lazy as _
|
2011-07-31 10:46:29 +02:00
|
|
|
|
2012-02-15 12:04:11 +01:00
|
|
|
|
2012-07-07 14:48:21 +02:00
|
|
|
class GeneralConfigForm(forms.Form, CssClassMixin):
|
|
|
|
event_name = forms.CharField(
|
|
|
|
widget=forms.TextInput(),
|
|
|
|
label=_("Event name"),
|
|
|
|
max_length=30,
|
|
|
|
)
|
|
|
|
|
|
|
|
event_description = forms.CharField(
|
|
|
|
widget=forms.TextInput(),
|
|
|
|
label=_("Short description of event"),
|
|
|
|
required=False,
|
|
|
|
max_length=100,
|
|
|
|
|
|
|
|
)
|
|
|
|
|
|
|
|
event_date = forms.CharField(
|
|
|
|
widget=forms.TextInput(),
|
|
|
|
label=_("Event date"),
|
|
|
|
required=False,
|
|
|
|
)
|
|
|
|
|
|
|
|
event_location = forms.CharField(
|
|
|
|
widget=forms.TextInput(),
|
|
|
|
label=_("Event location"),
|
|
|
|
required=False,
|
|
|
|
)
|
|
|
|
|
|
|
|
event_organizer = forms.CharField(
|
|
|
|
widget=forms.TextInput(),
|
|
|
|
label=_("Event organizer"),
|
|
|
|
required=False,
|
|
|
|
)
|
|
|
|
|
|
|
|
system_enable_anonymous = forms.BooleanField(
|
|
|
|
label=_("Allow access for anonymous guest users"),
|
|
|
|
required=False,
|
|
|
|
)
|
|
|
|
|
|
|
|
frontpage_title = forms.CharField(
|
|
|
|
widget=forms.TextInput(),
|
|
|
|
label=_("Title"),
|
|
|
|
required=False,
|
|
|
|
)
|
|
|
|
|
|
|
|
frontpage_welcometext = forms.CharField(
|
|
|
|
widget=forms.Textarea(),
|
|
|
|
label=_("Welcome text"),
|
|
|
|
required=False,
|
|
|
|
)
|