超级管理员奖励用户金币的功能
This commit is contained in:
parent
2e2e83bc62
commit
1d88f841d4
|
|
@ -78,10 +78,7 @@ class CommentsController < ApplicationController
|
|||
end
|
||||
|
||||
def reply
|
||||
comment = Comment.find(params[:id])
|
||||
@news = News.find comment.commented_id
|
||||
new_comment = @news.comments.build(:author_id => User.current.id, :reply_id => params[:id], :comments => params[:content], :parent_id => comment.id)
|
||||
@user_activity_id = params[:user_activity_id]
|
||||
|
||||
if new_comment.save
|
||||
update_course_activity(@news.class,@news.id)
|
||||
update_user_activity(@news.class,@news.id)
|
||||
|
|
|
|||
Loading…
Reference in New Issue