Ticket #1726 (reopened defect)

Opened 2 years ago

Last modified 4 days ago

Change first day of the week in calendar

Reported by: remy.blank@pobox.com Assigned to: coderanger
Priority: normal Component: DateFieldPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.11

Description

I'm in Switzerland and, well, we like our weeks to start on Monday :-)

Here's a patch that adds an option to trac.ini to select the day to be displayed as the first day of the week:

[datefield]
; 0=Sunday .. 6=Saturday
first_day_of_week = 1

Attachments

first_day_of_week.patch (1.9 kB) - added by remy.blank@pobox.com on 07/03/07 06:49:16.
Adds an option 'first_day_of_week' for trac.ini
first_day_=_1.jpg (22.9 kB) - added by hju@jochenkuhl.de on 09/24/08 18:23:31.
First_day = 1
first_day_=_2.jpg (18.5 kB) - added by hju@jochenkuhl.de on 09/24/08 18:24:01.
First_day = 2

Change History

07/03/07 06:49:16 changed by remy.blank@pobox.com

  • attachment first_day_of_week.patch added.

Adds an option 'first_day_of_week' for trac.ini

07/06/08 16:36:42 changed by doki_pen

  • status changed from new to closed.
  • resolution set to fixed.

Added first_day option to 0.11 branch. There seems to be a bug in jquery-ui datepicker that causes the tue column to be highlighted as a weekend when the firstDay parameter is used. Hopefully it will get fixed in jquery-ui.

09/24/08 18:22:07 changed by hju@jochenkuhl.de

  • release changed from 0.10 to 0.11.
  • status changed from closed to reopened.
  • resolution deleted.
  • type changed from enhancement to defect.

There seems to be a bug in jquery-ui datepicker that causes the tue column to be highlighted as a weekend when the firstDay parameter is used. Hopefully it will get fixed in jquery-ui.

It is not only a question of higlighting the tue column. The Column-Headers are even disordered. (see attached screenshots)

09/24/08 18:23:31 changed by hju@jochenkuhl.de

  • attachment first_day_=_1.jpg added.

First_day = 1

09/24/08 18:24:01 changed by hju@jochenkuhl.de

  • attachment first_day_=_2.jpg added.

First_day = 2

11/13/08 07:13:23 changed by petrus69@gmx.de

Same over here, weekday/-end highlighting as well as the disordered day of week short names appear in any first_day=X setting different from first_day=0.

01/05/09 12:31:25 changed by peterson_eric_d@hotmail.com

I also like my calendars to start on Monday. But when I set first_day = 1, the calendar is slightly messed up.

My weekdays are called

MoThSuWeSaTuFri

with Su and Tu highlighted as weekends. The numbers in the calendar are correct, just the week day names and weekend highlights are messed up.


Add/Change #1726 (Change first day of the week in calendar)




Change Properties
Action