FIX 一级板块加载帖子列表为空的bug
This commit is contained in:
parent
f38e01edaf
commit
529e8e5fe6
|
@ -366,7 +366,7 @@ class ForumSectionsService
|
||||||
unless @forum_section.parent_id.present?
|
unless @forum_section.parent_id.present?
|
||||||
children_forums = @forum_section.child_ids
|
children_forums = @forum_section.child_ids
|
||||||
select_section_ids = select_section_ids + children_forums
|
select_section_ids = select_section_ids + children_forums
|
||||||
end
|
#end
|
||||||
select_section_ids.uniq
|
select_section_ids.uniq
|
||||||
|
|
||||||
# page = params[:page].to_i
|
# page = params[:page].to_i
|
||||||
|
@ -418,7 +418,7 @@ class ForumSectionsService
|
||||||
unless @forum_section.parent_id.present?
|
unless @forum_section.parent_id.present?
|
||||||
children_forums = @forum_section.child_ids
|
children_forums = @forum_section.child_ids
|
||||||
select_section_ids = select_section_ids + children_forums
|
select_section_ids = select_section_ids + children_forums
|
||||||
end
|
# end
|
||||||
select_section_ids.uniq
|
select_section_ids.uniq
|
||||||
|
|
||||||
# page = params[:page].to_i
|
# page = params[:page].to_i
|
||||||
|
@ -461,10 +461,10 @@ class ForumSectionsService
|
||||||
return {status: -1, message: "请登录"} unless check_user_permission(current_user, params[:id])
|
return {status: -1, message: "请登录"} unless check_user_permission(current_user, params[:id])
|
||||||
|
|
||||||
select_section_ids = [params[:id]]
|
select_section_ids = [params[:id]]
|
||||||
unless @forum_section.parent_id.present?
|
# unless @forum_section.parent_id.present?
|
||||||
children_forums = @forum_section.child_ids
|
children_forums = @forum_section.child_ids
|
||||||
select_section_ids = select_section_ids + children_forums
|
select_section_ids = select_section_ids + children_forums
|
||||||
end
|
# end
|
||||||
select_section_ids.uniq
|
select_section_ids.uniq
|
||||||
|
|
||||||
# page = params[:page].to_i
|
# page = params[:page].to_i
|
||||||
|
|
Loading…
Reference in New Issue