@@ -1,158 +1,160 | |||||
1 | <%= render :partial => 'action_menu' %> |
|
1 | <%= render :partial => 'action_menu' %> | |
2 |
|
2 | |||
3 | <h2><%= issue_heading(@issue) %></h2> |
|
3 | <h2><%= issue_heading(@issue) %></h2> | |
4 |
|
4 | |||
5 | <div class="<%= @issue.css_classes %> details"> |
|
5 | <div class="<%= @issue.css_classes %> details"> | |
6 | <% if @prev_issue_id || @next_issue_id %> |
|
6 | <% if @prev_issue_id || @next_issue_id %> | |
7 | <div class="next-prev-links contextual"> |
|
7 | <div class="next-prev-links contextual"> | |
8 | <%= link_to_if @prev_issue_id, |
|
8 | <%= link_to_if @prev_issue_id, | |
9 | "\xc2\xab #{l(:label_previous)}", |
|
9 | "\xc2\xab #{l(:label_previous)}", | |
10 | (@prev_issue_id ? issue_path(@prev_issue_id) : nil), |
|
10 | (@prev_issue_id ? issue_path(@prev_issue_id) : nil), | |
11 | :title => "##{@prev_issue_id}" %> | |
|
11 | :title => "##{@prev_issue_id}" %> | | |
12 | <% if @issue_position && @issue_count %> |
|
12 | <% if @issue_position && @issue_count %> | |
13 | <span class="position"><%= l(:label_item_position, :position => @issue_position, :count => @issue_count) %></span> | |
|
13 | <span class="position"><%= l(:label_item_position, :position => @issue_position, :count => @issue_count) %></span> | | |
14 | <% end %> |
|
14 | <% end %> | |
15 | <%= link_to_if @next_issue_id, |
|
15 | <%= link_to_if @next_issue_id, | |
16 | "#{l(:label_next)} \xc2\xbb", |
|
16 | "#{l(:label_next)} \xc2\xbb", | |
17 | (@next_issue_id ? issue_path(@next_issue_id) : nil), |
|
17 | (@next_issue_id ? issue_path(@next_issue_id) : nil), | |
18 | :title => "##{@next_issue_id}" %> |
|
18 | :title => "##{@next_issue_id}" %> | |
19 | </div> |
|
19 | </div> | |
20 | <% end %> |
|
20 | <% end %> | |
21 |
|
21 | |||
22 | <%= avatar(@issue.author, :size => "50") %> |
|
22 | <%= avatar(@issue.author, :size => "50") %> | |
23 |
|
23 | |||
24 | <div class="subject"> |
|
24 | <div class="subject"> | |
25 | <%= render_issue_subject_with_tree(@issue) %> |
|
25 | <%= render_issue_subject_with_tree(@issue) %> | |
26 | </div> |
|
26 | </div> | |
27 | <p class="author"> |
|
27 | <p class="author"> | |
28 | <%= authoring @issue.created_on, @issue.author %>. |
|
28 | <%= authoring @issue.created_on, @issue.author %>. | |
29 | <% if @issue.created_on != @issue.updated_on %> |
|
29 | <% if @issue.created_on != @issue.updated_on %> | |
30 | <%= l(:label_updated_time, time_tag(@issue.updated_on)).html_safe %>. |
|
30 | <%= l(:label_updated_time, time_tag(@issue.updated_on)).html_safe %>. | |
31 | <% end %> |
|
31 | <% end %> | |
32 | </p> |
|
32 | </p> | |
33 |
|
33 | |||
34 | <table class="attributes"> |
|
34 | <table class="attributes"> | |
35 | <%= issue_fields_rows do |rows| |
|
35 | <%= issue_fields_rows do |rows| | |
36 | rows.left l(:field_status), h(@issue.status.name), :class => 'status' |
|
36 | rows.left l(:field_status), h(@issue.status.name), :class => 'status' | |
37 | rows.left l(:field_priority), h(@issue.priority.name), :class => 'priority' |
|
37 | rows.left l(:field_priority), h(@issue.priority.name), :class => 'priority' | |
38 |
|
38 | |||
39 | unless @issue.disabled_core_fields.include?('assigned_to_id') |
|
39 | unless @issue.disabled_core_fields.include?('assigned_to_id') | |
40 | rows.left l(:field_assigned_to), avatar(@issue.assigned_to, :size => "14").to_s.html_safe + (@issue.assigned_to ? link_to_user(@issue.assigned_to) : "-"), :class => 'assigned-to' |
|
40 | rows.left l(:field_assigned_to), avatar(@issue.assigned_to, :size => "14").to_s.html_safe + (@issue.assigned_to ? link_to_user(@issue.assigned_to) : "-"), :class => 'assigned-to' | |
41 | end |
|
41 | end | |
42 | unless @issue.disabled_core_fields.include?('category_id') |
|
42 | unless @issue.disabled_core_fields.include?('category_id') | |
43 | rows.left l(:field_category), h(@issue.category ? @issue.category.name : "-"), :class => 'category' |
|
43 | rows.left l(:field_category), h(@issue.category ? @issue.category.name : "-"), :class => 'category' | |
44 | end |
|
44 | end | |
45 | unless @issue.disabled_core_fields.include?('fixed_version_id') |
|
45 | unless @issue.disabled_core_fields.include?('fixed_version_id') | |
46 | rows.left l(:field_fixed_version), (@issue.fixed_version ? link_to_version(@issue.fixed_version) : "-"), :class => 'fixed-version' |
|
46 | rows.left l(:field_fixed_version), (@issue.fixed_version ? link_to_version(@issue.fixed_version) : "-"), :class => 'fixed-version' | |
47 | end |
|
47 | end | |
48 |
|
48 | |||
49 | unless @issue.disabled_core_fields.include?('start_date') |
|
49 | unless @issue.disabled_core_fields.include?('start_date') | |
50 | rows.right l(:field_start_date), format_date(@issue.start_date), :class => 'start-date' |
|
50 | rows.right l(:field_start_date), format_date(@issue.start_date), :class => 'start-date' | |
51 | end |
|
51 | end | |
52 | unless @issue.disabled_core_fields.include?('due_date') |
|
52 | unless @issue.disabled_core_fields.include?('due_date') | |
53 | rows.right l(:field_due_date), format_date(@issue.due_date), :class => 'due-date' |
|
53 | rows.right l(:field_due_date), format_date(@issue.due_date), :class => 'due-date' | |
54 | end |
|
54 | end | |
55 | unless @issue.disabled_core_fields.include?('done_ratio') |
|
55 | unless @issue.disabled_core_fields.include?('done_ratio') | |
56 | rows.right l(:field_done_ratio), progress_bar(@issue.done_ratio, :width => '80px', :legend => "#{@issue.done_ratio}%"), :class => 'progress' |
|
56 | rows.right l(:field_done_ratio), progress_bar(@issue.done_ratio, :width => '80px', :legend => "#{@issue.done_ratio}%"), :class => 'progress' | |
57 | end |
|
57 | end | |
58 | unless @issue.disabled_core_fields.include?('estimated_hours') |
|
58 | unless @issue.disabled_core_fields.include?('estimated_hours') | |
|
59 | unless @issue.estimated_hours.nil? | |||
59 | rows.right l(:field_estimated_hours), l_hours(@issue.estimated_hours), :class => 'estimated-hours' |
|
60 | rows.right l(:field_estimated_hours), l_hours(@issue.estimated_hours), :class => 'estimated-hours' | |
60 | end |
|
61 | end | |
|
62 | end | |||
61 | if User.current.allowed_to?(:view_time_entries, @project) |
|
63 | if User.current.allowed_to?(:view_time_entries, @project) | |
62 | rows.right l(:label_spent_time), (@issue.total_spent_hours > 0 ? (link_to l_hours(@issue.total_spent_hours), {:controller => 'timelog', :action => 'index', :project_id => @project, :issue_id => @issue}) : "-"), :class => 'spent-time' |
|
64 | rows.right l(:label_spent_time), (@issue.total_spent_hours > 0 ? (link_to l_hours(@issue.total_spent_hours), {:controller => 'timelog', :action => 'index', :project_id => @project, :issue_id => @issue}) : "-"), :class => 'spent-time' | |
63 | end |
|
65 | end | |
64 | end %> |
|
66 | end %> | |
65 | <%= render_custom_fields_rows(@issue) %> |
|
67 | <%= render_custom_fields_rows(@issue) %> | |
66 | <%= call_hook(:view_issues_show_details_bottom, :issue => @issue) %> |
|
68 | <%= call_hook(:view_issues_show_details_bottom, :issue => @issue) %> | |
67 | </table> |
|
69 | </table> | |
68 |
|
70 | |||
69 | <% if @issue.description? || @issue.attachments.any? -%> |
|
71 | <% if @issue.description? || @issue.attachments.any? -%> | |
70 | <hr /> |
|
72 | <hr /> | |
71 | <% if @issue.description? %> |
|
73 | <% if @issue.description? %> | |
72 | <div class="contextual"> |
|
74 | <div class="contextual"> | |
73 | <%= link_to l(:button_quote), |
|
75 | <%= link_to l(:button_quote), | |
74 | {:controller => 'journals', :action => 'new', :id => @issue}, |
|
76 | {:controller => 'journals', :action => 'new', :id => @issue}, | |
75 | :remote => true, |
|
77 | :remote => true, | |
76 | :method => 'post', |
|
78 | :method => 'post', | |
77 | :class => 'icon icon-comment' if authorize_for('issues', 'edit') %> |
|
79 | :class => 'icon icon-comment' if authorize_for('issues', 'edit') %> | |
78 | </div> |
|
80 | </div> | |
79 |
|
81 | |||
80 | <p><strong><%=l(:field_description)%></strong></p> |
|
82 | <p><strong><%=l(:field_description)%></strong></p> | |
81 | <div class="wiki"> |
|
83 | <div class="wiki"> | |
82 | <%= textilizable @issue, :description, :attachments => @issue.attachments %> |
|
84 | <%= textilizable @issue, :description, :attachments => @issue.attachments %> | |
83 | </div> |
|
85 | </div> | |
84 | <% end %> |
|
86 | <% end %> | |
85 | <%= link_to_attachments @issue, :thumbnails => true %> |
|
87 | <%= link_to_attachments @issue, :thumbnails => true %> | |
86 | <% end -%> |
|
88 | <% end -%> | |
87 |
|
89 | |||
88 | <%= call_hook(:view_issues_show_description_bottom, :issue => @issue) %> |
|
90 | <%= call_hook(:view_issues_show_description_bottom, :issue => @issue) %> | |
89 |
|
91 | |||
90 | <% if !@issue.leaf? || User.current.allowed_to?(:manage_subtasks, @project) %> |
|
92 | <% if !@issue.leaf? || User.current.allowed_to?(:manage_subtasks, @project) %> | |
91 | <hr /> |
|
93 | <hr /> | |
92 | <div id="issue_tree"> |
|
94 | <div id="issue_tree"> | |
93 | <div class="contextual"> |
|
95 | <div class="contextual"> | |
94 | <%= link_to(l(:button_add), {:controller => 'issues', :action => 'new', :project_id => @project, :issue => {:parent_issue_id => @issue}}) if User.current.allowed_to?(:manage_subtasks, @project) %> |
|
96 | <%= link_to(l(:button_add), {:controller => 'issues', :action => 'new', :project_id => @project, :issue => {:parent_issue_id => @issue}}) if User.current.allowed_to?(:manage_subtasks, @project) %> | |
95 | </div> |
|
97 | </div> | |
96 | <p><strong><%=l(:label_subtask_plural)%></strong></p> |
|
98 | <p><strong><%=l(:label_subtask_plural)%></strong></p> | |
97 | <%= render_descendants_tree(@issue) unless @issue.leaf? %> |
|
99 | <%= render_descendants_tree(@issue) unless @issue.leaf? %> | |
98 | </div> |
|
100 | </div> | |
99 | <% end %> |
|
101 | <% end %> | |
100 |
|
102 | |||
101 | <% if @relations.present? || User.current.allowed_to?(:manage_issue_relations, @project) %> |
|
103 | <% if @relations.present? || User.current.allowed_to?(:manage_issue_relations, @project) %> | |
102 | <hr /> |
|
104 | <hr /> | |
103 | <div id="relations"> |
|
105 | <div id="relations"> | |
104 | <%= render :partial => 'relations' %> |
|
106 | <%= render :partial => 'relations' %> | |
105 | </div> |
|
107 | </div> | |
106 | <% end %> |
|
108 | <% end %> | |
107 |
|
109 | |||
108 | </div> |
|
110 | </div> | |
109 |
|
111 | |||
110 | <% if @changesets.present? %> |
|
112 | <% if @changesets.present? %> | |
111 | <div id="issue-changesets"> |
|
113 | <div id="issue-changesets"> | |
112 | <h3><%=l(:label_associated_revisions)%></h3> |
|
114 | <h3><%=l(:label_associated_revisions)%></h3> | |
113 | <%= render :partial => 'changesets', :locals => { :changesets => @changesets} %> |
|
115 | <%= render :partial => 'changesets', :locals => { :changesets => @changesets} %> | |
114 | </div> |
|
116 | </div> | |
115 | <% end %> |
|
117 | <% end %> | |
116 |
|
118 | |||
117 | <% if @journals.present? %> |
|
119 | <% if @journals.present? %> | |
118 | <div id="history"> |
|
120 | <div id="history"> | |
119 | <h3><%=l(:label_history)%></h3> |
|
121 | <h3><%=l(:label_history)%></h3> | |
120 | <%= render :partial => 'history', :locals => { :issue => @issue, :journals => @journals } %> |
|
122 | <%= render :partial => 'history', :locals => { :issue => @issue, :journals => @journals } %> | |
121 | </div> |
|
123 | </div> | |
122 | <% end %> |
|
124 | <% end %> | |
123 |
|
125 | |||
124 |
|
126 | |||
125 | <div style="clear: both;"></div> |
|
127 | <div style="clear: both;"></div> | |
126 | <%= render :partial => 'action_menu' %> |
|
128 | <%= render :partial => 'action_menu' %> | |
127 |
|
129 | |||
128 | <div style="clear: both;"></div> |
|
130 | <div style="clear: both;"></div> | |
129 | <% if authorize_for('issues', 'edit') %> |
|
131 | <% if authorize_for('issues', 'edit') %> | |
130 | <div id="update" style="display:none;"> |
|
132 | <div id="update" style="display:none;"> | |
131 | <h3><%= l(:button_update) %></h3> |
|
133 | <h3><%= l(:button_update) %></h3> | |
132 | <%= render :partial => 'edit' %> |
|
134 | <%= render :partial => 'edit' %> | |
133 | </div> |
|
135 | </div> | |
134 | <% end %> |
|
136 | <% end %> | |
135 |
|
137 | |||
136 | <% other_formats_links do |f| %> |
|
138 | <% other_formats_links do |f| %> | |
137 | <%= f.link_to 'Atom', :url => {:key => User.current.rss_key} %> |
|
139 | <%= f.link_to 'Atom', :url => {:key => User.current.rss_key} %> | |
138 | <%= f.link_to 'PDF' %> |
|
140 | <%= f.link_to 'PDF' %> | |
139 | <% end %> |
|
141 | <% end %> | |
140 |
|
142 | |||
141 | <% html_title "#{@issue.tracker.name} ##{@issue.id}: #{@issue.subject}" %> |
|
143 | <% html_title "#{@issue.tracker.name} ##{@issue.id}: #{@issue.subject}" %> | |
142 |
|
144 | |||
143 | <% content_for :sidebar do %> |
|
145 | <% content_for :sidebar do %> | |
144 | <%= render :partial => 'issues/sidebar' %> |
|
146 | <%= render :partial => 'issues/sidebar' %> | |
145 |
|
147 | |||
146 | <% if User.current.allowed_to?(:add_issue_watchers, @project) || |
|
148 | <% if User.current.allowed_to?(:add_issue_watchers, @project) || | |
147 | (@issue.watchers.present? && User.current.allowed_to?(:view_issue_watchers, @project)) %> |
|
149 | (@issue.watchers.present? && User.current.allowed_to?(:view_issue_watchers, @project)) %> | |
148 | <div id="watchers"> |
|
150 | <div id="watchers"> | |
149 | <%= render :partial => 'watchers/watchers', :locals => {:watched => @issue} %> |
|
151 | <%= render :partial => 'watchers/watchers', :locals => {:watched => @issue} %> | |
150 | </div> |
|
152 | </div> | |
151 | <% end %> |
|
153 | <% end %> | |
152 | <% end %> |
|
154 | <% end %> | |
153 |
|
155 | |||
154 | <% content_for :header_tags do %> |
|
156 | <% content_for :header_tags do %> | |
155 | <%= auto_discovery_link_tag(:atom, {:format => 'atom', :key => User.current.rss_key}, :title => "#{@issue.project} - #{@issue.tracker} ##{@issue.id}: #{@issue.subject}") %> |
|
157 | <%= auto_discovery_link_tag(:atom, {:format => 'atom', :key => User.current.rss_key}, :title => "#{@issue.project} - #{@issue.tracker} ##{@issue.id}: #{@issue.subject}") %> | |
156 | <% end %> |
|
158 | <% end %> | |
157 |
|
159 | |||
158 | <%= context_menu issues_context_menu_path %> |
|
160 | <%= context_menu issues_context_menu_path %> |
General Comments 0
You need to be logged in to leave comments.
Login now