Hello @Mouna Hammoudi I understand the issue you are reporting. I see the same. And I have the solution.
I am aware that the event must be associated with a notification scheme or a workflow. I see from your screenshot that you put the SR post-function just before the post-function that fires the 'Generic Event'.
I did the same, but then I learned that when you associate it with a workflow, DO NOT use the scriptrunner Fire Event post-function.
Instead, change the existing post-function to fire your event instead of 'Generic Event'.
For @Nic Brough -Adaptavist- benefit, when we look at the events in the system (secure/admin/ListEventTypes.jspa), they appear 'Inactive' unless you associate the event to a workflow. If we use the SR post-function to fire an event, we see that the event remains 'Inactive', so using the SR post-function doesn't satisfy.
For me, to get this to recognize the workflow post-function, I had to fire the event from the existing post-function, like so:
and to satisfy the need for it to be "associated with a workflow", create a dummy workflow used by no projects. In the dummy workflow, change the default post-function make a reference to your event.
Once you do, your events suddenly become active.
Once active, you can fire them via a post-function or in custom code.
This happens when all the workflows that fire the event are inactive, or there are none using it at all.
You probably need to publish the draft workflow where you have added the event.
A number of versions ago, there was a minor bug in Jira that meant you also have to have triggered the event at least once to get Jira to realise that the event is active. I do not know if that has been fixed, but a good test remains behind it - try triggering the event and then going back to look at its state.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
It has already been published, it's not just a draft. Even though it has been published, it's still shown as inactive.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
And what about the rest of the answer?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have triggered the event many many times and still, nothing happens.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have triggered the event many times, here is the proof
However, the iTrac SF is still inactive
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
So it is active. What makes you think it is inactive?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Could you show us that? I can't see inactive events when they are active, so I'm a bit stuck on what you are seeing.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.