From 847bb35906fbe09d57be6d7392ff5df0df14e607 Mon Sep 17 00:00:00 2001 From: z9hang Date: Wed, 30 Jul 2014 10:00:07 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=AD=A3=E8=B0=B7=E6=AD=8C=E6=B5=8F?= =?UTF-8?q?=E8=A7=88=E5=99=A8=E8=B4=B4=E5=90=A7=E5=9B=BE=E6=A0=87=E5=81=8F?= =?UTF-8?q?=E7=A7=BB=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/forums/show.html.erb | 31 ++++++++++++++++--------------- 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/app/views/forums/show.html.erb b/app/views/forums/show.html.erb index 34fc953da..d558abe3f 100644 --- a/app/views/forums/show.html.erb +++ b/app/views/forums/show.html.erb @@ -31,24 +31,25 @@ <% #= link_to '发布帖子', new_forum_memo_path(@forum), :class => 'icon icon-add' %> + + <%= link_to( + image_tag('edit.png')+l(:label_forum_edit), + {:action => 'edit', :id => @forum}, + :method => 'get', + :title => l(:button_edit) + ) if @forum.editable_by?(User.current) %> + <%= link_to( + image_tag('delete.png')+'删除讨论区', + {:action => 'destroy', :id => @forum}, + :method => :delete, + :data => {:confirm => l(:text_are_you_sure)}, + :title => l(:button_delete) + ) if @forum.destroyable_by?(User.current) %> + <%= link_to l(:label_memo_new_from_forum), new_forum_memo_path(@forum), :class => 'icon icon-add', :onclick => 'showAndScrollTo("add-memo", "memo_subject"); return false;' if User.current.logged? %> -
- <%= link_to( - image_tag('edit.png')+l(:label_forum_edit), - {:action => 'edit', :id => @forum}, - :method => 'get', - :title => l(:button_edit) - ) if @forum.editable_by?(User.current) %> - <%= link_to( - image_tag('delete.png')+'删除讨论区', - {:action => 'destroy', :id => @forum}, - :method => :delete, - :data => {:confirm => l(:text_are_you_sure)}, - :title => l(:button_delete) - ) if @forum.destroyable_by?(User.current) %> -
+ <%= render :partial => 'forums/show_topics', :locals => {:memos => @memos} %>