when use JMWE, i can use
issue.getEntityProperty("wf-1st-last-assignee")
to get the value of property "wf-1st-last-assignee".
automation for jira also can get the issue / user / project property.
I try follow code to get the issue entity property in ScriptRunner Script Console
import com.atlassian.jira.component.ComponentAccessor
ComponentAccessor.getIssueManager().getEntitiesByIssueObject("wf-1st-last-assignee", ComponentAccessor.getIssueManager().getIssueObject("BIZMM-92"))
but it return []
how to get issue entity property with ScriptRunner?
Hi @ATLN AVer,
In our case, we were searching for the ability to update (not get) issue property via script runner. And found a following way:
def
result = put(
'/rest/api/2/issue/'
+ issueKey +
'/properties/'
+ propertyKey)
.header(
'Content-Type'
,
'application/json'
)
.body(propertyValue)
.asString()
so you have to actually point to specific issue property via REST notation
A full example description is here.
Sorry if not very relevant to your case, but still, might be helpful.
Cheers,
Pavel
thanks
but i's not work at for Jira Version (not cloud)
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.