Expose votes in merge request api
Signed-off-by: Islam Amer <islam.amer@jollamobile.com>
This commit is contained in:
parent
07437ac3d4
commit
29c807ced3
|
|
@ -20,6 +20,8 @@ Parameters:
|
||||||
"project_id":3,
|
"project_id":3,
|
||||||
"title":"test1",
|
"title":"test1",
|
||||||
"state":"opened",
|
"state":"opened",
|
||||||
|
"upvotes":0,
|
||||||
|
"downvotes":0,
|
||||||
"author":{
|
"author":{
|
||||||
"id":1,
|
"id":1,
|
||||||
"username": "admin",
|
"username": "admin",
|
||||||
|
|
@ -62,6 +64,8 @@ Parameters:
|
||||||
"project_id":3,
|
"project_id":3,
|
||||||
"title":"test1",
|
"title":"test1",
|
||||||
"state":"merged",
|
"state":"merged",
|
||||||
|
"upvotes":0,
|
||||||
|
"downvotes":0,
|
||||||
"author":{
|
"author":{
|
||||||
"id":1,
|
"id":1,
|
||||||
"username": "admin",
|
"username": "admin",
|
||||||
|
|
@ -106,6 +110,8 @@ Parameters:
|
||||||
"project_id":3,
|
"project_id":3,
|
||||||
"title":"test1",
|
"title":"test1",
|
||||||
"state":"opened",
|
"state":"opened",
|
||||||
|
"upvotes":0,
|
||||||
|
"downvotes":0,
|
||||||
"author":{
|
"author":{
|
||||||
"id":1,
|
"id":1,
|
||||||
"username": "admin",
|
"username": "admin",
|
||||||
|
|
@ -152,6 +158,8 @@ Parameters:
|
||||||
"project_id":3,
|
"project_id":3,
|
||||||
"title":"test1",
|
"title":"test1",
|
||||||
"state":"opened",
|
"state":"opened",
|
||||||
|
"upvotes":0,
|
||||||
|
"downvotes":0,
|
||||||
"author":{
|
"author":{
|
||||||
"id":1,
|
"id":1,
|
||||||
"username": "admin",
|
"username": "admin",
|
||||||
|
|
|
||||||
|
|
@ -112,7 +112,7 @@ module API
|
||||||
end
|
end
|
||||||
|
|
||||||
class MergeRequest < Grape::Entity
|
class MergeRequest < Grape::Entity
|
||||||
expose :id, :target_branch, :source_branch, :title, :state
|
expose :id, :target_branch, :source_branch, :title, :state, :upvotes, :downvotes
|
||||||
expose :target_project_id, as: :project_id
|
expose :target_project_id, as: :project_id
|
||||||
expose :author, :assignee, using: Entities::UserBasic
|
expose :author, :assignee, using: Entities::UserBasic
|
||||||
end
|
end
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue