diff --git a/app/views/forums/_file_form.html.erb b/app/views/forums/_file_form.html.erb index b8b0f5ff7..93c2e089f 100644 --- a/app/views/forums/_file_form.html.erb +++ b/app/views/forums/_file_form.html.erb @@ -7,7 +7,9 @@ <% if defined?(container) && container && container.saved_attachments %> <% container.attachments.each_with_index do |attachment, i| %>
@@ -48,13 +50,6 @@ <%#= button_tag "文件浏览", :type=>"button", :onclick=>"$('#_file').click();",:onmouseover => 'this.focus()',:class => 'AnnexBtn fl mt3' %> <%#= button_tag "上传附件", :id => "upload_attachments", :type=>"button", :onclick=>"$('#_file').click();",:onmouseover => 'this.focus()',:class => 'sub_btn' %> - - - - - 上传附件 - - <%= file_field_tag 'attachments[dummy][file]', :id => '_file', @@ -81,7 +76,11 @@ <%#= number_to_human_size(Setting.attachment_max_size.to_i.kilobytes) %> - + + + + 上传附件 + <% content_for :header_tags do %> <%= javascript_include_tag 'attachments' %> <% end %> diff --git a/app/views/forums/index.html.erb b/app/views/forums/index.html.erb index d583728d1..eee792a77 100644 --- a/app/views/forums/index.html.erb +++ b/app/views/forums/index.html.erb @@ -1,23 +1,23 @@- <%= @user.show_name %> > 讨论 + <%= @user.show_name %> > 论坛
-
+
+
<%= memo.subject %>
- <% if memo.sticky %>
- 顶
- <% end %>
+ <% if memo.sticky %>
+ 顶
+ <% end %>
<%= memo.content %>
- <%= memo.viewed_count %>
- <%= get_praise_num(memo) %>
- <%= Memo.where(:root_id => memo.id).count %>
-
- 最后更新:<%= time_from_now memo.updated_at %>
- <%= memo.content %>
+ <%= memo.viewed_count %>
+ <%= get_praise_num(memo) %>
+ <%= Memo.where(:root_id => memo.id).count %>
+
+
+
- <% if comment.creator_user == User.current %> - 删除 - <% end %> - | - <%= link_to( - '回复'.html_safe, - {:controller => 'users' ,:action => 'reply_to',:reply_id => comment.id, :type => memo.class.to_s, :user_activity_id => memo.id}, - :remote => true, - :method => 'get', - :title => l(:button_reply),:class => "color-grey") %> - | - - <%=render :partial=> "praise_tread/edu_praise", :locals => {:activity=>comment, :user_activity_id=>comment.id,:type=>"reply"}%> - -
-- <%= @user.show_name %> > 讨论 + <%= @user.show_name %> > 讨论
@@ -16,11 +16,11 @@
<%= h @memo.subject %> <% if @memo.sticky %> @@ -29,7 +29,7 @@
<%= @memo.author.show_name %>发表于<%= time_from_now @memo.updated_at %>
+<%= @memo.author.show_name %>发表于<%= time_from_now @memo.updated_at %>
@@ -55,7 +55,7 @@ <%= @memo.content.html_safe %>+ <% if is_teacher || comment.creator_user == User.current%> + 删除 + <% end %> + | + <%= link_to( + '回复'.html_safe, + {:controller => 'users' ,:action => 'reply_to',:reply_id => comment.id, :type => activity.class.to_s, :user_activity_id => activity.id}, + :remote => true, + :method => 'get', + :title => l(:button_reply),:class => "color-grey") %> + | + + <%=render :partial=> "praise_tread/edu_praise", :locals => {:activity=>comment, :user_activity_id=>comment.id,:type=>"reply"}%> + +
+- <% if is_teacher || comment.creator_user == User.current%> - 删除 - <% end %> - | - <%= link_to( - '回复'.html_safe, - {:controller => 'users' ,:action => 'reply_to',:reply_id => comment.id, :type => activity.class.to_s, :user_activity_id => activity.id}, - :remote => true, - :method => 'get', - :title => l(:button_reply),:class => "color-grey") %> - | - - <%=render :partial=> "praise_tread/edu_praise", :locals => {:activity=>comment, :user_activity_id=>comment.id,:type=>"reply"}%> - -
-
+ <% if comment.creator_user == User.current %> + 删除 + <% end %> + | + <%= link_to( + '回复'.html_safe, + {:controller => 'users' ,:action => 'reply_to',:reply_id => comment.id, :type => memo.class.to_s, :user_activity_id => memo.id}, + :remote => true, + :method => 'get', + :title => l(:button_reply),:class => "color-grey") %> + | + + <%=render :partial=> "praise_tread/edu_praise", :locals => {:activity=>comment, :user_activity_id=>comment.id,:type=>"reply"}%> + +
+