From 7b3c201469bcd0eda4c285307346bdb07deefed7 Mon Sep 17 00:00:00 2001 From: huangjingquan Date: Tue, 6 Aug 2013 16:32:37 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BA=86=E4=B8=80=E4=B8=AAbu?= =?UTF-8?q?g=EF=BC=88=E6=96=B0=E9=97=BB=E5=AD=90=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E5=BA=95=E6=A1=86=E4=B9=B1=E9=A3=9E=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/documents/_document.html.erb | 3 --- app/views/news/show.html.erb | 24 +++++++----------------- 2 files changed, 7 insertions(+), 20 deletions(-) diff --git a/app/views/documents/_document.html.erb b/app/views/documents/_document.html.erb index 20d3af415..b585f5dff 100644 --- a/app/views/documents/_document.html.erb +++ b/app/views/documents/_document.html.erb @@ -6,9 +6,6 @@ --> - - -
<%= link_to h(document.title), document_path(document) %>
diff --git a/app/views/news/show.html.erb b/app/views/news/show.html.erb index 516b46a54..bef124796 100644 --- a/app/views/news/show.html.erb +++ b/app/views/news/show.html.erb @@ -8,7 +8,8 @@ <%= delete_link news_path(@news) if User.current.allowed_to?(:manage_news, @project) %> -

<%=h @news.title %>

+

<%=h @news.title %>

+ <% if authorize_for('news', 'edit') %> --> -<% if @news.commentable? %>
-

<%= toggle_link l(:label_comment_add), "add_comment_form", :focus => "comment_comments" %>

-<%= form_tag({:controller => 'comments', :action => 'create', :id => @news}, :id => "add_comment_form", :style => "display:none;") do %> -
- <%= text_area 'comment', 'comments', :cols => 80, :rows => 15, :class => 'wiki-edit' %> - <%= wikitoolbar_for 'comment_comments' %> -
-

<%= submit_tag l(:button_add) %>

-<% end %> -<% end %> -
-

<%= l(:label_comment_plural) %>

+

<%= l(:label_comment_plural) %>

<% @comments.each do |comment| %> <% next if comment.new_record? %> @@ -54,7 +44,7 @@
<%= image_tag(url_to_avatar(comment.author), :class => "avatar")%> - + @@ -71,7 +61,7 @@ - +<% end %> <% html_title @news.title -%> <% content_for :header_tags do %> <%= stylesheet_link_tag 'scm' %> -<% end %> +<% end %> \ No newline at end of file
<%=link_to_user(comment.author) if comment.respond_to?(:author) %> 发表了<%= l(:label_comment_plural) %><%=link_to_user(comment.author) if comment.respond_to?(:author) %> 添加了<%= l(:label_comment_plural) %>

<%= textilizable(comment.comments) %>