#29109: `undefined` show in auto generated datetime input or time input in form when using locale as `th` -------------------------------------+------------------------------------- Reporter: Napat | Owner: nobody Charoenlarpkul | Type: Bug | Status: new Component: | Version: 1.11 Internationalization | Keywords: form datetime thai Severity: Normal | locale Triage Stage: | Has patch: 0 Unreviewed | Needs documentation: 0 | Needs tests: 0 Patch needs improvement: 0 | Easy pickings: 0 UI/UX: 0 | -------------------------------------+------------------------------------- I found wrong datetime format order in `django/conf/locale/th/formats.py`
In `TIME_INPUT_FORMATS` and `DATETIME_INPUT_FORMATS`, the first order should be `'%H:%M:%S', # 14:30:59` and `'%d/%m/%Y %H:%M:%S', # 25/10/2006 14:30:59` The final code should be like this {{{ #!python TIME_INPUT_FORMATS = [ '%H:%M:%S', # 14:30:59 '%H:%M:%S.%f', # 14:30:59.000200 '%H:%M', # 14:30 ] DATETIME_INPUT_FORMATS = [ '%d/%m/%Y %H:%M:%S', # 25/10/2006 14:30:59 '%d/%m/%Y %H:%M:%S.%f', # 25/10/2006 14:30:59.000200 '%d/%m/%Y %H:%M', # 25/10/2006 14:30 ] }}} -- Ticket URL: <https://code.djangoproject.com/ticket/29109> Django <https://code.djangoproject.com/> The Web framework for perfectionists with deadlines. -- You received this message because you are subscribed to the Google Groups "Django updates" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-updates+unsubscr...@googlegroups.com. To post to this group, send email to django-updates@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/django-updates/053.ffb5e83742cc5d405dc5e74426afbcf2%40djangoproject.com. For more options, visit https://groups.google.com/d/optout.