From 8d797c5c0b5b5e9688470542de0d76e09b72e9cf Mon Sep 17 00:00:00 2001 From: guange <8863824@gmail.com> Date: Tue, 15 Dec 2015 09:09:41 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E5=8A=A8=E6=80=81=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0at?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/at_controller.rb | 5 ++++- app/views/projects/_project_activities.html.erb | 4 ++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/app/controllers/at_controller.rb b/app/controllers/at_controller.rb index 3759abf53..5664201f3 100644 --- a/app/controllers/at_controller.rb +++ b/app/controllers/at_controller.rb @@ -6,7 +6,8 @@ class AtController < ApplicationController def show @logger = Logger.new(Rails.root.join('log', 'at.log').to_s) users = find_at_users(params[:type], params[:id]) - @users = users.uniq { |u| u.id }.delete_if { |u| u.id == User.current.id } + @users = users + @users = users.uniq { |u| u.id }.delete_if { |u| u.id == User.current.id } if users end private @@ -25,6 +26,8 @@ class AtController < ApplicationController find_attachment(id) when 'Message' find_message(id) + when 'HomeworkCommon' + find_homework(id) else nil end diff --git a/app/views/projects/_project_activities.html.erb b/app/views/projects/_project_activities.html.erb index f97646d3c..bdfa0055a 100644 --- a/app/views/projects/_project_activities.html.erb +++ b/app/views/projects/_project_activities.html.erb @@ -1,4 +1,4 @@ -<%= javascript_include_tag "/assets/kindeditor/kindeditor", '/assets/kindeditor/pasteimg', "init_activity_KindEditor" %> +<%= import_ke(enable_at: true, prettify: false, init_activity: true) %>