2007-03-12 20:59:02 +03:00
|
|
|
<div class="contextual">
|
2007-09-22 17:17:49 +04:00
|
|
|
<%= show_and_goto_link(l(:label_add_note), 'add-note', :class => 'icon icon-note') if authorize_for('issues', 'add_note') %>
|
2007-10-05 22:05:41 +04:00
|
|
|
<%= link_to_if_authorized l(:button_edit), {:controller => 'issues', :action => 'edit', :id => @issue}, :class => 'icon icon-edit', :accesskey => accesskey(:edit) %>
|
2007-09-02 18:34:13 +04:00
|
|
|
<%= link_to_if_authorized l(:button_log_time), {:controller => 'timelog', :action => 'edit', :issue_id => @issue}, :class => 'icon icon-time' %>
|
|
|
|
<%= watcher_tag(@issue, User.current) %>
|
2007-10-28 17:31:59 +03:00
|
|
|
<%= link_to_if_authorized l(:button_copy), {:controller => 'projects', :action => 'add_issue', :id => @project, :copy_from => @issue }, :class => 'icon icon-copy' %>
|
2007-09-02 18:34:13 +04:00
|
|
|
<%= link_to_if_authorized l(:button_move), {:controller => 'projects', :action => 'move_issues', :id => @project, "issue_ids[]" => @issue.id }, :class => 'icon icon-move' %>
|
|
|
|
<%= 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' %>
|
2007-03-12 20:59:02 +03:00
|
|
|
</div>
|
2006-06-28 22:11:03 +04:00
|
|
|
|
2007-09-22 17:17:49 +04:00
|
|
|
<h2><%= @issue.tracker.name %> #<%= @issue.id %></h2>
|
|
|
|
|
2007-11-18 17:32:39 +03:00
|
|
|
<div class="issue <%= "status-#{@issue.status.position} priority-#{@issue.priority.position}" %>">
|
2007-09-22 17:17:49 +04:00
|
|
|
<h3><%=h @issue.subject %></h3>
|
2007-09-15 18:54:15 +04:00
|
|
|
<p class="author">
|
2007-09-15 19:20:08 +04:00
|
|
|
<%= authoring @issue.created_on, @issue.author %>.
|
2007-09-15 18:54:15 +04:00
|
|
|
<%= l(:label_updated_time, distance_of_time_in_words(Time.now, @issue.updated_on)) if @issue.created_on != @issue.updated_on %>.
|
|
|
|
</p>
|
2007-09-22 17:17:49 +04:00
|
|
|
|
2007-03-12 20:59:02 +03:00
|
|
|
<table width="100%">
|
|
|
|
<tr>
|
|
|
|
<td style="width:15%"><b><%=l(:field_status)%> :</b></td><td style="width:35%"><%= @issue.status.name %></td>
|
2007-09-15 18:54:15 +04:00
|
|
|
<td style="width:15%"><b><%=l(:field_start_date)%> :</b></td><td style="width:35%"><%= format_date(@issue.start_date) %></td>
|
2007-03-12 20:59:02 +03:00
|
|
|
</tr>
|
|
|
|
<tr>
|
2007-09-15 18:54:15 +04:00
|
|
|
<td><b><%=l(:field_priority)%> :</b></td><td><%= @issue.priority.name %></td>
|
2007-03-12 20:59:02 +03:00
|
|
|
<td><b><%=l(:field_due_date)%> :</b></td><td><%= format_date(@issue.due_date) %></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2007-09-15 18:54:15 +04:00
|
|
|
<td><b><%=l(:field_assigned_to)%> :</b></td><td><%= @issue.assigned_to ? link_to_user(@issue.assigned_to) : "-" %></td>
|
2007-11-17 18:34:10 +03:00
|
|
|
<td><b><%=l(:field_done_ratio)%> :</b></td><td><%= progress_bar @issue.done_ratio, :width => '80px', :legend => "#{@issue.done_ratio}%" %></td>
|
2007-03-12 20:59:02 +03:00
|
|
|
</tr>
|
|
|
|
<tr>
|
2007-09-15 18:54:15 +04:00
|
|
|
<td><b><%=l(:field_category)%> :</b></td><td><%=h @issue.category ? @issue.category.name : "-" %></td>
|
|
|
|
<% if User.current.allowed_to?(:view_time_entries, @project) %>
|
2007-03-23 15:22:31 +03:00
|
|
|
<td><b><%=l(:label_spent_time)%> :</b></td>
|
|
|
|
<td><%= @issue.spent_hours > 0 ? (link_to lwr(:label_f_hour, @issue.spent_hours), {:controller => 'timelog', :action => 'details', :issue_id => @issue}, :class => 'icon icon-time') : "-" %></td>
|
2007-09-15 18:54:15 +04:00
|
|
|
<% end %>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td><b><%=l(:field_fixed_version)%> :</b></td><td><%= @issue.fixed_version ? link_to_version(@issue.fixed_version) : "-" %></td>
|
|
|
|
<% if @issue.estimated_hours %>
|
|
|
|
<td><b><%=l(:field_estimated_hours)%> :</b></td><td><%= lwr(:label_f_hour, @issue.estimated_hours) %></td>
|
|
|
|
<% end %>
|
2007-03-12 20:59:02 +03:00
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<% n = 0
|
|
|
|
for custom_value in @custom_values %>
|
2007-08-12 16:59:05 +04:00
|
|
|
<td valign="top"><b><%= custom_value.custom_field.name %> :</b></td><td valign="top"><%= simple_format(h(show_value(custom_value))) %></td>
|
2007-03-12 20:59:02 +03:00
|
|
|
<% n = n + 1
|
|
|
|
if (n > 1)
|
|
|
|
n = 0 %>
|
|
|
|
</tr><tr>
|
|
|
|
<%end
|
|
|
|
end %>
|
|
|
|
</tr>
|
|
|
|
</table>
|
|
|
|
<hr />
|
2007-04-24 17:57:27 +04:00
|
|
|
|
|
|
|
<% if @issue.changesets.any? %>
|
|
|
|
<div style="float:right;">
|
|
|
|
<em><%= l(:label_revision_plural) %>: <%= @issue.changesets.collect{|changeset| link_to(changeset.revision, :controller => 'repositories', :action => 'revision', :id => @project, :rev => changeset.revision)}.join(", ") %></em>
|
|
|
|
</div>
|
|
|
|
<% end %>
|
2007-03-12 20:59:02 +03:00
|
|
|
|
2007-09-24 23:26:09 +04:00
|
|
|
<p><strong><%=l(:field_description)%></strong></p>
|
2007-11-12 17:36:33 +03:00
|
|
|
<%= textilizable @issue, :description, :attachments => @issue.attachments %>
|
2007-03-12 20:59:02 +03:00
|
|
|
|
2007-09-24 23:26:09 +04:00
|
|
|
<% 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 %>
|
|
|
|
|
2007-05-05 17:22:27 +04:00
|
|
|
<% if authorize_for('issue_relations', 'new') || @issue.relations.any? %>
|
2007-09-22 17:17:49 +04:00
|
|
|
<hr />
|
|
|
|
<div id="relations">
|
2007-05-05 17:22:27 +04:00
|
|
|
<%= render :partial => 'relations' %>
|
|
|
|
</div>
|
|
|
|
<% end %>
|
|
|
|
|
2007-08-29 20:52:35 +04:00
|
|
|
</div>
|
2007-09-22 17:17:49 +04:00
|
|
|
|
|
|
|
<% if authorize_for('issues', 'change_status') and @status_options and !@status_options.empty? %>
|
|
|
|
<% form_tag({:controller => 'issues', :action => 'change_status', :id => @issue}) do %>
|
|
|
|
<p><%=l(:label_change_status)%> :
|
|
|
|
<select name="new_status_id">
|
|
|
|
<%= options_from_collection_for_select @status_options, "id", "name" %>
|
|
|
|
</select>
|
|
|
|
<%= submit_tag l(:button_change) %></p>
|
|
|
|
<% end %>
|
2007-08-29 20:52:35 +04:00
|
|
|
<% end %>
|
|
|
|
|
2007-08-12 17:57:29 +04:00
|
|
|
<% if @journals.any? %>
|
2007-09-22 17:17:49 +04:00
|
|
|
<div id="history">
|
2007-08-12 17:57:29 +04:00
|
|
|
<h3><%=l(:label_history)%></h3>
|
2007-03-12 20:59:02 +03:00
|
|
|
<%= render :partial => 'history', :locals => { :journals => @journals } %>
|
|
|
|
</div>
|
2007-08-01 22:59:39 +04:00
|
|
|
<% end %>
|
2007-03-12 20:59:02 +03:00
|
|
|
|
|
|
|
<% if authorize_for('issues', 'add_note') %>
|
2007-09-22 17:17:49 +04:00
|
|
|
<a name="add-note-anchor"></a>
|
|
|
|
<div id="add-note" class="box" style="display:none;">
|
2007-03-12 20:59:02 +03:00
|
|
|
<h3><%= l(:label_add_note) %></h3>
|
2007-08-29 20:52:35 +04:00
|
|
|
<% form_tag({:controller => 'issues', :action => 'add_note', :id => @issue}, :class => "tabular", :multipart => true) do %>
|
2007-03-12 20:59:02 +03:00
|
|
|
<p><label for="notes"><%=l(:field_notes)%></label>
|
|
|
|
<%= text_area_tag 'notes', '', :cols => 60, :rows => 10, :class => 'wiki-edit' %></p>
|
2007-06-27 23:12:52 +04:00
|
|
|
<%= wikitoolbar_for 'notes' %>
|
2007-08-29 20:52:35 +04:00
|
|
|
<%= render :partial => 'attachments/form' %>
|
2007-03-12 20:59:02 +03:00
|
|
|
<%= submit_tag l(:button_add) %>
|
2007-09-22 17:17:49 +04:00
|
|
|
<%= toggle_link l(:button_cancel), 'add-note' %>
|
2007-03-12 20:59:02 +03:00
|
|
|
<% end %>
|
|
|
|
</div>
|
2006-06-28 22:11:03 +04:00
|
|
|
<% end %>
|
2007-09-02 18:34:13 +04:00
|
|
|
|
|
|
|
<div class="contextual">
|
2007-10-06 03:17:49 +04:00
|
|
|
<%= l(:label_export_to) %><%= link_to 'PDF', {:format => 'pdf'}, :class => 'icon icon-pdf' %>
|
2007-09-02 18:34:13 +04:00
|
|
|
</div>
|
|
|
|
|
2007-09-08 00:52:45 +04:00
|
|
|
|
2007-09-22 17:17:49 +04:00
|
|
|
<% set_html_title "#{@issue.tracker.name} ##{@issue.id}: #{@issue.subject}" %>
|
|
|
|
|
|
|
|
<% content_for :sidebar do %>
|
|
|
|
<%= render :partial => 'issues/sidebar' %>
|
|
|
|
<% end %>
|