Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Section


도구명jira
버전8.22



Table of Contents


...

CustomFieldManager api 적용

CustomFieldManager api 불러오기

Code Block
languagejava
@ComponentImport
    private final CustomFieldManager customFieldManager;

MutableIssue issue = issueManager.getIssueByCurrentKey(String issueKey);
Collection<CustomField> customFieldList = customFieldManager.getCustomFieldObjectsByName(String customFieldName);
for(CustomField customField : customFieldList){
	Object object = customField.getValue(Issue issue)
}
  • String Type의 issue key를 parameter로 current issue get
  • String Type의 customFieldName을 parameter로 customFieldLIst get
  • CustomFieldList loop로 Collection List의 각 인덱스 value get
  • issue를 parameter로 Object Type의 customFieldValue get
  • Object Type은 Text Type의 value에 적용


Buttom Type Value 조회

Code Block
languagejava
@ComponentImport
    private final CustomFieldManager customFieldManager;

MutableIssue issue = issueManager.getIssueByCurrentKey(String issueKey);
Collection<CustomField> customFieldList = customFieldManager.getCustomFieldObjectsByName(String customFieldName);
for(CustomField customField : customFieldList){
	Object customFields = customField.getValue(issue);
	Option customFields1 = (Option) customFields;
}

...