I remember reading somewhere (I have no idea where) that HAPI did not work in a groovy script launched in asset automation. I haven't seen anything about it in the documentation and I wanted to confirm if this was true or not. If true, would someone have an idea on how to work around that limitation?
I have a project that is strictly for some equipment maintenance with an Asset Schema attached. I want to update attributes when other attributes have been changed. i.e. when a maintenance completed date is changed the Compliance attribute is updated as well. Is this possible with HAPI and asset automation? or is there a workaround?
HAPI is a feature of ScriptRunner for Jira. While Asset Management does have a Groovy scripting feature, it's not part of ScriptRunner and doesn't have access to HAPI. There is an open feature request for this: https://assist.adaptavist.com/browse/SRJIRA-7060
You may be able to schedule a Script Listener to listen for Issue Updated events, though I'm not 100% sure that updates to the Compliance attribute will trigger an Issue Updated event. There is also an open feature requests to support Asset events directly: https://assist.adaptavist.com/browse/SRJIRA-7357
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.