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
0
Merge Requests
0
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
Léo-Paul Géneau
gitlab-ce
Commits
6d68923e
Commit
6d68923e
authored
Feb 20, 2013
by
Andrew8xx8
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
human_merge_status replaced by human_merge_status_name
parent
52e0df5c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
2 additions
and
7 deletions
+2
-7
app/controllers/merge_requests_controller.rb
app/controllers/merge_requests_controller.rb
+1
-1
app/models/merge_request.rb
app/models/merge_request.rb
+0
-5
app/views/merge_requests/_show.html.haml
app/views/merge_requests/_show.html.haml
+1
-1
No files found.
app/controllers/merge_requests_controller.rb
View file @
6d68923e
...
@@ -73,7 +73,7 @@ class MergeRequestsController < ProjectResourceController
...
@@ -73,7 +73,7 @@ class MergeRequestsController < ProjectResourceController
if
@merge_request
.
unchecked?
if
@merge_request
.
unchecked?
@merge_request
.
check_if_can_be_merged
@merge_request
.
check_if_can_be_merged
end
end
render
json:
{
merge_status:
@merge_request
.
human_merge_status
}
render
json:
{
merge_status:
@merge_request
.
human_merge_status
_name
}
rescue
Gitlab
::
SatelliteNotExistError
rescue
Gitlab
::
SatelliteNotExistError
render
json:
{
merge_status: :no_satellite
}
render
json:
{
merge_status: :no_satellite
}
end
end
...
...
app/models/merge_request.rb
View file @
6d68923e
...
@@ -85,11 +85,6 @@ class MergeRequest < ActiveRecord::Base
...
@@ -85,11 +85,6 @@ class MergeRequest < ActiveRecord::Base
scope
:cared
,
->
(
user
)
{
where
(
'assignee_id = :user OR author_id = :user'
,
user:
user
.
id
)
}
scope
:cared
,
->
(
user
)
{
where
(
'assignee_id = :user OR author_id = :user'
,
user:
user
.
id
)
}
scope
:by_milestone
,
->
(
milestone
)
{
where
(
"milestone_id = :milestone_id"
,
milestone_id:
milestone
)
}
scope
:by_milestone
,
->
(
milestone
)
{
where
(
"milestone_id = :milestone_id"
,
milestone_id:
milestone
)
}
# DEPRECATED: Please use human_merge_status_name instead
def
human_merge_status
human_merge_status_name
end
def
validate_branches
def
validate_branches
if
target_branch
==
source_branch
if
target_branch
==
source_branch
errors
.
add
:base
,
"You can not use same branch for source and target branches"
errors
.
add
:base
,
"You can not use same branch for source and target branches"
...
...
app/views/merge_requests/_show.html.haml
View file @
6d68923e
...
@@ -32,7 +32,7 @@
...
@@ -32,7 +32,7 @@
check_enable
:
#{
@merge_request
.
unchecked?
?
"true"
:
"false"
}
,
check_enable
:
#{
@merge_request
.
unchecked?
?
"true"
:
"false"
}
,
url_to_ci_check
:
"
#{
ci_status_project_merge_request_path
(
@project
,
@merge_request
)
}
"
,
url_to_ci_check
:
"
#{
ci_status_project_merge_request_path
(
@project
,
@merge_request
)
}
"
,
ci_enable
:
#{
@project
.
gitlab_ci?
?
"true"
:
"false"
}
,
ci_enable
:
#{
@project
.
gitlab_ci?
?
"true"
:
"false"
}
,
current_status
:
"
#{
@merge_request
.
human_merge_status
}
"
,
current_status
:
"
#{
@merge_request
.
human_merge_status
_name
}
"
,
action
:
"
#{
controller
.
action_name
}
"
action
:
"
#{
controller
.
action_name
}
"
});
});
});
});
...
...
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