[ 
https://issues.apache.org/jira/browse/TRINIDAD-1419?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Matthias Weßendorf resolved TRINIDAD-1419.
------------------------------------------

       Resolution: Fixed
    Fix Version/s: 1.2.13-core 
                   1.0.12-core
         Assignee: Matthias Weßendorf

> Trinidad chooseDate golden files break with daylight savings
> ------------------------------------------------------------
>
>                 Key: TRINIDAD-1419
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-1419
>             Project: MyFaces Trinidad
>          Issue Type: Bug
>          Components: Components
>            Reporter: Yee-Wah Lee
>            Assignee: Matthias Weßendorf
>             Fix For: 1.0.12-core, 1.2.13-core 
>
>         Attachments: trin12_1419.diff
>
>
> This is a result of Trinidad-1349.  The server and client both use the 
> current date (System.currentTimeMillis)  to determine the timezone offset, 
> called baseTZOffset.  If the date being rendered has a different timezone 
> offset (called currTZOffset), it will append the timezone offset of the 
> server in that particular date-link. The client uses currTZOffset to 
> calculate how many hours to adjust the selected date-time by. 
> The code solves the problem mentioned in the original bug, but it also  
> causes problems for the chooseDate golden files. The baseTZOffset shifts 
> depending on the current daylight settings, hence the link being generated 
> will reflect that difference. 
> For example, suppose chooseDate test uses current date as July 27 2005, and 
> timezone in trinidad-config is set to "Pacific Standard Time". In PST, the 
> timezone offset is -8h (-480) . In  PDT, the timezone offset is -7h (-420), 
> which is also the timezone offset of July 27 2005. 
> chooseDate  golden file in PST 
>           <a  onclick="return _calsd('dateid',1122447600000, -420)"
> because baseTZOffset = -480, currTZOffset = -420. The client needs to use 
> -420 when calculating the timezone difference on that day.
> chooseDate golden file in PDT:
>           <a  onclick="return _calsd('dateid',1122447600000)"
> because baseTZoffset = currTZOffset = -420. The client can directly use 
> baseTZoffset. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to