add event_place to fetmeeting admin and template
This commit is contained in:
@@ -139,11 +139,12 @@ class EventForm(PostForm):
|
||||
class FetMeetingForm(PostForm):
|
||||
class Meta:
|
||||
model = FetMeeting
|
||||
fields = ["event_start", "event_end", "tags"]
|
||||
fields = ["event_start", "event_end", "event_place", "tags"]
|
||||
|
||||
labels = {
|
||||
"event_start": _("Start der Sitzung"),
|
||||
"event_end": _("Ende der Sitzung"),
|
||||
"event_place": _("Ort der Sitzung"),
|
||||
}
|
||||
|
||||
help_texts = {
|
||||
@@ -165,8 +166,8 @@ class FetMeetingForm(PostForm):
|
||||
|
||||
|
||||
class PostSearchForm(forms.Form):
|
||||
year_choices = [('', _('Alle'))]
|
||||
month_choices = [('', _('Alle'))] + list(MONTHS.items())
|
||||
year_choices = [("", _("Alle"))]
|
||||
month_choices = [("", _("Alle"))] + list(MONTHS.items())
|
||||
|
||||
year = forms.ChoiceField(label="Jahr", choices=year_choices, required=False)
|
||||
month = forms.ChoiceField(label="Monat", choices=month_choices, required=False)
|
||||
@@ -180,8 +181,8 @@ class PostSearchForm(forms.Form):
|
||||
if first_post:
|
||||
year_of_first_post = first_post.public_date.year
|
||||
years = range(year_of_first_post, timezone.now().date().year + 1)
|
||||
year_choices = [('', _('Alle'))] + [(i, i) for i in years]
|
||||
self.fields['year'].choices = year_choices
|
||||
year_choices = [("", _("Alle"))] + [(i, i) for i in years]
|
||||
self.fields["year"].choices = year_choices
|
||||
|
||||
except:
|
||||
pass
|
||||
|
||||
Reference in New Issue
Block a user