Commit a96aa643 authored by Jérome Perrin's avatar Jérome Perrin

DateTimeField: timezone should not be required

at same time, rename gmt_timezones to all_timezones
parent 1a5f3038
......@@ -234,7 +234,7 @@ def create_datetime_text_sub_form():
title = "Timezone",
required = 0,
default = 'GMT',
items = Widget.gmt_timezones,
items = Widget.all_timezones,
size = 1)
sub_form.add_fields([hour, minute, ampm, timezone], "time")
return sub_form
......@@ -292,7 +292,7 @@ def create_datetime_list_sub_form():
title = "Timezone",
required = 0,
default = 'GMT',
items = Widget.gmt_timezones,
items = Widget.all_timezones,
size = 1)
sub_form.add_group("time")
......
......@@ -1282,7 +1282,7 @@ class MultiCheckBoxWidget(MultiItemsWidget):
MultiCheckBoxWidgetInstance = MultiCheckBoxWidget()
gmt_timezones = [(x, x) for x in sorted(set(Timezones()))]
all_timezones = [('', '')] + [(x, x) for x in sorted(set(Timezones()))]
class DateTimeWidget(Widget):
"""
......@@ -1369,9 +1369,8 @@ class DateTimeWidget(Widget):
title="Default Timezone",
description=(
"The default timezone display when inputing a new date"),
default="GMT",
items=gmt_timezones,
required=1,
default="",
items=all_timezones,
size=1)
input_order = fields.ListField('input_order',
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment