##// END OF EJS Templates
Remove unecessary page title HTML escaping from views (#9252)....
Etienne Massip -
r7445:4ecd65c4658c
parent child
Show More
@@ -1,17 +1,17
1 1 <h2><%=h @attachment.filename %></h2>
2 2
3 3 <div class="attachments">
4 4 <p><%= h("#{@attachment.description} - ") unless @attachment.description.blank? %>
5 5 <span class="author"><%= link_to_user(@attachment.author) %>, <%= format_time(@attachment.created_on) %></span></p>
6 6 <p><%= link_to_attachment @attachment, :text => l(:button_download), :download => true -%>
7 7 <span class="size">(<%= number_to_human_size @attachment.filesize %>)</span></p>
8 8
9 9 </div>
10 10 &nbsp;
11 11 <%= render :partial => 'common/diff', :locals => {:diff => @diff, :diff_type => @diff_type} %>
12 12
13 <% html_title h(@attachment.filename) %>
13 <% html_title @attachment.filename %>
14 14
15 15 <% content_for :header_tags do -%>
16 16 <%= stylesheet_link_tag "scm" -%>
17 17 <% end -%>
@@ -1,17 +1,17
1 1 <h2><%=h @attachment.filename %></h2>
2 2
3 3 <div class="attachments">
4 4 <p><%= h("#{@attachment.description} - ") unless @attachment.description.blank? %>
5 5 <span class="author"><%= link_to_user(@attachment.author) %>, <%= format_time(@attachment.created_on) %></span></p>
6 6 <p><%= link_to_attachment @attachment, :text => l(:button_download), :download => true -%>
7 7 <span class="size">(<%= number_to_human_size @attachment.filesize %>)</span></p>
8 8
9 9 </div>
10 10 &nbsp;
11 11 <%= render :partial => 'common/file', :locals => {:content => @content, :filename => @attachment.filename} %>
12 12
13 <% html_title h(@attachment.filename) %>
13 <% html_title @attachment.filename %>
14 14
15 15 <% content_for :header_tags do -%>
16 16 <%= stylesheet_link_tag "scm" -%>
17 17 <% end -%>
@@ -1,73 +1,73
1 1 <%= breadcrumb link_to(l(:label_board_plural), {:controller => 'boards', :action => 'index', :project_id => @project}) %>
2 2
3 3 <div class="contextual">
4 4 <%= link_to_if_authorized l(:label_message_new),
5 5 {:controller => 'messages', :action => 'new', :board_id => @board},
6 6 :class => 'icon icon-add',
7 7 :onclick => 'Element.show("add-message"); Form.Element.focus("message_subject"); return false;' %>
8 8 <%= watcher_tag(@board, User.current) %>
9 9 </div>
10 10
11 11 <div id="add-message" style="display:none;">
12 12 <% if authorize_for('messages', 'new') %>
13 13 <h2><%= link_to h(@board.name), :controller => 'boards', :action => 'show', :project_id => @project, :id => @board %> &#187; <%= l(:label_message_new) %></h2>
14 14 <% form_for :message, @message, :url => {:controller => 'messages', :action => 'new', :board_id => @board}, :html => {:multipart => true, :id => 'message-form'} do |f| %>
15 15 <%= render :partial => 'messages/form', :locals => {:f => f} %>
16 16 <p><%= submit_tag l(:button_create) %>
17 17 <%= link_to_remote l(:label_preview),
18 18 { :url => { :controller => 'messages', :action => 'preview', :board_id => @board },
19 19 :method => 'post',
20 20 :update => 'preview',
21 21 :with => "Form.serialize('message-form')",
22 22 :complete => "Element.scrollTo('preview')"
23 23 }, :accesskey => accesskey(:preview) %> |
24 24 <%= link_to l(:button_cancel), "#", :onclick => 'Element.hide("add-message")' %></p>
25 25 <% end %>
26 26 <div id="preview" class="wiki"></div>
27 27 <% end %>
28 28 </div>
29 29
30 30 <h2><%=h @board.name %></h2>
31 31 <p class="subtitle"><%=h @board.description %></p>
32 32
33 33 <% if @topics.any? %>
34 34 <table class="list messages">
35 35 <thead><tr>
36 36 <th><%= l(:field_subject) %></th>
37 37 <th><%= l(:field_author) %></th>
38 38 <%= sort_header_tag('created_on', :caption => l(:field_created_on)) %>
39 39 <%= sort_header_tag('replies', :caption => l(:label_reply_plural)) %>
40 40 <%= sort_header_tag('updated_on', :caption => l(:label_message_last)) %>
41 41 </tr></thead>
42 42 <tbody>
43 43 <% @topics.each do |topic| %>
44 44 <tr class="message <%= cycle 'odd', 'even' %> <%= topic.sticky? ? 'sticky' : '' %> <%= topic.locked? ? 'locked' : '' %>">
45 45 <td class="subject"><%= link_to h(topic.subject), { :controller => 'messages', :action => 'show', :board_id => @board, :id => topic } %></td>
46 46 <td class="author" align="center"><%= link_to_user(topic.author) %></td>
47 47 <td class="created_on" align="center"><%= format_time(topic.created_on) %></td>
48 48 <td class="replies" align="center"><%= topic.replies_count %></td>
49 49 <td class="last_message">
50 50 <% if topic.last_reply %>
51 51 <%= authoring topic.last_reply.created_on, topic.last_reply.author %><br />
52 52 <%= link_to_message topic.last_reply %>
53 53 <% end %>
54 54 </td>
55 55 </tr>
56 56 <% end %>
57 57 </tbody>
58 58 </table>
59 59 <p class="pagination"><%= pagination_links_full @topic_pages, @topic_count %></p>
60 60 <% else %>
61 61 <p class="nodata"><%= l(:label_no_data) %></p>
62 62 <% end %>
63 63
64 64 <% other_formats_links do |f| %>
65 65 <%= f.link_to 'Atom', :url => {:key => User.current.rss_key} %>
66 66 <% end %>
67 67
68 <% html_title h(@board.name) %>
68 <% html_title @board.name %>
69 69
70 70 <% content_for :header_tags do %>
71 71 <%= auto_discovery_link_tag(:atom, {:format => 'atom', :key => User.current.rss_key}, :title => "#{@project}: #{@board}") %>
72 72 <%= stylesheet_link_tag 'scm' %>
73 73 <% end %>
@@ -1,6 +1,6
1 1 <h2><%=h @status %></h2>
2 2
3 3 <p id="errorExplanation"><%=h @message %></p>
4 4 <p><a href="javascript:history.back()">Back</a></p>
5 5
6 <% html_title h(@status) %>
6 <% html_title @status %>
@@ -1,32 +1,32
1 1 <div class="contextual">
2 2 <%= link_to_if_authorized l(:button_edit), {:controller => 'documents', :action => 'edit', :id => @document}, :class => 'icon icon-edit', :accesskey => accesskey(:edit) %>
3 3 <%= link_to_if_authorized l(:button_delete), {:controller => 'documents', :action => 'destroy', :id => @document}, :confirm => l(:text_are_you_sure), :method => :post, :class => 'icon icon-del' %>
4 4 </div>
5 5
6 6 <h2><%=h @document.title %></h2>
7 7
8 8 <p><em><%=h @document.category.name %><br />
9 9 <%= format_date @document.created_on %></em></p>
10 10 <div class="wiki">
11 11 <%= textilizable @document.description, :attachments => @document.attachments %>
12 12 </div>
13 13
14 14 <h3><%= l(:label_attachment_plural) %></h3>
15 15 <%= link_to_attachments @document %>
16 16
17 17 <% if authorize_for('documents', 'add_attachment') %>
18 18 <p><%= link_to l(:label_attachment_new), {}, :onclick => "Element.show('add_attachment_form'); Element.hide(this); Element.scrollTo('add_attachment_form'); return false;",
19 19 :id => 'attach_files_link' %></p>
20 20 <% form_tag({ :controller => 'documents', :action => 'add_attachment', :id => @document }, :multipart => true, :id => "add_attachment_form", :style => "display:none;") do %>
21 21 <div class="box">
22 22 <p><%= render :partial => 'attachments/form' %></p>
23 23 </div>
24 24 <%= submit_tag l(:button_add) %>
25 25 <% end %>
26 26 <% end %>
27 27
28 <% html_title h(@document.title) -%>
28 <% html_title @document.title -%>
29 29
30 30 <% content_for :header_tags do %>
31 31 <%= stylesheet_link_tag 'scm' %>
32 32 <% end %>
@@ -1,73 +1,73
1 1 <div class="contextual">
2 2 <% if !@query.new_record? && @query.editable_by?(User.current) %>
3 3 <%= link_to l(:button_edit), {:controller => 'queries', :action => 'edit', :id => @query}, :class => 'icon icon-edit' %>
4 4 <%= link_to l(:button_delete), {:controller => 'queries', :action => 'destroy', :id => @query}, :confirm => l(:text_are_you_sure), :method => :post, :class => 'icon icon-del' %>
5 5 <% end %>
6 6 </div>
7 7
8 8 <h2><%= @query.new_record? ? l(:label_issue_plural) : h(@query.name) %></h2>
9 <% html_title(@query.new_record? ? l(:label_issue_plural) : h(@query.name)) %>
9 <% html_title(@query.new_record? ? l(:label_issue_plural) : @query.name) %>
10 10
11 11 <% form_tag({ :controller => 'issues', :action => 'index', :project_id => @project }, :method => :get, :id => 'query_form') do %>
12 12 <%= hidden_field_tag 'set_filter', '1' %>
13 13 <div id="query_form_content" class="hide-when-print">
14 14 <fieldset id="filters" class="collapsible <%= @query.new_record? ? "" : "collapsed" %>">
15 15 <legend onclick="toggleFieldset(this);"><%= l(:label_filter_plural) %></legend>
16 16 <div style="<%= @query.new_record? ? "" : "display: none;" %>">
17 17 <%= render :partial => 'queries/filters', :locals => {:query => @query} %>
18 18 </div>
19 19 </fieldset>
20 20 <fieldset class="collapsible collapsed">
21 21 <legend onclick="toggleFieldset(this);"><%= l(:label_options) %></legend>
22 22 <div style="display: none;">
23 23 <table>
24 24 <tr>
25 25 <td><%= l(:field_column_names) %></td>
26 26 <td><%= render :partial => 'queries/columns', :locals => {:query => @query} %></td>
27 27 </tr>
28 28 <tr>
29 29 <td><%= l(:field_group_by) %></td>
30 30 <td><%= select_tag('group_by', options_for_select([[]] + @query.groupable_columns.collect {|c| [c.caption, c.name.to_s]}, @query.group_by)) %></td>
31 31 </tr>
32 32 </table>
33 33 </div>
34 34 </fieldset>
35 35 </div>
36 36 <p class="buttons hide-when-print">
37 37
38 38 <%= link_to_function l(:button_apply), 'submit_query_form("query_form")', :class => 'icon icon-checked' %>
39 39 <%= link_to l(:button_clear), { :set_filter => 1, :project_id => @project }, :class => 'icon icon-reload' %>
40 40 <% if @query.new_record? && User.current.allowed_to?(:save_queries, @project, :global => true) %>
41 41 <%= link_to_function l(:button_save), "$('query_form').action='#{ url_for :controller => 'queries', :action => 'new', :project_id => @project }'; submit_query_form('query_form')", :class => 'icon icon-save' %>
42 42 <% end %>
43 43 </p>
44 44 <% end %>
45 45
46 46 <%= error_messages_for 'query' %>
47 47 <% if @query.valid? %>
48 48 <% if @issues.empty? %>
49 49 <p class="nodata"><%= l(:label_no_data) %></p>
50 50 <% else %>
51 51 <%= render :partial => 'issues/list', :locals => {:issues => @issues, :query => @query} %>
52 52 <p class="pagination"><%= pagination_links_full @issue_pages, @issue_count %></p>
53 53 <% end %>
54 54
55 55 <% other_formats_links do |f| %>
56 56 <%= f.link_to 'Atom', :url => params.merge(:key => User.current.rss_key) %>
57 57 <%= f.link_to 'CSV', :url => params %>
58 58 <%= f.link_to 'PDF', :url => params %>
59 59 <% end %>
60 60
61 61 <% end %>
62 62 <%= call_hook(:view_issues_index_bottom, { :issues => @issues, :project => @project, :query => @query }) %>
63 63
64 64 <% content_for :sidebar do %>
65 65 <%= render :partial => 'issues/sidebar' %>
66 66 <% end %>
67 67
68 68 <% content_for :header_tags do %>
69 69 <%= auto_discovery_link_tag(:atom, {:query_id => @query, :format => 'atom', :page => nil, :key => User.current.rss_key}, :title => l(:label_issue_plural)) %>
70 70 <%= auto_discovery_link_tag(:atom, {:controller => 'journals', :action => 'index', :query_id => @query, :format => 'atom', :page => nil, :key => User.current.rss_key}, :title => l(:label_changes_details)) %>
71 71 <% end %>
72 72
73 73 <%= context_menu issues_context_menu_path %>
@@ -1,137 +1,137
1 1 <%= render :partial => 'action_menu' %>
2 2
3 3 <h2><%= issue_heading(@issue) %></h2>
4 4
5 5 <div class="<%= @issue.css_classes %> details">
6 6 <%= avatar(@issue.author, :size => "50") %>
7 7
8 8 <div class="subject">
9 9 <%= render_issue_subject_with_tree(@issue) %>
10 10 </div>
11 11 <p class="author">
12 12 <%= authoring @issue.created_on, @issue.author %>.
13 13 <% if @issue.created_on != @issue.updated_on %>
14 14 <%= l(:label_updated_time, time_tag(@issue.updated_on)) %>.
15 15 <% end %>
16 16 </p>
17 17
18 18 <table class="attributes">
19 19 <tr>
20 20 <th class="status"><%=l(:field_status)%>:</th><td class="status"><%= h(@issue.status.name) %></td>
21 21 <th class="start-date"><%=l(:field_start_date)%>:</th><td class="start-date"><%= format_date(@issue.start_date) %></td>
22 22 </tr>
23 23 <tr>
24 24 <th class="priority"><%=l(:field_priority)%>:</th><td class="priority"><%= h(@issue.priority.name) %></td>
25 25 <th class="due-date"><%=l(:field_due_date)%>:</th><td class="due-date"><%= format_date(@issue.due_date) %></td>
26 26 </tr>
27 27 <tr>
28 28 <th class="assigned-to"><%=l(:field_assigned_to)%>:</th><td class="assigned-to"><%= avatar(@issue.assigned_to, :size => "14") %><%= @issue.assigned_to ? link_to_user(@issue.assigned_to) : "-" %></td>
29 29 <th class="progress"><%=l(:field_done_ratio)%>:</th><td class="progress"><%= progress_bar @issue.done_ratio, :width => '80px', :legend => "#{@issue.done_ratio}%" %></td>
30 30 </tr>
31 31 <tr>
32 32 <th class="category"><%=l(:field_category)%>:</th><td class="category"><%=h(@issue.category ? @issue.category.name : "-") %></td>
33 33 <% if User.current.allowed_to?(:view_time_entries, @project) %>
34 34 <th class="spent-time"><%=l(:label_spent_time)%>:</th>
35 35 <td class="spent-time"><%= @issue.spent_hours > 0 ? (link_to l_hours(@issue.spent_hours), {:controller => 'timelog', :action => 'index', :project_id => @project, :issue_id => @issue}) : "-" %></td>
36 36 <% end %>
37 37 </tr>
38 38 <tr>
39 39 <th class="fixed-version"><%=l(:field_fixed_version)%>:</th><td class="fixed-version"><%= @issue.fixed_version ? link_to_version(@issue.fixed_version) : "-" %></td>
40 40 <% if @issue.estimated_hours %>
41 41 <th class="estimated-hours"><%=l(:field_estimated_hours)%>:</th><td class="estimated-hours"><%= l_hours(@issue.estimated_hours) %></td>
42 42 <% end %>
43 43 </tr>
44 44 <%= render_custom_fields_rows(@issue) %>
45 45 <%= call_hook(:view_issues_show_details_bottom, :issue => @issue) %>
46 46 </table>
47 47
48 48 <% if @issue.description? || @issue.attachments.any? -%>
49 49 <hr />
50 50 <% if @issue.description? %>
51 51 <div class="contextual">
52 52 <%= link_to_remote_if_authorized(l(:button_quote), { :url => {:controller => 'journals', :action => 'new', :id => @issue} }, :class => 'icon icon-comment') %>
53 53 </div>
54 54
55 55 <p><strong><%=l(:field_description)%></strong></p>
56 56 <div class="wiki">
57 57 <%= textilizable @issue, :description, :attachments => @issue.attachments %>
58 58 </div>
59 59 <% end %>
60 60 <%= link_to_attachments @issue %>
61 61 <% end -%>
62 62
63 63 <%= call_hook(:view_issues_show_description_bottom, :issue => @issue) %>
64 64
65 65 <% if !@issue.leaf? || User.current.allowed_to?(:manage_subtasks, @project) %>
66 66 <hr />
67 67 <div id="issue_tree">
68 68 <div class="contextual">
69 69 <%= 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) %>
70 70 </div>
71 71 <p><strong><%=l(:label_subtask_plural)%></strong></p>
72 72 <%= render_descendants_tree(@issue) unless @issue.leaf? %>
73 73 </div>
74 74 <% end %>
75 75
76 76 <% if @relations.present? || User.current.allowed_to?(:manage_issue_relations, @project) %>
77 77 <hr />
78 78 <div id="relations">
79 79 <%= render :partial => 'relations' %>
80 80 </div>
81 81 <% end %>
82 82
83 83 </div>
84 84
85 85 <% if @changesets.present? %>
86 86 <div id="issue-changesets">
87 87 <h3><%=l(:label_associated_revisions)%></h3>
88 88 <%= render :partial => 'changesets', :locals => { :changesets => @changesets} %>
89 89 </div>
90 90 <% end %>
91 91
92 92 <% if @journals.present? %>
93 93 <div id="history">
94 94 <h3><%=l(:label_history)%></h3>
95 95 <%= render :partial => 'history', :locals => { :issue => @issue, :journals => @journals } %>
96 96 </div>
97 97 <% end %>
98 98
99 99
100 100 <div style="clear: both;"></div>
101 101 <%= render :partial => 'action_menu' %>
102 102
103 103 <div style="clear: both;"></div>
104 104 <% if authorize_for('issues', 'edit') %>
105 105 <div id="update" style="display:none;">
106 106 <h3><%= l(:button_update) %></h3>
107 107 <%= render :partial => 'edit' %>
108 108 </div>
109 109 <% end %>
110 110
111 111 <% other_formats_links do |f| %>
112 112 <%= f.link_to 'Atom', :url => {:key => User.current.rss_key} %>
113 113 <%= f.link_to 'PDF' %>
114 114 <% end %>
115 115
116 <% html_title h("#{@issue.tracker.name} ##{@issue.id}: #{@issue.subject}") %>
116 <% html_title "#{@issue.tracker.name} ##{@issue.id}: #{@issue.subject}" %>
117 117
118 118 <% content_for :sidebar do %>
119 119 <%= render :partial => 'issues/sidebar' %>
120 120
121 121 <% if User.current.allowed_to?(:add_issue_watchers, @project) ||
122 122 (@issue.watchers.present? && User.current.allowed_to?(:view_issue_watchers, @project)) %>
123 123 <div id="watchers">
124 124 <%= render :partial => 'watchers/watchers', :locals => {:watched => @issue} %>
125 125 </div>
126 126 <% end %>
127 127 <% end %>
128 128
129 129 <% content_for :header_tags do %>
130 130 <%= auto_discovery_link_tag(:atom, {:format => 'atom', :key => User.current.rss_key}, :title => "#{@issue.project} - #{@issue.tracker} ##{@issue.id}: #{@issue.subject}") %>
131 131 <%= stylesheet_link_tag 'scm' %>
132 132 <%= javascript_include_tag 'context_menu' %>
133 133 <%= stylesheet_link_tag 'context_menu' %>
134 134 <%= stylesheet_link_tag 'context_menu_rtl' if l(:direction) == 'rtl' %>
135 135 <% end %>
136 136 <div id="context-menu" style="display: none;"></div>
137 137 <%= javascript_tag "new ContextMenu('#{issues_context_menu_path}')" %>
@@ -1,66 +1,66
1 1 <%= breadcrumb link_to(l(:label_board_plural), {:controller => 'boards', :action => 'index', :project_id => @project}),
2 2 link_to(h(@board.name), {:controller => 'boards', :action => 'show', :project_id => @project, :id => @board}) %>
3 3
4 4 <div class="contextual">
5 5 <%= watcher_tag(@topic, User.current) %>
6 6 <%= link_to_remote_if_authorized(l(:button_quote), { :url => {:action => 'quote', :id => @topic} }, :class => 'icon icon-comment') unless @topic.locked? %>
7 7 <%= link_to(l(:button_edit), {:action => 'edit', :id => @topic}, :class => 'icon icon-edit') if @message.editable_by?(User.current) %>
8 8 <%= link_to(l(:button_delete), {:action => 'destroy', :id => @topic}, :method => :post, :confirm => l(:text_are_you_sure), :class => 'icon icon-del') if @message.destroyable_by?(User.current) %>
9 9 </div>
10 10
11 11 <h2><%= avatar(@topic.author, :size => "24") %><%=h @topic.subject %></h2>
12 12
13 13 <div class="message">
14 14 <p><span class="author"><%= authoring @topic.created_on, @topic.author %></span></p>
15 15 <div class="wiki">
16 16 <%= textilizable(@topic.content, :attachments => @topic.attachments) %>
17 17 </div>
18 18 <%= link_to_attachments @topic, :author => false %>
19 19 </div>
20 20 <br />
21 21
22 22 <% unless @replies.empty? %>
23 23 <h3 class="comments"><%= l(:label_reply_plural) %> (<%= @reply_count %>)</h3>
24 24 <% @replies.each do |message| %>
25 25 <div class="message reply" id="<%= "message-#{message.id}" %>">
26 26 <div class="contextual">
27 27 <%= link_to_remote_if_authorized(image_tag('comment.png'), { :url => {:action => 'quote', :id => message} }, :title => l(:button_quote)) unless @topic.locked? %>
28 28 <%= link_to(image_tag('edit.png'), {:action => 'edit', :id => message}, :title => l(:button_edit)) if message.editable_by?(User.current) %>
29 29 <%= link_to(image_tag('delete.png'), {:action => 'destroy', :id => message}, :method => :post, :confirm => l(:text_are_you_sure), :title => l(:button_delete)) if message.destroyable_by?(User.current) %>
30 30 </div>
31 31 <h4>
32 32 <%= avatar(message.author, :size => "24") %>
33 33 <%= link_to h(message.subject), { :controller => 'messages', :action => 'show', :board_id => @board, :id => @topic, :r => message, :anchor => "message-#{message.id}" } %>
34 34 -
35 35 <%= authoring message.created_on, message.author %>
36 36 </h4>
37 37 <div class="wiki"><%= textilizable message, :content, :attachments => message.attachments %></div>
38 38 <%= link_to_attachments message, :author => false %>
39 39 </div>
40 40 <% end %>
41 41 <p class="pagination"><%= pagination_links_full @reply_pages, @reply_count, :per_page_links => false %></p>
42 42 <% end %>
43 43
44 44 <% if !@topic.locked? && authorize_for('messages', 'reply') %>
45 45 <p><%= toggle_link l(:button_reply), "reply", :focus => 'message_content' %></p>
46 46 <div id="reply" style="display:none;">
47 47 <% form_for :reply, @reply, :url => {:action => 'reply', :id => @topic}, :html => {:multipart => true, :id => 'message-form'} do |f| %>
48 48 <%= render :partial => 'form', :locals => {:f => f, :replying => true} %>
49 49 <%= submit_tag l(:button_submit) %>
50 50 <%= link_to_remote l(:label_preview),
51 51 { :url => { :controller => 'messages', :action => 'preview', :board_id => @board },
52 52 :method => 'post',
53 53 :update => 'preview',
54 54 :with => "Form.serialize('message-form')",
55 55 :complete => "Element.scrollTo('preview')"
56 56 }, :accesskey => accesskey(:preview) %>
57 57 <% end %>
58 58 <div id="preview" class="wiki"></div>
59 59 </div>
60 60 <% end %>
61 61
62 62 <% content_for :header_tags do %>
63 63 <%= stylesheet_link_tag 'scm' %>
64 64 <% end %>
65 65
66 <% html_title h(@topic.subject) %>
66 <% html_title @topic.subject %>
@@ -1,70 +1,70
1 1 <div class="contextual">
2 2 <%= watcher_tag(@news, User.current) %>
3 3 <%= link_to(l(:button_edit),
4 4 edit_news_path(@news),
5 5 :class => 'icon icon-edit',
6 6 :accesskey => accesskey(:edit),
7 7 :onclick => 'Element.show("edit-news"); return false;') if User.current.allowed_to?(:manage_news, @project) %>
8 8 <%= link_to(l(:button_delete),
9 9 news_path(@news),
10 10 :confirm => l(:text_are_you_sure),
11 11 :method => :delete,
12 12 :class => 'icon icon-del') if User.current.allowed_to?(:manage_news, @project) %>
13 13 </div>
14 14
15 15 <h2><%= avatar(@news.author, :size => "24") %><%=h @news.title %></h2>
16 16
17 17 <% if authorize_for('news', 'edit') %>
18 18 <div id="edit-news" style="display:none;">
19 19 <% labelled_tabular_form_for :news, @news, :url => news_path(@news),
20 20 :html => { :id => 'news-form', :method => :put } do |f| %>
21 21 <%= render :partial => 'form', :locals => { :f => f } %>
22 22 <%= submit_tag l(:button_save) %>
23 23 <%= link_to_remote l(:label_preview),
24 24 { :url => preview_news_path(:project_id => @project),
25 25 :method => 'get',
26 26 :update => 'preview',
27 27 :with => "Form.serialize('news-form')"
28 28 }, :accesskey => accesskey(:preview) %> |
29 29 <%= link_to l(:button_cancel), "#", :onclick => 'Element.hide("edit-news"); return false;' %>
30 30 <% end %>
31 31 <div id="preview" class="wiki"></div>
32 32 </div>
33 33 <% end %>
34 34
35 35 <p><% unless @news.summary.blank? %><em><%=h @news.summary %></em><br /><% end %>
36 36 <span class="author"><%= authoring @news.created_on, @news.author %></span></p>
37 37 <div class="wiki">
38 38 <%= textilizable(@news.description) %>
39 39 </div>
40 40 <br />
41 41
42 42 <div id="comments" style="margin-bottom:16px;">
43 43 <h3 class="comments"><%= l(:label_comment_plural) %></h3>
44 44 <% @comments.each do |comment| %>
45 45 <% next if comment.new_record? %>
46 46 <div class="contextual">
47 47 <%= link_to_if_authorized image_tag('delete.png'), {:controller => 'comments', :action => 'destroy', :id => @news, :comment_id => comment},
48 48 :confirm => l(:text_are_you_sure), :method => :delete, :title => l(:button_delete) %>
49 49 </div>
50 50 <h4><%= avatar(comment.author, :size => "24") %><%= authoring comment.created_on, comment.author %></h4>
51 51 <%= textilizable(comment.comments) %>
52 52 <% end if @comments.any? %>
53 53 </div>
54 54
55 55 <% if authorize_for 'comments', 'create' %>
56 56 <p><%= toggle_link l(:label_comment_add), "add_comment_form", :focus => "comment_comments" %></p>
57 57 <% form_tag({:controller => 'comments', :action => 'create', :id => @news}, :id => "add_comment_form", :style => "display:none;") do %>
58 58 <div class="box">
59 59 <%= text_area 'comment', 'comments', :cols => 80, :rows => 15, :class => 'wiki-edit' %>
60 60 <%= wikitoolbar_for 'comment_comments' %>
61 61 </div>
62 62 <p><%= submit_tag l(:button_add) %></p>
63 63 <% end %>
64 64 <% end %>
65 65
66 <% html_title h(@news.title) -%>
66 <% html_title @news.title -%>
67 67
68 68 <% content_for :header_tags do %>
69 69 <%= stylesheet_link_tag 'scm' %>
70 70 <% end %>
@@ -1,28 +1,28
1 1 <%= link_to 'root', :action => 'show', :id => @project, :path => '', :rev => @rev %>
2 2 <%
3 3 dirs = path.split('/')
4 4 if 'file' == kind
5 5 filename = dirs.pop
6 6 end
7 7 link_path = ''
8 8 dirs.each do |dir|
9 9 next if dir.blank?
10 10 link_path << '/' unless link_path.empty?
11 11 link_path << "#{dir}"
12 12 %>
13 13 / <%= link_to h(dir), :action => 'show', :id => @project,
14 14 :path => to_path_param(link_path), :rev => @rev %>
15 15 <% end %>
16 16 <% if filename %>
17 17 / <%= link_to h(filename),
18 18 :action => 'changes', :id => @project,
19 19 :path => to_path_param("#{link_path}/#{filename}"), :rev => @rev %>
20 20 <% end %>
21 21 <%
22 22 # @rev is revsion or Git and Mercurial branch or tag.
23 23 # For Mercurial *tip*, @rev and @changeset are nil.
24 24 rev_text = @changeset.nil? ? @rev : format_revision(@changeset)
25 25 %>
26 26 <%= "@ #{h rev_text}" unless rev_text.blank? %>
27 27
28 <% html_title(h(with_leading_slash(path))) -%>
28 <% html_title(with_leading_slash(path)) -%>
@@ -1,23 +1,23
1 1 <h2><%= l(:label_revision) %> <%= @diff_format_revisions %> <%=h @path %></h2>
2 2
3 3 <!-- Choose view type -->
4 4 <% form_tag({:path => to_path_param(@path)}, :method => 'get') do %>
5 5 <%= hidden_field_tag('rev', params[:rev]) if params[:rev] %>
6 6 <%= hidden_field_tag('rev_to', params[:rev_to]) if params[:rev_to] %>
7 7 <p><label><%= l(:label_view_diff) %></label>
8 8 <%= select_tag 'type', options_for_select([[l(:label_diff_inline), "inline"], [l(:label_diff_side_by_side), "sbs"]], @diff_type), :onchange => "if (this.value != '') {this.form.submit()}" %></p>
9 9 <% end %>
10 10
11 11 <% cache(@cache_key) do -%>
12 12 <%= render :partial => 'common/diff', :locals => {:diff => @diff, :diff_type => @diff_type} %>
13 13 <% end -%>
14 14
15 15 <% other_formats_links do |f| %>
16 16 <%= f.link_to 'Diff', :url => params, :caption => 'Unified diff' %>
17 17 <% end %>
18 18
19 <% html_title(h(with_leading_slash(@path)), 'Diff') -%>
19 <% html_title(with_leading_slash(@path), 'Diff') -%>
20 20
21 21 <% content_for :header_tags do %>
22 22 <%= stylesheet_link_tag "scm" %>
23 23 <% end %>
@@ -1,11 +1,11
1 1 <div class="contextual">
2 2 <%= link_to l(:label_profile), user_path(@user), :class => 'icon icon-user' %>
3 3 <%= change_status_link(@user) %>
4 4 <%= link_to(l(:button_delete), @user, :confirm => l(:text_are_you_sure), :method => :delete, :class => 'icon icon-del') if User.current != @user %>
5 5 </div>
6 6
7 7 <h2><%= link_to l(:label_user_plural), :controller => 'users', :action => 'index' %> &#187; <%=h @user.login %></h2>
8 8
9 9 <%= render_tabs user_settings_tabs %>
10 10
11 <% html_title(l(:label_user), h(@user.login), l(:label_administration)) -%>
11 <% html_title(l(:label_user), @user.login, l(:label_administration)) -%>
@@ -1,70 +1,70
1 1 <div class="contextual">
2 2 <%= link_to(l(:button_edit), edit_user_path(@user), :class => 'icon icon-edit') if User.current.admin? %>
3 3 </div>
4 4
5 5 <h2><%= avatar @user, :size => "50" %> <%=h @user.name %></h2>
6 6
7 7 <div class="splitcontentleft">
8 8 <ul>
9 9 <% unless @user.pref.hide_mail %>
10 10 <li><%=l(:field_mail)%>: <%= mail_to(h(@user.mail), nil, :encode => 'javascript') %></li>
11 11 <% end %>
12 12 <% @user.visible_custom_field_values.each do |custom_value| %>
13 13 <% if !custom_value.value.blank? %>
14 14 <li><%=h custom_value.custom_field.name%>: <%=h show_value(custom_value) %></li>
15 15 <% end %>
16 16 <% end %>
17 17 <li><%=l(:label_registered_on)%>: <%= format_date(@user.created_on) %></li>
18 18 <% unless @user.last_login_on.nil? %>
19 19 <li><%=l(:field_last_login_on)%>: <%= format_date(@user.last_login_on) %></li>
20 20 <% end %>
21 21 </ul>
22 22
23 23 <% unless @memberships.empty? %>
24 24 <h3><%=l(:label_project_plural)%></h3>
25 25 <ul>
26 26 <% for membership in @memberships %>
27 27 <li><%= link_to_project(membership.project) %>
28 28 (<%=h membership.roles.sort.collect(&:to_s).join(', ') %>, <%= format_date(membership.created_on) %>)</li>
29 29 <% end %>
30 30 </ul>
31 31 <% end %>
32 32 <%= call_hook :view_account_left_bottom, :user => @user %>
33 33 </div>
34 34
35 35 <div class="splitcontentright">
36 36
37 37 <% unless @events_by_day.empty? %>
38 38 <h3><%= link_to l(:label_activity), :controller => 'activities', :action => 'index', :id => nil, :user_id => @user, :from => @events_by_day.keys.first %></h3>
39 39
40 40 <p>
41 41 <%=l(:label_reported_issues)%>: <%= Issue.count(:conditions => ["author_id=?", @user.id]) %>
42 42 </p>
43 43
44 44 <div id="activity">
45 45 <% @events_by_day.keys.sort.reverse.each do |day| %>
46 46 <h4><%= format_activity_day(day) %></h4>
47 47 <dl>
48 48 <% @events_by_day[day].sort {|x,y| y.event_datetime <=> x.event_datetime }.each do |e| -%>
49 49 <dt class="<%= e.event_type %>">
50 50 <span class="time"><%= format_time(e.event_datetime, false) %></span>
51 51 <%= content_tag('span', h(e.project), :class => 'project') %>
52 52 <%= link_to format_activity_title(e.event_title), e.event_url %></dt>
53 53 <dd><span class="description"><%= format_activity_description(e.event_description) %></span></dd>
54 54 <% end -%>
55 55 </dl>
56 56 <% end -%>
57 57 </div>
58 58
59 59 <% other_formats_links do |f| %>
60 60 <%= f.link_to 'Atom', :url => {:controller => 'activities', :action => 'index', :id => nil, :user_id => @user, :key => User.current.rss_key} %>
61 61 <% end %>
62 62
63 63 <% content_for :header_tags do %>
64 64 <%= auto_discovery_link_tag(:atom, :controller => 'activities', :action => 'index', :user_id => @user, :format => :atom, :key => User.current.rss_key) %>
65 65 <% end %>
66 66 <% end %>
67 67 <%= call_hook :view_account_right_bottom, :user => @user %>
68 68 </div>
69 69
70 <% html_title h(@user.name) %>
70 <% html_title @user.name %>
@@ -1,56 +1,56
1 1 <div class="contextual">
2 2 <%= link_to(l(:button_edit), edit_version_path(@version), :class => 'icon icon-edit') if User.current.allowed_to?(:manage_versions, @version.project) %>
3 3 <%= link_to_if_authorized(l(:button_edit_associated_wikipage, :page_title => @version.wiki_page_title), {:controller => 'wiki', :action => 'edit', :project_id => @version.project, :id => Wiki.titleize(@version.wiki_page_title)}, :class => 'icon icon-edit') unless @version.wiki_page_title.blank? || @version.project.wiki.nil? %>
4 4 <%= link_to(l(:button_delete), version_path(@version, :back_url => url_for(:controller => 'versions', :action => 'index', :project_id => @version.project)),
5 5 :confirm => l(:text_are_you_sure), :method => :delete, :class => 'icon icon-del') if User.current.allowed_to?(:manage_versions, @version.project) %>
6 6 <%= call_hook(:view_versions_show_contextual, { :version => @version, :project => @project }) %>
7 7 </div>
8 8
9 9 <h2><%= h(@version.name) %></h2>
10 10
11 11 <div id="roadmap">
12 12 <%= render :partial => 'versions/overview', :locals => {:version => @version} %>
13 13 <%= render(:partial => "wiki/content", :locals => {:content => @version.wiki_page.content}) if @version.wiki_page %>
14 14
15 15 <div id="version-summary">
16 16 <% if @version.estimated_hours > 0 || User.current.allowed_to?(:view_time_entries, @project) %>
17 17 <fieldset><legend><%= l(:label_time_tracking) %></legend>
18 18 <table>
19 19 <tr>
20 20 <td width="130px" align="right"><%= l(:field_estimated_hours) %></td>
21 21 <td width="240px" class="total-hours"width="130px" align="right"><%= html_hours(l_hours(@version.estimated_hours)) %></td>
22 22 </tr>
23 23 <% if User.current.allowed_to?(:view_time_entries, @project) %>
24 24 <tr>
25 25 <td width="130px" align="right"><%= l(:label_spent_time) %></td>
26 26 <td width="240px" class="total-hours"><%= html_hours(l_hours(@version.spent_hours)) %></td>
27 27 </tr>
28 28 <% end %>
29 29 </table>
30 30 </fieldset>
31 31 <% end %>
32 32
33 33 <div id="status_by">
34 34 <%= render_issue_status_by(@version, params[:status_by]) if @version.fixed_issues.count > 0 %>
35 35 </div>
36 36 </div>
37 37
38 38 <% if @issues.present? %>
39 39 <% form_tag({}) do -%>
40 40 <table class="list related-issues">
41 41 <caption><%= l(:label_related_issues) %></caption>
42 42 <%- @issues.each do |issue| -%>
43 43 <tr class="hascontextmenu">
44 44 <td class="checkbox"><%= check_box_tag 'ids[]', issue.id %></td>
45 45 <td><%= link_to_issue(issue, :project => (@project != issue.project)) %></td>
46 46 </tr>
47 47 <% end %>
48 48 </table>
49 49 <% end %>
50 50 <%= context_menu issues_context_menu_path %>
51 51 <% end %>
52 52 </div>
53 53
54 54 <%= call_hook :view_versions_show_bottom, :version => @version %>
55 55
56 <% html_title h(@version.name) %>
56 <% html_title @version.name %>
@@ -1,31 +1,31
1 1 <%= wiki_page_breadcrumb(@page) %>
2 2
3 3 <h2><%=h @page.pretty_title %></h2>
4 4
5 5 <% form_for :content, @content, :url => {:action => 'update', :id => @page.title}, :html => {:method => :put, :multipart => true, :id => 'wiki_form'} do |f| %>
6 6 <%= f.hidden_field :version %>
7 7 <%= error_messages_for 'content' %>
8 8
9 9 <p><%= f.text_area :text, :cols => 100, :rows => 25, :class => 'wiki-edit', :accesskey => accesskey(:edit) %></p>
10 10 <p><label><%= l(:field_comments) %></label><br /><%= f.text_field :comments, :size => 120 %></p>
11 11 <p><label><%=l(:label_attachment_plural)%></label><br /><%= render :partial => 'attachments/form' %></p>
12 12
13 13 <p><%= submit_tag l(:button_save) %>
14 14 <%= link_to_remote l(:label_preview),
15 15 { :url => { :controller => 'wiki', :action => 'preview', :project_id => @project, :id => @page.title },
16 16 :method => :post,
17 17 :update => 'preview',
18 18 :with => "Form.serialize('wiki_form')",
19 19 :complete => "Element.scrollTo('preview')"
20 20 }, :accesskey => accesskey(:preview) %></p>
21 21 <%= wikitoolbar_for 'content_text' %>
22 22 <% end %>
23 23
24 24 <div id="preview" class="wiki"></div>
25 25
26 26 <% content_for :header_tags do %>
27 27 <%= stylesheet_link_tag 'scm' %>
28 28 <%= robot_exclusion_tag %>
29 29 <% end %>
30 30
31 <% html_title h(@page.pretty_title) %>
31 <% html_title @page.pretty_title %>
@@ -1,68 +1,68
1 1 <div class="contextual">
2 2 <% if @editable %>
3 3 <%= link_to_if_authorized(l(:button_edit), {:action => 'edit', :id => @page.title}, :class => 'icon icon-edit', :accesskey => accesskey(:edit)) if @content.version == @page.content.version %>
4 4 <%= watcher_tag(@page, User.current) %>
5 5 <%= link_to_if_authorized(l(:button_lock), {:action => 'protect', :id => @page.title, :protected => 1}, :method => :post, :class => 'icon icon-lock') if !@page.protected? %>
6 6 <%= link_to_if_authorized(l(:button_unlock), {:action => 'protect', :id => @page.title, :protected => 0}, :method => :post, :class => 'icon icon-unlock') if @page.protected? %>
7 7 <%= link_to_if_authorized(l(:button_rename), {:action => 'rename', :id => @page.title}, :class => 'icon icon-move') if @content.version == @page.content.version %>
8 8 <%= link_to_if_authorized(l(:button_delete), {:action => 'destroy', :id => @page.title}, :method => :delete, :confirm => l(:text_are_you_sure), :class => 'icon icon-del') %>
9 9 <%= link_to_if_authorized(l(:button_rollback), {:action => 'edit', :id => @page.title, :version => @content.version }, :class => 'icon icon-cancel') if @content.version < @page.content.version %>
10 10 <% end %>
11 11 <%= link_to_if_authorized(l(:label_history), {:action => 'history', :id => @page.title}, :class => 'icon icon-history') %>
12 12 </div>
13 13
14 14 <%= wiki_page_breadcrumb(@page) %>
15 15
16 16 <% if @content.version != @page.content.version %>
17 17 <p>
18 18 <%= link_to(("\xc2\xab " + l(:label_previous)),
19 19 :action => 'show', :id => @page.title, :project_id => @page.project,
20 20 :version => (@content.version - 1)) + " - " if @content.version > 1 %>
21 21 <%= "#{l(:label_version)} #{@content.version}/#{@page.content.version}" %>
22 22 <%= '(' + link_to(l(:label_diff), :controller => 'wiki', :action => 'diff',
23 23 :id => @page.title, :project_id => @page.project,
24 24 :version => @content.version) + ')' if @content.version > 1 %> -
25 25 <%= link_to((l(:label_next) + " \xc2\xbb"), :action => 'show',
26 26 :id => @page.title, :project_id => @page.project,
27 27 :version => (@content.version + 1)) + " - " if @content.version < @page.content.version %>
28 28 <%= link_to(l(:label_current_version), :action => 'show', :id => @page.title, :project_id => @page.project) %>
29 29 <br />
30 30 <em><%= @content.author ? link_to_user(@content.author) : l(:label_user_anonymous)
31 31 %>, <%= format_time(@content.updated_on) %> </em><br />
32 32 <%=h @content.comments %>
33 33 </p>
34 34 <hr />
35 35 <% end %>
36 36
37 37 <%= render(:partial => "wiki/content", :locals => {:content => @content}) %>
38 38
39 39 <%= link_to_attachments @page %>
40 40
41 41 <% if @editable && authorize_for('wiki', 'add_attachment') %>
42 42 <div id="wiki_add_attachment">
43 43 <p><%= link_to l(:label_attachment_new), {}, :onclick => "Element.show('add_attachment_form'); Element.hide(this); Element.scrollTo('add_attachment_form'); return false;",
44 44 :id => 'attach_files_link' %></p>
45 45 <% form_tag({ :controller => 'wiki', :action => 'add_attachment', :project_id => @project, :id => @page.title }, :multipart => true, :id => "add_attachment_form", :style => "display:none;") do %>
46 46 <div class="box">
47 47 <p><%= render :partial => 'attachments/form' %></p>
48 48 </div>
49 49 <%= submit_tag l(:button_add) %>
50 50 <%= link_to l(:button_cancel), {}, :onclick => "Element.hide('add_attachment_form'); Element.show('attach_files_link'); return false;" %>
51 51 <% end %>
52 52 </div>
53 53 <% end %>
54 54
55 55 <% other_formats_links do |f| %>
56 56 <%= f.link_to 'HTML', :url => {:id => @page.title, :version => @content.version} %>
57 57 <%= f.link_to 'TXT', :url => {:id => @page.title, :version => @content.version} %>
58 58 <% end if User.current.allowed_to?(:export_wiki_pages, @project) %>
59 59
60 60 <% content_for :header_tags do %>
61 61 <%= stylesheet_link_tag 'scm' %>
62 62 <% end %>
63 63
64 64 <% content_for :sidebar do %>
65 65 <%= render :partial => 'sidebar' %>
66 66 <% end %>
67 67
68 <% html_title h(@page.pretty_title) %>
68 <% html_title @page.pretty_title %>
General Comments 0
You need to be logged in to leave comments. Login now