Skip to content
GitLab
Menu
Why GitLab
Pricing
Contact Sales
Explore
Why GitLab
Pricing
Contact Sales
Explore
Sign in
Get free trial
Primary navigation
Search or go to…
Project
GitLab
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Privacy statement
Keyboard shortcuts
?
What's new
4
Snippets
Groups
Projects
Show more breadcrumbs
GitLab.org
GitLab
Commits
ff21b96d
Commit
ff21b96d
authored
5 years ago
by
Luke Duncalfe
Committed by
Natalia Tepluhina
5 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Expose diff_refs on MergeRequestType
https://gitlab.com/gitlab-org/gitlab-ee/issues/9489
parent
c01f611d
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
app/graphql/types/diff_refs_type.rb
+6
-3
6 additions, 3 deletions
app/graphql/types/diff_refs_type.rb
app/graphql/types/notes/diff_position_base_input_type.rb
+3
-3
3 additions, 3 deletions
app/graphql/types/notes/diff_position_base_input_type.rb
with
9 additions
and
6 deletions
app/graphql/types/diff_refs_type.rb
+
6
−
3
View file @
ff21b96d
# frozen_string_literal: true
module
Types
# rubocop: disable Graphql/AuthorizeTypes
# Types that use DiffRefsType should have their own authorization
class
DiffRefsType
<
BaseObject
graphql_name
'DiffRefs'
field
:
base
_sha
,
GraphQL
::
STRING_TYPE
,
null:
false
field
:
head
_sha
,
GraphQL
::
STRING_TYPE
,
null:
false
field
:start_sha
,
GraphQL
::
STRING_TYPE
,
null:
false
field
:
head
_sha
,
GraphQL
::
STRING_TYPE
,
null:
false
,
description:
'The sha of the head at the time the comment was made'
field
:
base
_sha
,
GraphQL
::
STRING_TYPE
,
null:
false
,
description:
'The merge base of the branch the comment was made on'
field
:start_sha
,
GraphQL
::
STRING_TYPE
,
null:
false
,
description:
'The sha of the branch being compared against'
end
# rubocop: enable Graphql/AuthorizeTypes
end
This diff is collapsed.
Click to expand it.
app/graphql/types/notes/diff_position_base_input_type.rb
+
3
−
3
View file @
ff21b96d
...
...
@@ -5,11 +5,11 @@ module Notes
# rubocop: disable Graphql/AuthorizeTypes
class
DiffPositionBaseInputType
<
BaseInputObject
argument
:head_sha
,
GraphQL
::
STRING_TYPE
,
required:
true
,
description:
copy_field_description
(
Types
::
Notes
::
DiffPosition
Type
,
:head_sha
)
description:
copy_field_description
(
Types
::
DiffRefs
Type
,
:head_sha
)
argument
:base_sha
,
GraphQL
::
STRING_TYPE
,
required:
false
,
description:
copy_field_description
(
Types
::
Notes
::
DiffPosition
Type
,
:base_sha
)
description:
copy_field_description
(
Types
::
DiffRefs
Type
,
:base_sha
)
argument
:start_sha
,
GraphQL
::
STRING_TYPE
,
required:
true
,
description:
copy_field_description
(
Types
::
Notes
::
DiffPosition
Type
,
:start_sha
)
description:
copy_field_description
(
Types
::
DiffRefs
Type
,
:start_sha
)
argument
:paths
,
Types
::
DiffPathsInputType
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment