2011-11-18 14:01:06 +01:00
|
|
|
from django import forms
|
|
|
|
|
|
|
|
from .models import Event
|
|
|
|
|
2013-11-02 22:34:05 +01:00
|
|
|
|
2011-11-18 14:01:06 +01:00
|
|
|
class EventForm(forms.Form):
|
|
|
|
dt = forms.DateTimeField()
|
|
|
|
|
2013-11-02 22:34:05 +01:00
|
|
|
|
2011-11-18 14:01:06 +01:00
|
|
|
class EventSplitForm(forms.Form):
|
|
|
|
dt = forms.SplitDateTimeField()
|
|
|
|
|
2013-11-02 22:34:05 +01:00
|
|
|
|
2013-09-21 22:50:33 +02:00
|
|
|
class EventLocalizedForm(forms.Form):
|
|
|
|
dt = forms.DateTimeField(localize=True)
|
|
|
|
|
2013-11-02 22:34:05 +01:00
|
|
|
|
2011-11-18 14:01:06 +01:00
|
|
|
class EventModelForm(forms.ModelForm):
|
|
|
|
class Meta:
|
|
|
|
model = Event
|
2013-02-21 22:56:55 +01:00
|
|
|
fields = "__all__"
|
2013-09-21 22:50:33 +02:00
|
|
|
|
2013-11-02 22:34:05 +01:00
|
|
|
|
2013-09-21 22:50:33 +02:00
|
|
|
class EventLocalizedModelForm(forms.ModelForm):
|
|
|
|
class Meta:
|
|
|
|
model = Event
|
|
|
|
fields = "__all__"
|
|
|
|
localized_fields = "__all__"
|