We have created an Issue panel on JIRA issue view screen. What we need to render is a list of issue keys (which fetched by an API call).
This is how we define the Forge library manifest.yml file:
- key: dylan-hello-world-app-hello-world-panel
title: Forge App by Dylan
- key: issue-updated-trigger
- key: main
- key: issue-trigger-func
id: our cloud app id
My run() function does the the rendering part of the panel (initial render).
The issueUpdateTrigger(event, context) function will be triggered when issue updated event happens. By default, this function will automatically received event and context parameters from JIRA.
In the issueUpdateTrigger, we would like to call API again by passing in context to retrieve new issue keys list and also update the context of our existing panel. May I know how can we perform the regarding actions?
(I think It is a must to expose both run() and issueUpdatedTrigger() functions in the index file, cause this is how Forge reads the function, and therefore these two functions might not be able to share a common ancestor function.)
Appreciate your help and do let me know if more information is needed :D
Unfortunately refreshing the issue panel is not possible inside event listening function. You may provide a button for users to refresh an issue using e.g. useAction https://developer.atlassian.com/platform/forge/ui-kit-hooks-reference/#useaction - when state of the hook is refreshed, the view is re-rendered.
I see... thanks for explaining.
We are doing something like an issue panel to display information regarding the ticket, ,and therefore we would require the issue panel to listen for the event of issue updating and not the event that is happening within the app itself (like button onClick).
Can I also check with you is the function below catching JIRA Issue updating event? Because we have tested this for our app but it is not catching event from JIRA when we update the issue.
alert('public event fired');
Again, appreciate your input!
unfortunately currently it's not possible using UI kit. But with CustomUI you can build your own UI with JS and use e.g. some interval polling / checking if the state changed.
This morning, Atlassian announced the acquisition of ThinkTilt , the maker of ProForma, a no-code/low code form builder with 700+ customers worldwide. ThinkTilt helps IT empower any team in their or...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events