gitlabhq/app/views/merge_requests/show.html.haml
2012-02-05 12:58:02 +02:00

72 lines
2.2 KiB
Plaintext

%h3
= "Merge Request ##{@merge_request.id}:"
 
%span.label= @merge_request.source_branch
→
%span.label= @merge_request.target_branch
%small
created at
= @merge_request.created_at.stamp("Aug 21, 2011")
%span.right
- if can?(current_user, :admin_project, @project) || @merge_request.author == current_user
- if @merge_request.closed
= link_to 'Reopen', project_merge_request_path(@project, @merge_request, :merge_request => {:closed => false }, :status_only => true), :method => :put, :class => "btn"
- else
= link_to 'Close', project_merge_request_path(@project, @merge_request, :merge_request => {:closed => true }, :status_only => true), :method => :put, :class => "btn", :title => "Close merge request"
- if can?(current_user, :admin_project, @project) || @merge_request.author == current_user
= link_to edit_project_merge_request_path(@project, @merge_request), :class => "btn small" do
Edit
%hr
- if @merge_request.closed
.alert-message.error Closed
- else
.alert-message.success Open
%div.well
%div
%cite.cgray Created by
= image_tag gravatar_icon(@merge_request.author_email), :width => 16, :class => "lil_av"
%strong.author= link_to_merge_request_author(@merge_request)
%cite.cgray and currently assigned to
= image_tag gravatar_icon(@merge_request.assignee_email), :width => 16, :class => "lil_av"
%strong.author= link_to_merge_request_assignee(@merge_request)
%hr
%div= simple_format @merge_request.title
.tabs
%li.active
= link_to "#notes", :class => "merge-notes-tab tab" do
Notes
%li
= link_to "#commits", "data-url" => commits_project_merge_request_path(@project, @merge_request), :class => "merge-commits-tab tab" do
Commits
%li
= link_to "#diffs", "data-url" => diffs_project_merge_request_path(@project, @merge_request), :class => "merge-diffs-tab tab" do
Diff
%img{:src => "/assets/ajax-loader-facebook.gif", :class => "dashboard-loader"}
.merge-request-notes
.merge_request_notes= render "notes/notes"
.loading{ :style => "display:none;"}
%center= image_tag "ajax-loader.gif"
.clear
.merge-request-commits
.merge-request-diffs
:javascript
$(function(){
MergeRequest.init();
})