2011-12-13 19:40:45 +01:00
|
|
|
%div
|
|
|
|
%span.entity-info
|
|
|
|
- if can?(current_user, :admin_project, @project) || @merge_request.author == current_user
|
|
|
|
= link_to edit_project_merge_request_path(@project, @merge_request) do
|
|
|
|
.entity-button
|
|
|
|
Edit Merge Request
|
|
|
|
%i
|
|
|
|
= image_tag gravatar_icon(@merge_request.author_email), :class => "left", :width => 40, :style => "padding-right:5px;"
|
|
|
|
%span.commit-title
|
|
|
|
%strong
|
|
|
|
= "Merge Request ##{@merge_request.id}:"
|
|
|
|
|
|
|
|
.tag.commit.inline= @merge_request.source_branch
|
2011-11-28 08:39:43 +01:00
|
|
|
→
|
2011-12-13 19:40:45 +01:00
|
|
|
.tag.commit.inline= @merge_request.target_branch
|
|
|
|
%span.commit-author
|
|
|
|
%strong
|
2011-12-13 22:24:31 +01:00
|
|
|
= link_to project_team_member_path(@project, @project.team_member_by_id(@merge_request.author.id)) do
|
|
|
|
%span.author= @merge_request.author_name
|
2011-12-13 19:40:45 +01:00
|
|
|
→
|
2011-12-13 22:24:31 +01:00
|
|
|
= link_to project_team_member_path(@project, @project.team_member_by_id(@merge_request.assignee.id)) do
|
|
|
|
%span.author= @merge_request.assignee_name
|
2011-11-28 08:39:43 +01:00
|
|
|
|
2011-12-13 19:40:45 +01:00
|
|
|
|
|
|
|
|
|
|
|
= @merge_request.created_at.stamp("Aug 21, 2011 9:23pm")
|
|
|
|
|
|
|
|
%hr
|
2011-12-13 22:24:31 +01:00
|
|
|
%br
|
|
|
|
%h3
|
|
|
|
= simple_format @merge_request.title
|
2011-11-28 08:39:43 +01:00
|
|
|
|
|
|
|
.clear
|
|
|
|
%br
|
|
|
|
%br
|
|
|
|
|
2011-12-13 19:40:45 +01:00
|
|
|
.merge-tabs
|
2011-12-13 22:24:31 +01:00
|
|
|
= link_to "#notes", :class => "merge-notes-tab active tab" do
|
|
|
|
%span
|
|
|
|
Notes
|
|
|
|
= link_to "#commits", "data-url" => commits_project_merge_request_path(@project, @merge_request), :class => "merge-commits-tab tab" do
|
|
|
|
%span
|
|
|
|
Commits
|
|
|
|
= link_to "#diffs", "data-url" => diffs_project_merge_request_path(@project, @merge_request), :class => "merge-diffs-tab tab" do
|
|
|
|
%span
|
|
|
|
Diff
|
|
|
|
|
2011-12-13 19:40:45 +01:00
|
|
|
- if can?(current_user, :admin_project, @project) || @merge_request.author == current_user
|
|
|
|
.right
|
|
|
|
- if @merge_request.closed
|
2011-12-13 22:24:31 +01:00
|
|
|
= link_to 'Reopen', project_merge_request_path(@project, @merge_request, :merge_request => {:closed => false }, :status_only => true), :method => :put, :class => "red-button"
|
2011-12-13 19:40:45 +01:00
|
|
|
- else
|
2011-12-13 22:24:31 +01:00
|
|
|
= link_to 'Close', project_merge_request_path(@project, @merge_request, :merge_request => {:closed => true }, :status_only => true), :method => :put, :class => "positive-button", :title => "Close merge request"
|
2011-12-13 09:07:52 +01:00
|
|
|
%img{:src => "/assets/ajax-loader-facebook.gif", :class => "dashboard-loader"}
|
|
|
|
|
|
|
|
.merge-request-notes
|
|
|
|
.issue_notes= render "notes/notes"
|
|
|
|
.loading{ :style => "display:none;"}
|
|
|
|
%center= image_tag "ajax-loader.gif"
|
|
|
|
.clear
|
|
|
|
|
|
|
|
.merge-request-commits
|
|
|
|
.merge-request-diffs
|
2011-11-28 21:16:57 +01:00
|
|
|
|
|
|
|
|
|
|
|
:javascript
|
|
|
|
$(function(){
|
2011-12-13 09:07:52 +01:00
|
|
|
MergeRequest.init();
|
2011-11-28 21:16:57 +01:00
|
|
|
})
|