Schedule Job "run as"

russellprice
Tera Contributor

Hi

I have a scheduled job which triggers an event to run a notification email script.

It shows the last 24hrs worth of incidents and must show the start time in the users time zone. When i click the "preview notification" button in Notifictions the time is shown correctly as the users time zone:

find_real_file.png

However, when the schedule is triggered the email comes out showing the system time:

find_real_file.png

It doesn't seem to make any difference if i change the "run as" user in the scheduled job, it still sends the email out using the system time.

My code is obviously working because it shows correctly in the "preview notification" so there must be something im doing wrong with the scheduled job? Can anyone shed light on this?

6 REPLIES 6

russellprice
Tera Contributor

Can no one tell me why getDisplayValue displays the time and date in the users time zone when you "preview notification" but when the notification is ran by a schedule it displays system time instead (GMT).

The schedules "Run as" is a user whos time zone is "US/Eastern" and the "Run as tz" is set to "US/Eastern" so i cant see why its still showing system time.

Run as user is only a placeholder used for logging purposes. If the field is left blank, the created by will show System Administration. If you put any other user in there (even with no roles except snc_internal) the scheduled job will show that username in the log. I don't know about the run as tz failure.

-Chris