JIRA 扩展 = 变更日志不工作
JIRA expand = changelog not working
我正在尝试使用以下 jql 在 jira 中查询数据:
$jql_options = array(
"jql" => $jql,
"startAt" => 0,
"maxResults" => 1,
"validateQuery" => false,
"fields" => array(
"summary",
"status",
"assignee"
),
"expand" => "changelog"
);
我收到这个错误:
string(282) "{"errorMessages":["Can not deserialize instance of java.util.ArrayList out of VALUE_STRING token\n at [Source: org.apache.catalina.connector.CoyoteInputStream@464d8928; line: 1, column: 2] (through reference chain: com.atlassian.jira.rest.v2.search.SearchRequestBean[\"expand\"])"]}"
我知道 "expand" => "changelog" 是个错误,但在他们的网站上,他们提出了一个像我这样的请求表示。
你能给我一些建议吗? :)
我好像读错了其余 api 文档。
"expand" 选项仅在获取请求中可用。
我在 url + "&expand=changelog" 中附加了 jql 数据,我在 post!
中发送了其他选项
$jql_options = array(
"startAt" => 0,
"maxResults" => 1,
"validateQuery" => false,
"fields" => array(
"key"
)
);
$data = json_encode($jql_options);
$options = array(
CURLOPT_URL => $this->jiraURL . "/rest/api/latest/search?jql=" .urlencode($jql) . "&expand=changelog",
CURLOPT_HTTPHEADER => array(
'Authorization: Basic ' . base64_encode($this->username.":".$this->password),
'Content-type: application/json') ,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POSTFIELDS => $data
);
我正在尝试使用以下 jql 在 jira 中查询数据:
$jql_options = array(
"jql" => $jql,
"startAt" => 0,
"maxResults" => 1,
"validateQuery" => false,
"fields" => array(
"summary",
"status",
"assignee"
),
"expand" => "changelog"
);
我收到这个错误:
string(282) "{"errorMessages":["Can not deserialize instance of java.util.ArrayList out of VALUE_STRING token\n at [Source: org.apache.catalina.connector.CoyoteInputStream@464d8928; line: 1, column: 2] (through reference chain: com.atlassian.jira.rest.v2.search.SearchRequestBean[\"expand\"])"]}"
我知道 "expand" => "changelog" 是个错误,但在他们的网站上,他们提出了一个像我这样的请求表示。
你能给我一些建议吗? :)
我好像读错了其余 api 文档。
"expand" 选项仅在获取请求中可用。
我在 url + "&expand=changelog" 中附加了 jql 数据,我在 post!
中发送了其他选项 $jql_options = array(
"startAt" => 0,
"maxResults" => 1,
"validateQuery" => false,
"fields" => array(
"key"
)
);
$data = json_encode($jql_options);
$options = array(
CURLOPT_URL => $this->jiraURL . "/rest/api/latest/search?jql=" .urlencode($jql) . "&expand=changelog",
CURLOPT_HTTPHEADER => array(
'Authorization: Basic ' . base64_encode($this->username.":".$this->password),
'Content-type: application/json') ,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POSTFIELDS => $data
);