show.rhtml
128 lines
| 5.9 KiB
| text/html+ruby
|
RhtmlLexer
|
r330 | <div class="contextual"> | ||
|
r1591 | <%= link_to_if_authorized(l(:button_update), {:controller => 'issues', :action => 'edit', :id => @issue }, :onclick => 'showAndScrollTo("update", "notes"); return false;', :class => 'icon icon-edit', :accesskey => accesskey(:edit)) %> | ||
|
r686 | <%= link_to_if_authorized l(:button_log_time), {:controller => 'timelog', :action => 'edit', :issue_id => @issue}, :class => 'icon icon-time' %> | ||
<%= watcher_tag(@issue, User.current) %> | ||||
|
r1066 | <%= link_to_if_authorized l(:button_copy), {:controller => 'issues', :action => 'new', :project_id => @project, :copy_from => @issue }, :class => 'icon icon-copy' %> | ||
|
r1116 | <%= link_to_if_authorized l(:button_move), {:controller => 'issues', :action => 'move', :id => @issue }, :class => 'icon icon-move' %> | ||
|
r686 | <%= link_to_if_authorized l(:button_delete), {:controller => 'issues', :action => 'destroy', :id => @issue}, :confirm => l(:text_are_you_sure), :method => :post, :class => 'icon icon-del' %> | ||
|
r330 | </div> | ||
|
r2 | |||
|
r736 | <h2><%= @issue.tracker.name %> #<%= @issue.id %></h2> | ||
|
r899 | <div class="issue <%= "status-#{@issue.status.position} priority-#{@issue.priority.position}" %>"> | ||
|
r1960 | <%= gravatar(@issue.author.mail, :size => "64") %> | ||
|
r736 | <h3><%=h @issue.subject %></h3> | ||
|
r720 | <p class="author"> | ||
|
r721 | <%= authoring @issue.created_on, @issue.author %>. | ||
|
r1329 | <%= l(:label_updated_time, distance_of_time_in_words(Time.now, @issue.updated_on)) + '.' if @issue.created_on != @issue.updated_on %> | ||
|
r720 | </p> | ||
|
r736 | |||
|
r330 | <table width="100%"> | ||
<tr> | ||||
|
r1960 | <td style="width:15%" class="status"><b><%=l(:field_status)%>:</b></td><td style="width:35%" class="status status-<%= @issue.status.name %>"><%= @issue.status.name %></td> | ||
<td style="width:15%" class="start-date"><b><%=l(:field_start_date)%>:</b></td><td style="width:35%"><%= format_date(@issue.start_date) %></td> | ||||
|
r330 | </tr> | ||
<tr> | ||||
|
r1960 | <td class="priority"><b><%=l(:field_priority)%>:</b></td><td class="priority priority-<%= @issue.priority.name %>"><%= @issue.priority.name %></td> | ||
<td class="due-date"><b><%=l(:field_due_date)%>:</b></td><td class="due-date"><%= format_date(@issue.due_date) %></td> | ||||
|
r330 | </tr> | ||
<tr> | ||||
|
r1960 | <td class="assigned-to"><b><%=l(:field_assigned_to)%>:</b></td><td><%= gravatar(@issue.assigned_to.mail, :size => "24") %><%= @issue.assigned_to ? link_to_user(@issue.assigned_to) : "-" %></td> | ||
<td class="progress"><b><%=l(:field_done_ratio)%>:</b></td><td class="progress"><%= progress_bar @issue.done_ratio, :width => '80px', :legend => "#{@issue.done_ratio}%" %></td> | ||||
|
r330 | </tr> | ||
<tr> | ||||
|
r1960 | <td class="category"><b><%=l(:field_category)%>:</b></td><td><%=h @issue.category ? @issue.category.name : "-" %></td> | ||
|
r720 | <% if User.current.allowed_to?(:view_time_entries, @project) %> | ||
|
r1960 | <td class="spent-time"><b><%=l(:label_spent_time)%>:</b></td> | ||
<td class="spent-hours"><%= @issue.spent_hours > 0 ? (link_to lwr(:label_f_hour, @issue.spent_hours), {:controller => 'timelog', :action => 'details', :project_id => @project, :issue_id => @issue}, :class => 'icon icon-time') : "-" %></td> | ||||
|
r720 | <% end %> | ||
</tr> | ||||
<tr> | ||||
|
r1960 | <td class="fixed-version"><b><%=l(:field_fixed_version)%>:</b></td><td><%= @issue.fixed_version ? link_to_version(@issue.fixed_version) : "-" %></td> | ||
|
r720 | <% if @issue.estimated_hours %> | ||
|
r1960 | <td class="estimated-hours"><b><%=l(:field_estimated_hours)%>:</b></td><td><%= lwr(:label_f_hour, @issue.estimated_hours) %></td> | ||
|
r720 | <% end %> | ||
|
r330 | </tr> | ||
<tr> | ||||
|
r1578 | <% n = 0 -%> | ||
<% @issue.custom_values.each do |value| -%> | ||||
<td valign="top"><b><%=h value.custom_field.name %>:</b></td><td valign="top"><%= simple_format(h(show_value(value))) %></td> | ||||
|
r330 | <% n = n + 1 | ||
if (n > 1) | ||||
n = 0 %> | ||||
</tr><tr> | ||||
<%end | ||||
end %> | ||||
</tr> | ||||
|
r1785 | <%= call_hook(:view_issues_show_details_bottom, :issue => @issue) %> | ||
|
r330 | </table> | ||
<hr /> | ||||
|
r470 | |||
|
r1466 | <div class="contextual"> | ||
|
r1772 | <%= link_to_remote_if_authorized l(:button_quote), { :url => {:action => 'reply', :id => @issue} }, :class => 'icon icon-comment' %> | ||
|
r1466 | </div> | ||
|
r751 | <p><strong><%=l(:field_description)%></strong></p> | ||
|
r1022 | <div class="wiki"> | ||
|
r884 | <%= textilizable @issue, :description, :attachments => @issue.attachments %> | ||
|
r1022 | </div> | ||
|
r330 | |||
|
r751 | <% if @issue.attachments.any? %> | ||
<%= link_to_attachments @issue.attachments, :delete_url => (authorize_for('issues', 'destroy_attachment') ? {:controller => 'issues', :action => 'destroy_attachment', :id => @issue} : nil) %> | ||||
<% end %> | ||||
|
r503 | <% if authorize_for('issue_relations', 'new') || @issue.relations.any? %> | ||
|
r736 | <hr /> | ||
<div id="relations"> | ||||
|
r503 | <%= render :partial => 'relations' %> | ||
</div> | ||||
<% end %> | ||||
|
r1711 | <% if User.current.allowed_to?(:add_issue_watchers, @project) || | ||
(@issue.watchers.any? && User.current.allowed_to?(:view_issue_watchers, @project)) %> | ||||
<hr /> | ||||
<div id="watchers"> | ||||
<%= render :partial => 'watchers/watchers', :locals => {:watched => @issue} %> | ||||
</div> | ||||
<% end %> | ||||
|
r663 | </div> | ||
|
r736 | |||
|
r1071 | <% if @issue.changesets.any? && User.current.allowed_to?(:view_changesets, @project) %> | ||
<div id="issue-changesets"> | ||||
<h3><%=l(:label_associated_revisions)%></h3> | ||||
<%= render :partial => 'changesets', :locals => { :changesets => @issue.changesets} %> | ||||
</div> | ||||
<% end %> | ||||
|
r610 | <% if @journals.any? %> | ||
|
r736 | <div id="history"> | ||
|
r610 | <h3><%=l(:label_history)%></h3> | ||
|
r330 | <%= render :partial => 'history', :locals => { :journals => @journals } %> | ||
</div> | ||||
|
r593 | <% end %> | ||
|
r1179 | <div style="clear: both;"></div> | ||
|
r330 | |||
|
r1115 | <% if authorize_for('issues', 'edit') %> | ||
|
r1030 | <div id="update" style="display:none;"> | ||
<h3><%= l(:button_update) %></h3> | ||||
|
r1115 | <%= render :partial => 'edit' %> | ||
|
r330 | </div> | ||
|
r2 | <% end %> | ||
|
r686 | |||
|
r1171 | <p class="other-formats"> | ||
<%= l(:label_export_to) %> | ||||
<span><%= link_to 'Atom', {:format => 'atom', :key => User.current.rss_key}, :class => 'feed' %></span> | ||||
<span><%= link_to 'PDF', {:format => 'pdf'}, :class => 'pdf' %></span> | ||||
</p> | ||||
|
r704 | |||
|
r1019 | <% html_title "#{@issue.tracker.name} ##{@issue.id}: #{@issue.subject}" %> | ||
|
r736 | |||
<% content_for :sidebar do %> | ||||
<%= render :partial => 'issues/sidebar' %> | ||||
<% end %> | ||||
|
r1171 | |||
<% content_for :header_tags do %> | ||||
<%= auto_discovery_link_tag(:atom, {:format => 'atom', :key => User.current.rss_key}, :title => "#{@issue.project} - #{@issue.tracker} ##{@issue.id}: #{@issue.subject}") %> | ||||
|
r1548 | <%= stylesheet_link_tag 'scm' %> | ||
|
r1171 | <% end %> | ||