I have a custom single select field 'Bug State' with 3 options.
I want to use a script to update this field according to changes in the bug issue Status.
If Bug Status is 'Open' or 'In Progress' the 'Bug State' value = Open.
If Bug Status is 'Resolved' then the 'Bug State' value = Resolved.
If Bug Status is 'Blocked' or 'Closed' then the 'Bug State' value = Closed.
Using Jira Data Center.
Pls help,
Thanks