2013-06-23 16:47:22 +00:00
|
|
|
= render "projects/commits/head"
|
2012-02-06 20:32:04 +00:00
|
|
|
|
2013-07-13 05:45:48 +00:00
|
|
|
%h3.page-title
|
2012-02-06 20:32:04 +00:00
|
|
|
Compare View
|
|
|
|
|
2012-09-26 03:13:19 +00:00
|
|
|
= render "form"
|
2012-02-06 20:32:04 +00:00
|
|
|
|
2012-09-21 08:22:53 +00:00
|
|
|
- if @commits.present?
|
2012-07-25 18:45:53 +00:00
|
|
|
%div.ui-box
|
2013-07-13 17:36:21 +00:00
|
|
|
.title
|
2013-01-08 10:23:33 +00:00
|
|
|
Commits (#{@commits.count})
|
2014-02-05 13:54:51 +00:00
|
|
|
- if @commits.size > MergeRequestDiff::COMMITS_SAFE_SIZE
|
|
|
|
%ul.well-list
|
|
|
|
- Commit.decorate(@commits.first(MergeRequestDiff::COMMITS_SAFE_SIZE)).each do |commit|
|
|
|
|
= render "projects/commits/inline_commit", commit: commit, project: @project
|
|
|
|
%li.warning-row.unstyled
|
|
|
|
other #{@commits.size - MergeRequestDiff::COMMITS_SAFE_SIZE} commits hidden to prevent performance issues.
|
|
|
|
- else
|
|
|
|
%ul.well-list= render Commit.decorate(@commits), project: @project
|
2012-02-06 20:32:04 +00:00
|
|
|
|
2014-02-05 14:09:13 +00:00
|
|
|
%h4 Diff
|
|
|
|
- if @diffs.present?
|
2013-07-30 10:35:33 +00:00
|
|
|
= render "projects/commits/diffs", diffs: @diffs, project: @project
|
2014-02-05 14:09:13 +00:00
|
|
|
- elsif @commits.size > MergeRequestDiff::COMMITS_SAFE_SIZE
|
|
|
|
.alert.alert-warning
|
|
|
|
%p
|
|
|
|
%strong Warning! This comparison includes more than #{MergeRequestDiff::COMMITS_SAFE_SIZE} commits.
|
|
|
|
%p To preserve performance the line diff is not shown.
|
|
|
|
|
2013-09-12 17:15:10 +00:00
|
|
|
- else
|
|
|
|
.light-well
|
|
|
|
%center
|
|
|
|
%h4
|
|
|
|
There isn't anything to compare.
|
|
|
|
%p.slead
|
|
|
|
- if params[:to] == params[:from]
|
|
|
|
You'll need to use different branch names to get a valid comparison.
|
|
|
|
- else
|
|
|
|
%span.label-branch #{params[:from]}
|
|
|
|
and
|
|
|
|
%span.label-branch #{params[:to]}
|
|
|
|
are the same.
|