Hi All,
I am using below code to access JIRA issues. I am able to fetch all the fields except for custom fields such as Business Analyst, Business Sponsor Function etc:
library(JirAgileR, quietly = T)
library(knitr, quietly = T)
library(dplyr, quietly = T)
if (is.null(JIRABaseURL)) JIRABaseURL
if (is.null(username)) username
if (is.null(password)) password
fields1<-get_jira_issues(domain = JIRABaseURL,
username = username,
password = password,
jql_query = "project in('My Project')",
fields = c('duedate', 'updateddate', 'components'),
maxResults = 50,
verbose = FALSE,
as.data.frame = TRUE)
How can I fetch custom fields using JirAgileR
I figured out the solution.
custom fields can be fetched using customfield_12345 keyword where 12345 is the id of the custom field.
I managed to find it using inspect elements under developer tools in the browser.
Below is the code snippet of the element where i managed to find the custom field details
<th class="colHeaderLink sortable headerrow-customfield_12345" rel="customfield_12345:ASC" data-id="customfield_12345" onclick="window.document.location='/issues/?jql=ORDER%20BY%20%22customfield_12345%22%20ASC'">
<span title="Sort By Business sponsor">Business sponsor</span>
</th>
below is the code for fetching the custom field:
library(JirAgileR, quietly = T)
library(knitr, quietly = T)
library(dplyr, quietly = T)
if (is.null(JIRABaseURL)) JIRABaseURL
if (is.null(username)) username
if (is.null(password)) password
fields1<-get_jira_issues(domain = JIRABaseURL,
username = username,
password = password,
jql_query = "project in('My Project')",
fields = c('duedate', 'updateddate', 'components', 'customfield_12345'),
maxResults = 50,
verbose = FALSE,
as.data.frame = TRUE)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.