@@ -1,40 +1,42 | |||
|
1 | 1 | <h2><%= l(:label_board_plural) %></h2> |
|
2 | 2 | |
|
3 | 3 | <table class="list boards"> |
|
4 | 4 | <thead><tr> |
|
5 | 5 | <th><%= l(:label_board) %></th> |
|
6 | 6 | <th><%= l(:label_topic_plural) %></th> |
|
7 | 7 | <th><%= l(:label_message_plural) %></th> |
|
8 | 8 | <th><%= l(:label_message_last) %></th> |
|
9 | 9 | </tr></thead> |
|
10 | 10 | <tbody> |
|
11 | 11 | <% for board in @boards %> |
|
12 | 12 | <tr class="<%= cycle 'odd', 'even' %>"> |
|
13 | 13 | <td> |
|
14 | 14 | <%= link_to h(board.name), {:action => 'show', :id => board}, :class => "icon22 icon22-comment" %><br /> |
|
15 | 15 | <%=h board.description %> |
|
16 | 16 | </td> |
|
17 | 17 | <td align="center"><%= board.topics_count %></td> |
|
18 | 18 | <td align="center"><%= board.messages_count %></td> |
|
19 | 19 | <td> |
|
20 | 20 | <small> |
|
21 | 21 | <% if board.last_message %> |
|
22 | 22 | <%= authoring board.last_message.created_on, board.last_message.author %><br /> |
|
23 | 23 | <%= link_to_message board.last_message %> |
|
24 | 24 | <% end %> |
|
25 | 25 | </small> |
|
26 | 26 | </td> |
|
27 | 27 | </tr> |
|
28 | 28 | <% end %> |
|
29 | 29 | </tbody> |
|
30 | 30 | </table> |
|
31 | 31 | |
|
32 | 32 | <p class="other-formats"> |
|
33 | 33 | <%= l(:label_export_to) %> |
|
34 | 34 | <span><%= link_to 'Atom', {:controller => 'projects', :action => 'activity', :id => @project, :format => 'atom', :show_messages => 1, :key => User.current.rss_key}, |
|
35 | 35 | :class => 'feed' %></span> |
|
36 | 36 | </p> |
|
37 | 37 | |
|
38 | 38 | <% content_for :header_tags do %> |
|
39 | 39 | <%= auto_discovery_link_tag(:atom, {:controller => 'projects', :action => 'activity', :id => @project, :format => 'atom', :show_messages => 1, :key => User.current.rss_key}) %> |
|
40 | 40 | <% end %> |
|
41 | ||
|
42 | <% html_title l(:label_board_plural) %> |
@@ -1,59 +1,61 | |||
|
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"); 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 | <h2><%= link_to h(@board.name), :controller => 'boards', :action => 'show', :project_id => @project, :id => @board %> » <%= l(:label_message_new) %></h2> |
|
13 | 13 | <% form_for :message, @message, :url => {:controller => 'messages', :action => 'new', :board_id => @board}, :html => {:multipart => true, :id => 'message-form'} do |f| %> |
|
14 | 14 | <%= render :partial => 'messages/form', :locals => {:f => f} %> |
|
15 | 15 | <p><%= submit_tag l(:button_create) %> |
|
16 | 16 | <%= link_to_remote l(:label_preview), |
|
17 | 17 | { :url => { :controller => 'messages', :action => 'preview', :board_id => @board }, |
|
18 | 18 | :method => 'post', |
|
19 | 19 | :update => 'preview', |
|
20 | 20 | :with => "Form.serialize('message-form')", |
|
21 | 21 | :complete => "Element.scrollTo('preview')" |
|
22 | 22 | }, :accesskey => accesskey(:preview) %> | |
|
23 | 23 | <%= link_to l(:button_cancel), "#", :onclick => 'Element.hide("add-message")' %></p> |
|
24 | 24 | <% end %> |
|
25 | 25 | <div id="preview" class="wiki"></div> |
|
26 | 26 | </div> |
|
27 | 27 | |
|
28 | 28 | <h2><%=h @board.name %></h2> |
|
29 | 29 | |
|
30 | 30 | <% if @topics.any? %> |
|
31 | 31 | <table class="list messages"> |
|
32 | 32 | <thead><tr> |
|
33 | 33 | <th><%= l(:field_subject) %></th> |
|
34 | 34 | <th><%= l(:field_author) %></th> |
|
35 | 35 | <%= sort_header_tag("#{Message.table_name}.created_on", :caption => l(:field_created_on)) %> |
|
36 | 36 | <th><%= l(:label_reply_plural) %></th> |
|
37 | 37 | <%= sort_header_tag("#{Message.table_name}.updated_on", :caption => l(:label_message_last)) %> |
|
38 | 38 | </tr></thead> |
|
39 | 39 | <tbody> |
|
40 | 40 | <% @topics.each do |topic| %> |
|
41 | 41 | <tr class="message <%= cycle 'odd', 'even' %> <%= topic.sticky? ? 'sticky' : '' %> <%= topic.locked? ? 'locked' : '' %>"> |
|
42 | 42 | <td class="subject"><%= link_to h(topic.subject), { :controller => 'messages', :action => 'show', :board_id => @board, :id => topic }, :class => 'icon' %></td> |
|
43 | 43 | <td class="author" align="center"><%= topic.author %></td> |
|
44 | 44 | <td class="created_on" align="center"><%= format_time(topic.created_on) %></td> |
|
45 | 45 | <td class="replies" align="center"><%= topic.replies_count %></td> |
|
46 | 46 | <td class="last_message"> |
|
47 | 47 | <% if topic.last_reply %> |
|
48 | 48 | <%= authoring topic.last_reply.created_on, topic.last_reply.author %><br /> |
|
49 | 49 | <%= link_to_message topic.last_reply %> |
|
50 | 50 | <% end %> |
|
51 | 51 | </td> |
|
52 | 52 | </tr> |
|
53 | 53 | <% end %> |
|
54 | 54 | </tbody> |
|
55 | 55 | </table> |
|
56 | 56 | <p class="pagination"><%= pagination_links_full @topic_pages, @topic_count %></p> |
|
57 | 57 | <% else %> |
|
58 | 58 | <p class="nodata"><%= l(:label_no_data) %></p> |
|
59 | 59 | <% end %> |
|
60 | ||
|
61 | <% html_title h(@board.name) %> |
@@ -1,56 +1,58 | |||
|
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 | <%= link_to_if_authorized l(:button_edit), {:action => 'edit', :id => @topic}, :class => 'icon icon-edit' %> |
|
6 | 6 | <%= link_to_if_authorized l(:button_delete), {:action => 'destroy', :id => @topic}, :method => :post, :confirm => l(:text_are_you_sure), :class => 'icon icon-del' %> |
|
7 | 7 | </div> |
|
8 | 8 | |
|
9 | 9 | <h2><%=h @topic.subject %></h2> |
|
10 | 10 | |
|
11 | 11 | <div class="message"> |
|
12 | 12 | <p><span class="author"><%= authoring @topic.created_on, @topic.author %></span></p> |
|
13 | 13 | <div class="wiki"> |
|
14 | 14 | <%= textilizable(@topic.content, :attachments => @topic.attachments) %> |
|
15 | 15 | </div> |
|
16 | 16 | <%= link_to_attachments @topic.attachments, :no_author => true %> |
|
17 | 17 | </div> |
|
18 | 18 | <br /> |
|
19 | 19 | |
|
20 | 20 | <% unless @replies.empty? %> |
|
21 | 21 | <h3 class="icon22 icon22-comment"><%= l(:label_reply_plural) %></h3> |
|
22 | 22 | <% @replies.each do |message| %> |
|
23 | 23 | <a name="<%= "message-#{message.id}" %>"></a> |
|
24 | 24 | <div class="contextual"> |
|
25 | 25 | <%= link_to_if_authorized image_tag('edit.png'), {:action => 'edit', :id => message}, :title => l(:button_edit) %> |
|
26 | 26 | <%= link_to_if_authorized image_tag('delete.png'), {:action => 'destroy', :id => message}, :method => :post, :confirm => l(:text_are_you_sure), :title => l(:button_delete) %> |
|
27 | 27 | </div> |
|
28 | 28 | <div class="message reply"> |
|
29 | 29 | <h4><%=h message.subject %> - <%= authoring message.created_on, message.author %></h4> |
|
30 | 30 | <div class="wiki"><%= textilizable message, :content, :attachments => message.attachments %></div> |
|
31 | 31 | <%= link_to_attachments message.attachments, :no_author => true %> |
|
32 | 32 | </div> |
|
33 | 33 | <% end %> |
|
34 | 34 | <% end %> |
|
35 | 35 | |
|
36 | 36 | <% if !@topic.locked? && authorize_for('messages', 'reply') %> |
|
37 | 37 | <p><%= toggle_link l(:button_reply), "reply", :focus => 'message_content' %></p> |
|
38 | 38 | <div id="reply" style="display:none;"> |
|
39 | 39 | <% form_for :reply, @reply, :url => {:action => 'reply', :id => @topic}, :html => {:multipart => true, :id => 'message-form'} do |f| %> |
|
40 | 40 | <%= render :partial => 'form', :locals => {:f => f, :replying => true} %> |
|
41 | 41 | <%= submit_tag l(:button_submit) %> |
|
42 | 42 | <%= link_to_remote l(:label_preview), |
|
43 | 43 | { :url => { :controller => 'messages', :action => 'preview', :board_id => @board }, |
|
44 | 44 | :method => 'post', |
|
45 | 45 | :update => 'preview', |
|
46 | 46 | :with => "Form.serialize('message-form')", |
|
47 | 47 | :complete => "Element.scrollTo('preview')" |
|
48 | 48 | }, :accesskey => accesskey(:preview) %> |
|
49 | 49 | <% end %> |
|
50 | 50 | <div id="preview" class="wiki"></div> |
|
51 | 51 | </div> |
|
52 | 52 | <% end %> |
|
53 | 53 | |
|
54 | 54 | <% content_for :header_tags do %> |
|
55 | 55 | <%= stylesheet_link_tag 'scm' %> |
|
56 | 56 | <% end %> |
|
57 | ||
|
58 | <% html_title h(@topic.subject) %> |
General Comments 0
You need to be logged in to leave comments.
Login now