- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-28-2020 01:27 PM
Hello,
In Service Portal, when we open the incident view and in Activity timeline after incident is being created work notes is mentioned, as soon as the incident is created it shows created 5hr ago. But the actual time of incident created is different. When we hover over on the 5hr it shows wrong time.
When i print the data.created_on is getting the correct date and time, but why it is showing wrong there. can someone please help.
Attaching the screenshots of script and portal view.
Thanks,
Pooja
Solved! Go to Solution.
- Labels:
-
Service Portal Development
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-29-2020 10:02 AM
I found the answer,
From server side we are doing data.created_on = gr.getDisplayValue('sys_created_on') , when passing the display value to timestamp it id going back for 5hrs and setting the value. So, I changed that getDisplayValue to getValue() method and now the date and time is working correctly.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-28-2020 01:48 PM
Did you customize this widget? On my OOB no day shows. It just says created 2 hours ago.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-28-2020 02:06 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-28-2020 02:31 PM
I'm not sure on this one. I have seen something similar where is was adding 5 hours to a date/time variable when a user manually type in the date and time in the wrong format. Eg left off the seconds. It was a bug in the system which I believe was fixed in New York.
Note: My only other thought would be if you are in a different time zone then the submitter.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-29-2020 10:02 AM
I found the answer,
From server side we are doing data.created_on = gr.getDisplayValue('sys_created_on') , when passing the display value to timestamp it id going back for 5hrs and setting the value. So, I changed that getDisplayValue to getValue() method and now the date and time is working correctly.