Commit 87d9e0d88c2d3a1587968ba670e263a25c372986

Authored by Dmitriy Zaporozhets
1 parent 6f32ccf4

Issue show page restyled

Showing 1 changed file with 42 additions and 35 deletions   Show diff stats
app/views/issues/show.html.haml
1 -.issue-show-holder.ui-box  
2 - %h3  
3 - = "Issue ##{@issue.id}"  
4 - .right  
5 - - if @issue.closed  
6 - %span.tag.closed Closed  
7 - - else  
8 - %span.tag.open Open  
9 -  
10 - .data  
11 - %p= @issue.title 1 +%div
  2 + %span.entity-info
  3 + - if can?(current_user, :admin_project, @project) || @issue.author == current_user
  4 + = link_to edit_project_issue_path(@project, @issue) do
  5 + .entity-button
  6 + Edit Issue
  7 + %i
  8 + = image_tag gravatar_icon(@issue.author_email), :class => "left", :width => 40, :style => "padding-right:5px;"
  9 + %span.commit-title
  10 + %strong
  11 + = "Issue ##{@issue.id}:"
  12 + %span.commit-author
  13 + %strong
  14 + = link_to project_team_member_path(@project, @project.team_member_by_id(@issue.author.id)) do
  15 + %span.author= @issue.author_name
  16 + - if @issue.author != @issue.assignee
  17 + →
  18 + = link_to project_team_member_path(@project, @project.team_member_by_id(@issue.assignee.id)) do
  19 + %span.author= @issue.assignee_name
  20 +  
12 21
13 - - if @issue.author == @issue.assignee  
14 - = image_tag gravatar_icon(@issue.assignee_email), :width => 20, :style => "padding:0 5px;"  
15 - = @issue.assignee_name  
16 - - else  
17 - = image_tag gravatar_icon(@issue.author_email), :width => 20, :style => "padding:0 5px;"  
18 - = @issue.author_name  
19 - →  
20 - = image_tag gravatar_icon(@issue.assignee_email), :width => 20, :style => "padding:0 5px;"  
21 - = @issue.assignee_name  
22 - .right  
23 - %cite.cgray= @issue.created_at.stamp("21 Aug 2011, 11:15pm")  
24 - .clear 22 +  
  23 + = @issue.created_at.stamp("Aug 21, 2011 9:23pm")
25 24
26 - .buttons  
27 - - if can? current_user, :write_issue, @issue  
28 - - if @issue.closed  
29 - = link_to 'Reopen', project_issue_path(@project, @issue, :issue => {:closed => false }, :status_only => true), :method => :put, :class => "grey-button"  
30 - - else  
31 - = link_to 'Close', project_issue_path(@project, @issue, :issue => {:closed => true }, :status_only => true), :method => :put, :class => "grey-button"  
32 - .right  
33 - = link_to 'Edit', edit_project_issue_path(@project, @issue), :class => "grey-button positive" 25 + %hr
  26 + %br
  27 + %h3
  28 + = simple_format @issue.title
34 29
35 .clear 30 .clear
36 %br 31 %br
37 %br 32 %br
38 33
39 -.issue_notes= render "notes/notes"  
40 -.loading{ :style => "display:none;"}  
41 - %center= image_tag "ajax-loader.gif"  
42 -.clear 34 +.merge-tabs
  35 + = link_to "#notes", :class => "merge-notes-tab active tab" do
  36 + %span
  37 + Notes
  38 + .right
  39 + - if @issue.closed
  40 + = link_to 'Reopen', project_issue_path(@project, @issue, :issue => {:closed => false }, :status_only => true), :method => :put, :class => "red-button"
  41 + - else
  42 + = link_to 'Close', project_issue_path(@project, @issue, :issue => {:closed => true }, :status_only => true), :method => :put, :class => "positive-button"
  43 +
  44 +.merge-request-notes
  45 + .issue_notes= render "notes/notes"
  46 + .loading{ :style => "display:none;"}
  47 + %center= image_tag "ajax-loader.gif"
  48 + .clear
  49 +