You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
Next: Root
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
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)
}