实训评论的子回复不再隐藏

dev_forum
daiao 5 years ago
parent d9eb84eafc
commit 8d522fe57e

@ -41,9 +41,7 @@ class Discuss < ApplicationRecord
# end
def child_discuss(user)
user.admin? ?
Discuss.where(parent_id: self.id).includes(:user).reorder(created_at: :asc) :
Discuss.where(parent_id: self.id, :hidden => false).includes(:user).reorder(created_at: :asc)
Discuss.where(parent_id: self.id).includes(:user).reorder(created_at: :asc)
end
private

Loading…
Cancel
Save