Removed unnecessary microsecond truncation in SplitDateTimeWidget.
The microseconds are already truncated by the TimeInput subwidget.
This commit is contained in:
parent
3c34452ab5
commit
90ca9412e4
|
@ -888,7 +888,7 @@ class SplitDateTimeWidget(MultiWidget):
|
|||
def decompress(self, value):
|
||||
if value:
|
||||
value = to_current_timezone(value)
|
||||
return [value.date(), value.time().replace(microsecond=0)]
|
||||
return [value.date(), value.time()]
|
||||
return [None, None]
|
||||
|
||||
|
||||
|
|
|
@ -359,7 +359,7 @@ foundation for custom widgets.
|
|||
|
||||
def decompress(self, value):
|
||||
if value:
|
||||
return [value.date(), value.time().replace(microsecond=0)]
|
||||
return [value.date(), value.time()]
|
||||
return [None, None]
|
||||
|
||||
.. tip::
|
||||
|
|
Loading…
Reference in New Issue