Hi,
I’m trying to extract a new field that returns the assignee group, based on the status of the ticket.
This is mi code:
if ((issue.fields.status.name=="Pending at III Level") || (issue.fields.status.name=="In working at III Level") || (issue.fields.status.name=="Development") || (issue.fields.status.name=="Comment Waiting"))
{return issue.fields.customfield_10613}
else if ((issue.fields.status.name=="Pending at II Level") || (issue.fields.status.name=="In working at II Level") || (issue.fields.status.name=="Suspended"))
{return issue.fields.customfield_10612}
else if ((issue.fields.status.name=="Submitted") || (issue.fields.status.name=="In working at I Level") || (issue.fields.status.name=="Waiting for Comment") || (issue.fields.status.name=="Closed"))
{return "First_Level"}
else {return "Stato non mappato";}
I obtain this result, in which the value enclosed by the square brackets is present
Is there a way to extract only the value between quotes?
I tried with .value but it doesn’t work
I need it because then I would have to create a new field that is based on the value of this one and with the square brackets it is not recognized as a value.
Thanks in advance