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
66ffa28e
Commit
66ffa28e
authored
Aug 01, 2016
by
Fatih Acet
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove Conflicts tab make it a page instead.
parent
5625e828
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
112 additions
and
114 deletions
+112
-114
app/controllers/projects/merge_requests_controller.rb
app/controllers/projects/merge_requests_controller.rb
+1
-4
app/views/projects/merge_requests/_show.html.haml
app/views/projects/merge_requests/_show.html.haml
+0
-7
app/views/projects/merge_requests/conflicts.haml
app/views/projects/merge_requests/conflicts.haml
+111
-0
app/views/projects/merge_requests/show/_conflicts.html.haml
app/views/projects/merge_requests/show/_conflicts.html.haml
+0
-103
No files found.
app/controllers/projects/merge_requests_controller.rb
View file @
66ffa28e
...
@@ -135,10 +135,7 @@ class Projects::MergeRequestsController < Projects::ApplicationController
...
@@ -135,10 +135,7 @@ class Projects::MergeRequestsController < Projects::ApplicationController
return
render_404
unless
@merge_request
.
cannot_be_merged?
return
render_404
unless
@merge_request
.
cannot_be_merged?
respond_to
do
|
format
|
respond_to
do
|
format
|
format
.
html
do
format
.
html
{
define_discussion_vars
}
define_discussion_vars
render
'show'
end
format
.
json
do
format
.
json
do
begin
begin
...
...
app/views/projects/merge_requests/_show.html.haml
View file @
66ffa28e
...
@@ -61,10 +61,6 @@
...
@@ -61,10 +61,6 @@
=
link_to
diffs_namespace_project_merge_request_path
(
@project
.
namespace
,
@project
,
@merge_request
),
data:
{
target:
'div#diffs'
,
action:
'diffs'
,
toggle:
'tab'
}
do
=
link_to
diffs_namespace_project_merge_request_path
(
@project
.
namespace
,
@project
,
@merge_request
),
data:
{
target:
'div#diffs'
,
action:
'diffs'
,
toggle:
'tab'
}
do
Changes
Changes
%span
.badge
=
@merge_request
.
diff_size
%span
.badge
=
@merge_request
.
diff_size
%li
.conflicts-tab
=
link_to
conflicts_namespace_project_merge_request_path
(
@project
.
namespace
,
@project
,
@merge_request
),
data:
{
target:
'div#conflicts'
,
action:
'conflicts'
,
toggle:
'tab'
}
do
Conflicts
%span
.badge
3
.tab-content
.tab-content
#notes
.notes.tab-pane.voting_notes
#notes
.notes.tab-pane.voting_notes
...
@@ -82,9 +78,6 @@
...
@@ -82,9 +78,6 @@
-
# This tab is always loaded via AJAX
-
# This tab is always loaded via AJAX
#diffs
.diffs.tab-pane
#diffs
.diffs.tab-pane
-
# This tab is always loaded via AJAX
-
# This tab is always loaded via AJAX
#conflicts
.conflicts.tab-pane
-
# This tab is always loaded via AJAX
=
render
'projects/merge_requests/show/conflicts'
.mr-loading-status
.mr-loading-status
=
spinner
=
spinner
...
...
app/views/projects/merge_requests/conflicts.haml
0 → 100644
View file @
66ffa28e
-
page_title
"Merge Conflicts"
,
"
#{
@merge_request
.
title
}
(
#{
@merge_request
.
to_reference
}
"
,
"Merge Requests"
=
render
"projects/merge_requests/show/mr_title"
.merge-request-details.issuable-details
{
data:
{
id:
@merge_request
.
project
.
id
}}
=
render
"projects/merge_requests/show/mr_box"
#conflicts
.loading
{
"v-if"
=>
"isLoading"
}
%i
.fa.fa-spinner.fa-spin
.content-block.oneline-block.files-changed
{
"v-if"
=>
"!isLoading"
}
.inline-parallel-buttons
.btn-group
%a
.btn
{
|
":class"
=>
"{'active': !isParallel}"
,
|
"@click"
=>
"handleViewTypeChange('inline')"
}
Inline
%a
.btn
{
|
":class"
=>
"{'active': isParallel}"
,
|
"@click"
=>
"handleViewTypeChange('parallel')"
}
Side-by-side
.js-toggle-container
.commit-stat-summary
Showing
%strong
.cred
{{conflictsCount}} conflicts
for
%strong
{{conflictsData.source_branch}}
into
%strong
{{conflictsData.target_branch}}
.files-wrapper
{
"v-if"
=>
"!isLoading"
}
.files
{
"v-if"
=>
"isParallel"
}
.diff-file.file-holder.conflict.parallel-view
{
"v-for"
=>
"file in conflictsData.files"
}
.file-title
%span
{{file.new_path}}
.file-actions
%a
.btn.btn-sm
View file @{{conflictsData.shortCommitSha}}
.diff-content.diff-wrap-lines
.diff-wrap-lines.code.file-content.js-syntax-highlight.white
%table
{
"v-for"
=>
"(key, group) in file.parallelLines"
}
%tr
.line_holder.parallel
{
"v-for"
=>
"line in group"
,
|
":class"
=>
"{ |
'head': line.isHead, |
'origin': line.isOrigin, |
'match': line.hasMatch, |
'selected': line.isSelected, |
'unselected': line.isUnselected }"
}
%template
{
"v-if"
=>
"line.isHeader"
}
%td
.diff-line-num.header
%td
.line_content.header
%strong
{{line.richText}}
%button
.btn
{
"@click"
=>
"handleSelected(line.id, line.section)"
}
Use this
%template
{
"v-if"
=>
"!line.isHeader"
}
%td
.diff-line-num.old_line
{{line.lineNumber}}
%td
.line_content
{{{line.richText}}}
.files
{
"v-if"
=>
"!isParallel"
}
.diff-file.file-holder.conflict.inline-view
{
"v-for"
=>
"file in conflictsData.files"
}
.file-title
%span
{{file.new_path}}
.file-actions
%a
.btn.btn-sm
View file @{{conflictsData.shortCommitSha}}
.diff-content.diff-wrap-lines
.diff-wrap-lines.code.file-content.js-syntax-highlight.white
%table
%tr
.line_holder
{
"v-for"
=>
"line in file.inlineLines"
,
|
":class"
=>
"{ |
'head': line.isHead, |
'origin': line.isOrigin, |
'match': line.hasMatch, |
'selected': line.isSelected, |
'unselected': line.isUnselected }"
}
%template
{
"v-if"
=>
"!line.isHeader"
}
%td
.diff-line-num.new_line
%a
{{line.new_line}}
%td
.diff-line-num.old_line
%a
{{line.old_line}}
%td
.line_content
{{{line.richText}}}
%template
{
"v-if"
=>
"line.isHeader"
}
%td
.diff-line-num.header
%td
.diff-line-num.header
%td
.line_content.header
%strong
{{{line.richText}}}
%button
.btn
{
"@click"
=>
"handleSelected(line.id, line.section)"
}
Use this
.content-block.oneline-block.files-changed
%strong
.resolved-count
{{resolvedCount}}
of
%strong
.total-count
{{conflictsCount}}
conflicts have been resolved
.commit-message-container.form-group
.max-width-marker
%textarea
.form-control.js-commit-message
{
":disabled"
=>
"!allResolved"
}
{{{conflictsData.commitMessage}}}
%button
{
type:
'button'
,
class:
'btn btn-success js-submit-button'
,
":disabled"
=>
"!allResolved"
}
Commit conflict resolution
%button
{
type:
'button'
,
class:
'btn btn-cancel'
}
Cancel
app/views/projects/merge_requests/show/_conflicts.html.haml
deleted
100644 → 0
View file @
5625e828
.loading
{
"v-if"
=>
"isLoading"
}
%i
.fa.fa-spinner.fa-spin
.content-block.oneline-block.files-changed
{
"v-if"
=>
"!isLoading"
}
.inline-parallel-buttons
.btn-group
%a
.btn
{
|
":class"
=>
"{'active': !isParallel}"
,
|
"@click"
=>
"handleViewTypeChange('inline')"
}
Inline
%a
.btn
{
|
":class"
=>
"{'active': isParallel}"
,
|
"@click"
=>
"handleViewTypeChange('parallel')"
}
Side-by-side
.js-toggle-container
.commit-stat-summary
Showing
%strong
.cred
{{conflictsCount}} conflicts
for
%strong
{{conflictsData.source_branch}}
into
%strong
{{conflictsData.target_branch}}
.files-wrapper
{
"v-if"
=>
"!isLoading"
}
.files
{
"v-if"
=>
"isParallel"
}
.diff-file.file-holder.conflict.parallel-view
{
"v-for"
=>
"file in conflictsData.files"
}
.file-title
%span
{{file.new_path}}
.file-actions
%a
.btn.btn-sm
View file @{{conflictsData.shortCommitSha}}
.diff-content.diff-wrap-lines
.diff-wrap-lines.code.file-content.js-syntax-highlight.white
%table
{
"v-for"
=>
"(key, group) in file.parallelLines"
}
%tr
.line_holder.parallel
{
"v-for"
=>
"line in group"
,
|
":class"
=>
"{ |
'head': line.isHead, |
'origin': line.isOrigin, |
'match': line.hasMatch, |
'selected': line.isSelected, |
'unselected': line.isUnselected }"
}
%template
{
"v-if"
=>
"line.isHeader"
}
%td
.diff-line-num.header
%td
.line_content.header
%strong
{{line.richText}}
%button
.btn
{
"@click"
=>
"handleSelected(line.id, line.section)"
}
Use this
%template
{
"v-if"
=>
"!line.isHeader"
}
%td
.diff-line-num.old_line
{{line.lineNumber}}
%td
.line_content
{{{line.richText}}}
.files
{
"v-if"
=>
"!isParallel"
}
.diff-file.file-holder.conflict.inline-view
{
"v-for"
=>
"file in conflictsData.files"
}
.file-title
%span
{{file.new_path}}
.file-actions
%a
.btn.btn-sm
View file @{{conflictsData.shortCommitSha}}
.diff-content.diff-wrap-lines
.diff-wrap-lines.code.file-content.js-syntax-highlight.white
%table
%tr
.line_holder
{
"v-for"
=>
"line in file.inlineLines"
,
|
":class"
=>
"{ |
'head': line.isHead, |
'origin': line.isOrigin, |
'match': line.hasMatch, |
'selected': line.isSelected, |
'unselected': line.isUnselected }"
}
%template
{
"v-if"
=>
"!line.isHeader"
}
%td
.diff-line-num.new_line
%a
{{line.new_line}}
%td
.diff-line-num.old_line
%a
{{line.old_line}}
%td
.line_content
{{{line.richText}}}
%template
{
"v-if"
=>
"line.isHeader"
}
%td
.diff-line-num.header
%td
.diff-line-num.header
%td
.line_content.header
%strong
{{{line.richText}}}
%button
.btn
{
"@click"
=>
"handleSelected(line.id, line.section)"
}
Use this
.content-block.oneline-block.files-changed
%strong
.resolved-count
{{resolvedCount}}
of
%strong
.total-count
{{conflictsCount}}
conflicts have been resolved
.commit-message-container.form-group
.max-width-marker
%textarea
.form-control.js-commit-message
{
":disabled"
=>
"!allResolved"
}
{{{conflictsData.commitMessage}}}
%button
{
type:
'button'
,
class:
'btn btn-success js-submit-button'
,
":disabled"
=>
"!allResolved"
}
Commit conflict resolution
%button
{
type:
'button'
,
class:
'btn btn-cancel'
}
Cancel
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