I write workflow post functions in scriptRunner.
I need to know if a transition was caused by hit button or script
@zeng qing , in your script do you use any specific automation user account to action the transition? If you are letting it authorize as the current user or a general user, i do not see a way to differentiate. The history will be only record the user account, timestamp and change details and not further details on the change was triggered.
If you can't differentiate on the basis of user, then no, there's no way to know.
You can do it though - when you write a script that causes a transition, have it store data on the issue to record it (a custom field you don't bother to put on the view screens or cards is the simplest option).
Your post-functions can then read that (and clear it if you don't need it again)
Can't agree more.Thanks
It looks like you're new here. Sign in or register to get started.