Opened 11 years ago

Closed 10 years ago

Last modified 9 years ago

#109 closed defect (fixed)

Patch: Customizing Date(Time)Field displays

Reported by: Manuzhai Owned by: anonymous
Component: contrib.admin Version:
Severity: blocker Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

In the admin interface, dates are displayed as July 11, 2005, 8:39 p.m., while I'd at the least prefer to have a 24-hour format for the time. I think there should be options DATE_FORMAT, TIME_FORMAT and DATETIME_FORMAT which take care of the default formatting for these fields.

Attachments (2)

custom-datetime-1.diff (1.1 KB) - added by Manuzhai 11 years ago.
Handling a customizable datetime-formatting.
custom-datetime-2.diff (1.2 KB) - added by Manuzhai 11 years ago.
Setting the default datetime-formatting

Download all attachments as: .zip

Change History (33)

Changed 11 years ago by Manuzhai

Attachment: custom-datetime-1.diff added

Handling a customizable datetime-formatting.

Changed 11 years ago by Manuzhai

Attachment: custom-datetime-2.diff added

Setting the default datetime-formatting

comment:1 Changed 11 years ago by Manuzhai

Ahh, sorry, that second patch also contains my other changes to the global_settings. Oh well, you get my drift, it's quite a trivial patch anyway.

comment:2 Changed 11 years ago by Manuzhai

Summary: Customizing Date(Time)Field displaysPatch: Customizing Date(Time)Field displays

Please comment on this?

comment:3 Changed 11 years ago by Adrian Holovaty

Resolution: fixed
Status: newclosed

(In [1115]) Fixed #109 -- Created DATE_FORMAT, DATETIME_FORMAT and TIME_FORMAT settings.

comment:4 Changed 11 years ago by anonymous

Resolution: fixed
Status: closedreopened

Please keep in mind that these need to be translateable - the problem is, they depend on the language the user chooses, not on some base setting. That's why I changed the code in i18n to have date:_("DATE_WITH_TIME_FULL") in there, so that the actual date format was pulled from the .po (and I added the english default format to the en-.po and the d.m.y format to all other languages).

comment:5 Changed 11 years ago by Nebojša Đorđević - nesh <nesh@…>

Any progress with this? When DATE_FORMAT, DATETIME_FORMAT and TIME_FORMAT will be translatable?

comment:6 Changed 11 years ago by hugo

Owner: changed from Adrian Holovaty to hugo
Status: reopenednew

You could try to use gettext_lazy('DATE_TIME_FULL') (or any other technical message IDs for which you need to put in translations into the translation file) on them. gettext_lazy constructs a translation promise that is realized (= translated) when the value is used as a string. This works quite often automatically.

I use the same technology for translating model names and field names. If that works, please update the ticket so I know that I can do the needed work. I am a bit out-of-the-loop due to my hotel not having net access, but will be able to check into this after the weekend.

comment:7 Changed 11 years ago by hugo

Status: newassigned

comment:8 Changed 11 years ago by hugo

Resolution: fixed
Status: assignedclosed

(In [1208]) fixes #109 - added translation possibilities for date and time formats (and updated translation files for the new message IDs)

comment:9 Changed 10 years ago by Kaka17169

Component: Admin interface
priority: normal
Resolution: fixed
Severity: normal
Status: closedreopened
Type: defect

comment:10 Changed 10 years ago by Kaka99803

Owner: changed from hugo to anonymous
Status: reopenednew

comment:11 Changed 10 years ago by anonymous

Component: Admin interface
priority: highest
Resolution: fixed
Severity: blocker
Status: newclosed
Type: defect

Trac spam

comment:12 Changed 10 years ago by Kaka11861

Component: Admin interface
priority: highest
Resolution: fixed
Severity: blocker
Status: closedreopened
Type: defect

comment:13 Changed 10 years ago by Malcolm Tredinnick

Component: Admin interface
priority: highest
Resolution: fixed
Severity: blocker
Status: reopenedclosed
Type: defect

spam.

comment:14 Changed 10 years ago by Kaka81238

Component: Admin interface
priority: highest
Resolution: fixed
Severity: blocker
Status: closedreopened
Type: defect

comment:15 Changed 10 years ago by Kaka84298

Status: reopenednew

comment:16 Changed 10 years ago by Chris Beaven

Component: Admin interface
priority: highest
Resolution: fixed
Severity: blocker
Status: newclosed
Type: defect

spam

comment:17 Changed 10 years ago by anonymous

Component: Admin interfaceContrib apps
milestone: Version 1.0
priority: highestnormal
Severity: blockerminor
Type: defecttask
Version: 0.9

comment:18 Changed 10 years ago by Kaka73660

Component: Contrib apps
milestone: Version 1.0
priority: normal
Resolution: fixed
Severity: minor
Status: closedreopened
Type: task
Version: 0.9

comment:19 Changed 10 years ago by anonymous

Component: Admin interface
priority: highest
Resolution: fixed
Severity: blocker
Status: reopenedclosed
Type: defect

comment:20 Changed 10 years ago by anonymous

priority: highestnormal
Severity: blockernormal

comment:21 Changed 10 years ago by Kaka23606

Component: Admin interface
priority: normal
Resolution: fixed
Severity: normal
Status: closedreopened
Type: defect

comment:22 Changed 10 years ago by Adrian Holovaty

Component: Admin interface
priority: highest
Resolution: fixed
Severity: blocker
Status: reopenedclosed
Type: defect

comment:23 Changed 10 years ago by Kaka47380

Component: Admin interface
priority: highest
Resolution: fixed
Severity: blocker
Status: closedreopened
Type: defect

comment:24 Changed 10 years ago by Kaka38874

Status: reopenednew

comment:25 Changed 10 years ago by Adrian Holovaty

Component: Admin interface
priority: highest
Resolution: fixed
Severity: blocker
Status: newclosed
Type: defect

comment:26 Changed 10 years ago by Kaka86958

Component: Admin interface
priority: highest
Resolution: fixed
Severity: blocker
Status: closedreopened
Type: defect

comment:27 Changed 10 years ago by Kaka59626

Status: reopenednew

comment:28 Changed 10 years ago by anonymous

Component: Admin interface
priority: highest
Severity: blocker
Type: defect

comment:29 Changed 10 years ago by Tom Tobin <korpios@…>

Resolution: fixed
Status: newclosed

Revert spam.

comment:30 Changed 10 years ago by Kaka24474

Cc: boss added
Component: Admin interfaceboss
Keywords: boss added
milestone: boss
priority: highestboss
Resolution: fixed
Severity: blockerboss
Status: closedreopened
Type: defectboss
Version: boss

comment:31 Changed 10 years ago by anonymous

Cc: boss removed
Component: bossAdmin interface
Keywords: boss removed
milestone: boss
priority: bosshighest
Resolution: fixed
Severity: bossblocker
Status: reopenedclosed
Type: bossdefect
Version: boss

persistant spam

Note: See TracTickets for help on using tickets.
Back to Top