@@ -1,32 +1,32 | |||
|
1 | 1 | <div class="contextual"> |
|
2 | 2 | <%= link_to_if_authorized l(:button_edit), {:controller => 'news', :action => 'edit', :id => @news}, :class => 'icon icon-edit' %> |
|
3 | 3 | <%= link_to_if_authorized l(:button_delete), {:controller => 'news', :action => 'destroy', :id => @news}, :confirm => l(:text_are_you_sure), :method => :post, :class => 'icon icon-del' %> |
|
4 | 4 | </div> |
|
5 | 5 | |
|
6 | 6 | <h2><%=h @news.title %></h2> |
|
7 | 7 | |
|
8 | 8 | <p><em><% unless @news.summary.empty? %><%=h @news.summary %><br /><% end %> |
|
9 | 9 | <%= @news.author.display_name %>, <%= format_time(@news.created_on) %></em></p> |
|
10 | 10 | <br /> |
|
11 |
<%= textilizable |
|
|
11 | <%= textilizable(@news.description) %> | |
|
12 | 12 | <br /> |
|
13 | 13 | |
|
14 | 14 | <div id="comments" style="margin-bottom:16px;"> |
|
15 | 15 | <h3 class="icon22 icon22-comment"><%= l(:label_comment_plural) %></h3> |
|
16 | 16 | <% @news.comments.each do |comment| %> |
|
17 | 17 | <% next if comment.new_record? %> |
|
18 | 18 | <h4><%= format_time(comment.created_on) %> - <%= comment.author.name %></h4> |
|
19 | 19 | <div class="contextual"> |
|
20 | 20 | <%= link_to_if_authorized l(:button_delete), {:controller => 'news', :action => 'destroy_comment', :id => @news, :comment_id => comment}, :confirm => l(:text_are_you_sure), :method => :post, :class => 'icon icon-del' %> |
|
21 | 21 | </div> |
|
22 | 22 | <%= simple_format(auto_link(h comment.comment))%> |
|
23 | 23 | <% end if @news.comments_count > 0 %> |
|
24 | 24 | </div> |
|
25 | 25 | |
|
26 | 26 | <% if authorize_for 'news', 'add_comment' %> |
|
27 | 27 | <p><%= toggle_link l(:label_comment_add), "add_comment_form", :focus => "comment_comment" %></p> |
|
28 | 28 | <% form_tag({:action => 'add_comment', :id => @news}, :id => "add_comment_form", :style => "display:none;") do %> |
|
29 | 29 | <%= text_area 'comment', 'comment', :cols => 60, :rows => 6 %> |
|
30 | 30 | <p><%= submit_tag l(:button_add) %></p> |
|
31 | 31 | <% end %> |
|
32 | 32 | <% end %> No newline at end of file |
General Comments 0
You need to be logged in to leave comments.
Login now