1
這裏例如如何獲得關於這個問題的評論的數量
import com.atlassian.jira.ComponentManager
def commentManager = ComponentManager.getInstance().
getCommentManager()
def numberOfComments = commentManager.getComments(issue).size()
return numberOfComments ? numberOfComments as Double : null
但現在的ComponentManager已經過時?並且我嘗試:
import com.atlassian.jira.component.ComponentAccessor
def commentManager = ComponentAccessor.commentManager
def numberOfComment = commentManager.getComments(issue).size()
但是,如何獲取應用的特定項目? Simmilary getInstance()。
你的變量名是** **非常怪異...'ComponentManager's沒有*「CommentManager」 * S,這並不甚至使任何意義,是非常誤導...只是說 – specializt
看看這裏 http://stackoverflow.com/questions/35348346/getting-issue-comments-jira-python – SgtDroelf