我想使用Power BI JIRA服务来分析特定项目。 当我在服务中配置URL和身份验证时,它会获取组织中所有项目的数据集。 目前我正在使用这种格式的网址 https://organisationname.jira.com 有什么方法可以配置URL,以便我只获取一个项目的详细信息吗?
答案 0 :(得分:1)
我有同样的问题,不得不向@Nick Chopper添加一些步骤以使其正常工作,但我在初始JIRA实例上使用该模板。步骤: -
第1步:添加' projectKey'带有类型为文本的参数,并在当前值字段中输入项目密钥。
步骤2:将projectKey参数添加到FetchPages函数,并将此参数传递给FetchPage函数。
let
FetchPages = (url as text, pageSize as number, projectKey as text) =>
let
Source = GenerateByPage(
(previous) =>
let
skipRows = if previous = null then 0 else Value.Metadata(previous)[skipRows],
totalItems = if previous = null then 0 else Value.Metadata(previous)[total],
table = if previous = null or Table.RowCount(previous) = pageSize then
FetchPage(url, pageSize, skipRows, projectKey)
else null
in table,
type table [Column1])
in
Source
in
FetchPages
步骤3:在FetchPage函数中添加projectKey参数,并将projectKey作为jql查询传递给JIRA Web服务。
let
FetchPage = (url as text, pageSize as number, skipRows as number, projectKey as text) as table =>
let
//Here is where you run the code that will return a single page
contents = Web.Contents(URL&"/rest/api/2/search",[Query = [maxResults= Text.From(pageSize), startAt = Text.From(skipRows), jql = "project="&projectKey]]),
json = Json.Document(contents),
Value = json[issues],
table = Table.FromList(Value, Splitter.SplitByNothing(), null, null, ExtraValues.Error)
in
table meta [skipRows = skipRows + pageSize, total = 500]
in
FetchPage
第4步:刷新数据
答案 1 :(得分:0)
使用power bi content pack创建项目关键参数,并在当前值中输入项目键。项目键是用于预先确定问题类型编号的文本条。例如ZZZ-1096。然后将其添加到fetchpages函数中
像这样= (url as text, pageSize as number, optional projectKey as text) =>
let
Source = GenerateByPage(
(previous) =>
let
skipRows = if previous = null then 0 else Value.Metadata(previous)[skipRows],
这就是here的电源双连接器。