1. Alex Willmer
  2. trac-ticketlinks


rblank  committed 808af49

0.12.1dev: Fixed the display of the sample time in the default timezone on the "Date & Time" preference panel, as it was showing the local time instead.

  • Participants
  • Parent commits 7b7adc3
  • Branches 0.12-stable

Comments (0)

Files changed (1)

File trac/prefs/templates/prefs_datetime.html

View file
  • Ignore whitespace
                                 selected_tz = timezone(session_tzname) or utc">
       <label>Time zone:
       <select name="tz">
-        <option>Default time zone</option>
+        <option value="">Default time zone</option>
         <option py:for="tzname in timezones" value="$tzname"
                 selected="${session_tzname != None and
                             session_tzname.startswith('Etc/') and
         <py:when test="session_tzname">
           <i18n:msg params="tz, formatted">
             In your time zone ${selected_tz.tzname(datetime.now())}, this would be displayed as
-            <strong>${format_time(now, 'iso8601', tzinfo=selected_tz)}</strong>.
+            <strong>${format_time(now, 'iso8601', tzinfo=req.tz)}</strong>.
           <i18n:msg params="formatted">
             In the default time zone, this would be displayed as
-            <strong>${format_time(now, 'iso8601', tzinfo=localtz)}</strong>.
+            <strong>${format_time(now, 'iso8601', tzinfo=req.tz)}</strong>.