Hi,
I have 3 tabs that I display and out of the 3 tabs, 2 tabs are disabled by default using the following script in Behavior.
disableTab(1)
disableTab(2)
Now, I want to enable Tab 1 from the Behavior ScriptRunner only if the workflow status is "Ready". Here is the below code:
import com.atlassian.jira.component.ComponentAccessor
def issue = ComponentAccessor.getIssueManager().getIssueObject(underlyingIssue.getKey())
if (issue.status.name == "Ready" ) {
switchTab(1)
disableTab(2)
} else {
disableTab(1)
disableTab(2)
}
The above code does not work.
Can anyone assist?
Thanks,
KP