How to get the user sysid in ui action

ant_niopires
Mega Contributor

Hi all,

Is it possible to get the sys id of the user that clicked on a specific ui action?

For instance, store that sysid value and later use it to send a notification to the same user.

Any thoughts on this?

Thanks,

António

3 REPLIES 3

Community Alums
Not applicable

You can trigger an event in the UI action and pass the usr sys_id that way:



gs.eventQueue("event.name", current, gs.getUserID(), gs.getUserName());



Cheers,



Tim


Hey Tim,



Thank you for your answer. It is a possible solution but i believe my needs are a bit more complex.



The ui action will start some different processes, including some transform maps. And i would like to send a notification for the user that started the process (clicked on the ui action) once it has finished. So i'm guessing that i should store that sysid somewhere so i can't later grab it in a transform script and send an email to the original user.



Any way to do this?



Thanks


Community Alums
Not applicable

You'll just need to pass that value (sys_id of the user) into each of your functions/processes. Depending on how you're triggering your next process (Business Rules?) you should be able to pass that value on to the next function.



Tim