Ticket #16272: 16272.patch
File 16272.patch, 1.2 KB (added by , 13 years ago) |
---|
-
django/forms/widgets.py
371 371 372 372 class DateInput(Input): 373 373 input_type = 'text' 374 format = '%Y-%m-%d' # '2006-10-25'375 374 376 375 def __init__(self, attrs=None, format=None): 377 376 super(DateInput, self).__init__(attrs) … … 403 402 404 403 class DateTimeInput(Input): 405 404 input_type = 'text' 406 format = '%Y-%m-%d %H:%M:%S' # '2006-10-25 14:30:59'407 405 408 406 def __init__(self, attrs=None, format=None): 409 407 super(DateTimeInput, self).__init__(attrs) … … 435 433 436 434 class TimeInput(Input): 437 435 input_type = 'text' 438 format = '%H:%M:%S' # '14:30:59'439 436 440 437 def __init__(self, attrs=None, format=None): 441 438 super(TimeInput, self).__init__(attrs) … … 828 825 """ 829 826 A Widget that splits datetime input into two <input type="text"> boxes. 830 827 """ 831 date_format = DateInput.format832 time_format = TimeInput.format833 828 834 829 def __init__(self, attrs=None, date_format=None, time_format=None): 835 830 widgets = (DateInput(attrs=attrs, format=date_format),