Hi IA community,
I am trying to use the system.perspective.navigate() function to navigate to various views based on certain tag values following a tag change event on the same tag. I am attempting to do this in a gateway event script. My understanding is that I need to get the session Id and page Id's.
To test whether I am actually able to get the session and page Id's, I am writing those values to tags. I see content in my 'sessionId' tag, but not in my 'pageId' tag. Unfortunately, I don't see much information or examples in the manual that align with what I am trying to accomplish. Nor do I see much in the forums.
Can someone please advise what I could be doing wrong here? Thank you in advance for any help anyone could provide! My code is below.
#Get session info for the Digital Signage project
sessionInfo = system.perspective.getSessionInfo(projectFilter = 'Digital_Signage')
#If step value is 30, then navigate to the break screen
if newValue.getValue() == 30:
system.perspective.navigate(view = '1st Shift Break 1 Time Screen', sessionId = sessionInfo['id'], pageId = sessionInfo['pageIds'])
system.perspective.refresh(sessionId = sessionInfo['id'], pageId = sessionInfo['pageIds'])
#Write session ID and page ID's to their respective tags
system.tag.writeBlocking('[Digital Signage]sessionID', sessionId)
system.tag.writeBlocking('[Digital Signage]PageID', pageId)