Modify

Opened 7 years ago

Closed 17 months ago

#5461 closed defect (wontfix)

first day of week should be found in locale

Reported by: doki_pen Owned by: rjollos
Priority: normal Component: DateFieldPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.12

Description

first day of week in calendar should be configured based on the users locale. first_day_of_week config should be changed to default_first_day_of_week

Attachments (0)

Change History (9)

comment:1 Changed 7 years ago by doki_pen

  • Status changed from new to assigned

comment:2 Changed 6 years ago by rjollos

Does Trac have a configurable preference for this? I've wanted to do the same thing with a few other macros, but have not been able to find such a preference in Trac. It seems like it would be best to have a parameter for this in the [trac] section of trac.ini.

comment:3 follow-up: Changed 6 years ago by anonymous

On the contrary. It should be by user

comment:4 in reply to: ↑ 3 Changed 6 years ago by rjollos

Replying to anonymous:

On the contrary. It should be by user

That is sort of where I was headed ... Like the timezone preference, which has a trac setting and a user preference, the locale could have the same options. If the user specifies a preference, it over-rides the Trac setting.

Such an option currently does not exist, right?

Trac dates and times are currently displayed in the format, MM/DD/YYYY HH:MM PM, so the day of week preference might be something that could be implemented along with a datetime format preference.

comment:5 Changed 6 years ago by doki_pen

We have trac settings for display order of date, date separator and first day of week. http://trac-hacks.org/wiki/DateFieldPlugin

comment:6 Changed 4 years ago by hasienda

For the record: "first week day in user-preferences" is an enhancement tracked in t:#10757 (see comment 9 in that ticket).

comment:7 in reply to: ↑ description Changed 4 years ago by hasienda

  • Trac Release changed from 0.11 to 0.12

Replying to doki_pen:

first day of week in calendar should be configured based on the users locale. first_day_of_week config should be changed to default_first_day_of_week

Coming from recent work for WikiCalendarMacro I know, that one could find a user-defined setting per request by help of req.locale (since Trac 0.12), instantiate Locale, a Babel object, that in turn would provide the appropriate value in Locale.first_week_day, (see source:wikicalendarmacro/trunk/wikicalendar/macros.py).

Doesn't matter, if Babel has been installed or not, I think no solution should be expected for Trac < 0.12, because it lacks even basic localization support.

comment:8 Changed 3 years ago by rjollos

  • Owner changed from doki_pen to rjollos

comment:9 Changed 17 months ago by rjollos

  • Resolution set to wontfix
  • Status changed from assigned to closed

The forthcoming Trac 1.2 supports time fields, so this plugin is being deprecated.

Add Comment

Modify Ticket

Action
as closed The owner will remain rjollos.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.