优化下回复相关的微信动态
This commit is contained in:
parent
5ac30fe09c
commit
9911faaa49
|
@ -25,8 +25,10 @@ module Mobile
|
|||
elsif ac.act_type == "News"
|
||||
ac.nil? || ac.act.nil? ? 0 : ac.act.comments.count
|
||||
elsif ac.act_type == "Message" || ac.act_type == "BlogComment" || ac.act_type == "JournalsForMessage"
|
||||
all_comments = []
|
||||
ac.nil? || ac.act.nil? ? 0 : get_all_children(all_comments, ac.act).count
|
||||
className = ac.act_type.classify.constantize
|
||||
# all_comments = []
|
||||
# ac.nil? || ac.act.nil? ? 0 : get_all_children(all_comments, ac.act).count
|
||||
ac.nil? || ac.act.nil? ? 0 : className.where("root_id = #{ac.act.id}").count
|
||||
elsif ac.act_type == "Issue"
|
||||
ac.nil? || ac.act.nil? ? 0 : ac.act.journals.where("notes is not null and notes != ''").count
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue