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
dc9474fb
Commit
dc9474fb
authored
May 19, 2017
by
Fatih Acet
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MRWidget: Remove approved from serializer.
parent
ffaccec7
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
3 deletions
+2
-3
app/assets/javascripts/vue_merge_request_widget/ee/stores/mr_widget_store.js
...pts/vue_merge_request_widget/ee/stores/mr_widget_store.js
+2
-2
app/serializers/merge_request_entity.rb
app/serializers/merge_request_entity.rb
+0
-1
No files found.
app/assets/javascripts/vue_merge_request_widget/ee/stores/mr_widget_store.js
View file @
dc9474fb
...
...
@@ -31,7 +31,7 @@ export default class MergeRequestStore extends CEMergeRequestStore {
}
initApprovals
(
data
)
{
this
.
isApproved
=
data
.
a
pproved
||
false
;
this
.
isApproved
=
this
.
isA
pproved
||
false
;
this
.
approvals
=
this
.
approvals
||
null
;
this
.
approvalsPath
=
data
.
approvals_path
||
this
.
approvalsPath
;
this
.
approvalsRequired
=
Boolean
(
this
.
approvalsPath
);
...
...
@@ -40,7 +40,7 @@ export default class MergeRequestStore extends CEMergeRequestStore {
setApprovals
(
data
)
{
this
.
approvals
=
data
;
this
.
approvalsLeft
=
!!
data
.
approvals_left
;
this
.
isApproved
=
data
.
approved
||
!
this
.
approvalsLeft
||
false
;
this
.
isApproved
=
!
this
.
approvalsLeft
||
false
;
this
.
preventMerge
=
this
.
approvalsRequired
&&
this
.
approvalsLeft
;
}
}
app/serializers/merge_request_entity.rb
View file @
dc9474fb
...
...
@@ -21,7 +21,6 @@ class MergeRequestEntity < IssuableEntity
expose
:rebase_commit_sha
expose
:rebase_in_progress?
,
as: :rebase_in_progress
expose
:should_be_rebased?
,
as: :should_be_rebased
expose
:approved?
,
as: :approved
expose
:ff_only_enabled
do
|
merge_request
|
merge_request
.
project
.
merge_requests_ff_only_enabled
end
...
...
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