Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
67ebd3ee
Commit
67ebd3ee
authored
Jul 12, 2021
by
Eulyeon Ko
Committed by
Jan Provaznik
Jul 29, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Expose mergeRequestCounts for Issue GraphQL type
Changelog: changed
parent
769ec6da
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
1 deletion
+5
-1
app/graphql/types/issue_type.rb
app/graphql/types/issue_type.rb
+2
-0
doc/api/graphql/reference/index.md
doc/api/graphql/reference/index.md
+2
-0
spec/graphql/types/issue_type_spec.rb
spec/graphql/types/issue_type_spec.rb
+1
-1
No files found.
app/graphql/types/issue_type.rb
View file @
67ebd3ee
...
...
@@ -60,6 +60,8 @@ module Types
description:
'Number of upvotes the issue has received.'
field
:downvotes
,
GraphQL
::
Types
::
Int
,
null:
false
,
description:
'Number of downvotes the issue has received.'
field
:merge_requests_count
,
GraphQL
::
INT_TYPE
,
null:
false
,
description:
'Number of merge requests that close the issue on merge.'
field
:user_notes_count
,
GraphQL
::
Types
::
Int
,
null:
false
,
description:
'Number of user notes of the issue.'
,
resolver:
Resolvers
::
UserNotesCountResolver
...
...
doc/api/graphql/reference/index.md
View file @
67ebd3ee
...
...
@@ -9080,6 +9080,7 @@ Relationship between an epic and an issue.
|
<a
id=
"epicissueiid"
></a>
`iid`
|
[
`ID!`
](
#id
)
| Internal ID of the issue. |
|
<a
id=
"epicissueiteration"
></a>
`iteration`
|
[
`Iteration`
](
#iteration
)
| Iteration of the issue. |
|
<a
id=
"epicissuelabels"
></a>
`labels`
|
[
`LabelConnection`
](
#labelconnection
)
| Labels of the issue. (see
[
Connections
](
#connections
)
) |
|
<a
id=
"epicissuemergerequestscount"
></a>
`mergeRequestsCount`
|
[
`Int!`
](
#int
)
| Number of merge requests that close the issue on merge. |
|
<a
id=
"epicissuemetricimages"
></a>
`metricImages`
|
[
`[MetricImage!]`
](
#metricimage
)
| Metric images associated to the issue. |
|
<a
id=
"epicissuemilestone"
></a>
`milestone`
|
[
`Milestone`
](
#milestone
)
| Milestone of the issue. |
|
<a
id=
"epicissuemoved"
></a>
`moved`
|
[
`Boolean`
](
#boolean
)
| Indicates if issue got moved from other project. |
...
...
@@ -10153,6 +10154,7 @@ Returns [`VulnerabilitySeveritiesCount`](#vulnerabilityseveritiescount).
|
<a
id=
"issueiid"
></a>
`iid`
|
[
`ID!`
](
#id
)
| Internal ID of the issue. |
|
<a
id=
"issueiteration"
></a>
`iteration`
|
[
`Iteration`
](
#iteration
)
| Iteration of the issue. |
|
<a
id=
"issuelabels"
></a>
`labels`
|
[
`LabelConnection`
](
#labelconnection
)
| Labels of the issue. (see
[
Connections
](
#connections
)
) |
|
<a
id=
"issuemergerequestscount"
></a>
`mergeRequestsCount`
|
[
`Int!`
](
#int
)
| Number of merge requests that close the issue on merge. |
|
<a
id=
"issuemetricimages"
></a>
`metricImages`
|
[
`[MetricImage!]`
](
#metricimage
)
| Metric images associated to the issue. |
|
<a
id=
"issuemilestone"
></a>
`milestone`
|
[
`Milestone`
](
#milestone
)
| Milestone of the issue. |
|
<a
id=
"issuemoved"
></a>
`moved`
|
[
`Boolean`
](
#boolean
)
| Indicates if issue got moved from other project. |
...
...
spec/graphql/types/issue_type_spec.rb
View file @
67ebd3ee
...
...
@@ -15,7 +15,7 @@ RSpec.describe GitlabSchema.types['Issue'] do
it
'has specific fields'
do
fields
=
%i[id iid title description state reference author assignees updated_by participants labels milestone due_date
confidential discussion_locked upvotes downvotes user_notes_count user_discussions_count web_path web_url relative_position
confidential discussion_locked upvotes downvotes
merge_requests_count
user_notes_count user_discussions_count web_path web_url relative_position
emails_disabled subscribed time_estimate total_time_spent human_time_estimate human_total_time_spent closed_at created_at updated_at task_completion_status
design_collection alert_management_alert severity current_user_todos moved moved_to
create_note_email timelogs project_id]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment