Return Issue#iid instead of id when listing issues
This commit is contained in:
parent
c14ac83575
commit
a8b2d7f380
2 changed files with 3 additions and 3 deletions
|
@ -7,7 +7,7 @@ class Projects::BoardIssuesController < Projects::ApplicationController
|
||||||
issues = Boards::Issues::ListService.new(project, current_user, filter_params).execute
|
issues = Boards::Issues::ListService.new(project, current_user, filter_params).execute
|
||||||
issues = issues.page(params[:page])
|
issues = issues.page(params[:page])
|
||||||
|
|
||||||
render json: issues.as_json(only: [:id, :title, :confidential], include: { labels: { only: [:id, :title, :color] } })
|
render json: issues.as_json(only: [:iid, :title, :confidential], include: { labels: { only: [:id, :title, :color] } })
|
||||||
end
|
end
|
||||||
|
|
||||||
def update
|
def update
|
||||||
|
|
4
spec/fixtures/api/schemas/issue.json
vendored
4
spec/fixtures/api/schemas/issue.json
vendored
|
@ -1,12 +1,12 @@
|
||||||
{
|
{
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"required" : [
|
"required" : [
|
||||||
"id",
|
"iid",
|
||||||
"title",
|
"title",
|
||||||
"confidential"
|
"confidential"
|
||||||
],
|
],
|
||||||
"properties" : {
|
"properties" : {
|
||||||
"id": { "type": "integer" },
|
"iid": { "type": "integer" },
|
||||||
"title": { "type": "string" },
|
"title": { "type": "string" },
|
||||||
"confidential": { "type": "boolean" },
|
"confidential": { "type": "boolean" },
|
||||||
"labels": {
|
"labels": {
|
||||||
|
|
Loading…
Reference in a new issue