CC-3174 : showbuilder
fixing timezone calculations if browser/server is different.
This commit is contained in:
parent
28759a2d34
commit
564575d657
3 changed files with 15 additions and 6 deletions
|
@ -115,10 +115,10 @@ $(document).ready(function() {
|
|||
iTime = oDate.getTime(); //value is in millisec.
|
||||
iTime = Math.round(iTime / 1000);
|
||||
iServerOffset = serverTimezoneOffset;
|
||||
iClientOffset = oDate.getTimezoneOffset() * 60;//function returns minutes
|
||||
iClientOffset = oDate.getTimezoneOffset() * -60;//function returns minutes
|
||||
|
||||
//adjust for the fact the the Date object is in clent time.
|
||||
iTime = iTime + iServerOffset + iClientOffset;
|
||||
//adjust for the fact the the Date object is in client time.
|
||||
iTime = iTime + iClientOffset + iServerOffset;
|
||||
|
||||
return iTime;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue