The Atlassian Community can help you and your team get more value out of Atlassian products and practices.
Hi - I am trying to setup a ticket where original date shows on the ticket create(of the subtask ticket) screen only if the sub-task issue type and the value entered in another custom field are as specified. I keep getting the following errors:
issue.getIssueTypeObject().isSubtask() -- error = cannot find matching method com.onresolve.jira.goroovy.user.FormField#getIssueTypeObject(). Please check if the declared type is right and if the method exists.
if(!issue.getIssueTypeObject().isSubTask())
return -- error = cannot find matching method com.onresolve.jira.goroovy.user.FormField#getIssueTypeObject(). Please check if the declared type is right and if the method exists.
Here is the posted code:
import com.atlassian.jira.issue.Issue
def IssueType = getFieldByName("Campaign")
def issue = getFieldByName("Data Enhancement")
def productField = getFieldByName("Product")
def productFieldValue = productField.getValue()
if(!issue.get("issueType").isSubTask())
return
def originalDueDateField = getFieldByName("Original Due Date")
switch (productFieldValue){
case "Match Analysis":
originalDueDateField.setHidden(false)
break
case "Data Append":
originalDueDateField.setHidden(true)
break
case "Data Feed":
originalDueDateField.setHidden(true)
break
case "Data License":
originalDueDateField.setHidden(true)
break
case "Exposure File":
originalDueDateField.setHidden(true)
break
case "Score Append":
originalDueDateField.setHidden(true)
}
if(!issue.getIssueTypeObject().isSubTask())
return -- error = cannot find matching method com.onresolve.jira.goroovy.user.FormField#getIssueTypeObject(). Please check if the declared type is right and if the method exists.
Here is the posted code:
import com.atlassian.jira.issue.Issue
def IssueType = getFieldByName("Campaign")
def issue = getFieldByName("Data Enhancement")
def productField = getFieldByName("Product")
def productFieldValue = productField.getValue()
if(!issue.get("issueType").isSubTask())
return
def originalDueDateField = getFieldByName("Original Due Date")
switch (productFieldValue){
case "Match Analysis":
originalDueDateField.setHidden(false)
break
case "Data Append":
originalDueDateField.setHidden(true)
break
case "Data Feed":
originalDueDateField.setHidden(true)
break
case "Data License":
originalDueDateField.setHidden(true)
break
case "Exposure File":
originalDueDateField.setHidden(true)
break
case "Score Append":
originalDueDateField.setHidden(true)
}
Hello everyone, Hope everyone is safe! A few months ago we posted an article sharing all the new articles and documentation that we, the AMER Jira Service Management team created. As mentioned ...
Connect with like-minded Atlassian users at free events near you!
Find an eventConnect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.
Host an eventYou're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events