order children previews by id_asc (#1481)
This commit is contained in:
@@ -22,10 +22,13 @@ class PostsController < ApplicationController
|
|||||||
@post = Post.find(params[:id])
|
@post = Post.find(params[:id])
|
||||||
@post_flag = PostFlag.new(:post_id => @post.id)
|
@post_flag = PostFlag.new(:post_id => @post.id)
|
||||||
@post_appeal = PostAppeal.new(:post_id => @post.id)
|
@post_appeal = PostAppeal.new(:post_id => @post.id)
|
||||||
|
|
||||||
@children_post_set = PostSets::Post.new("parent:#{@post.id} -id:#{@post.id}", 1, 200)
|
@children_post_set = PostSets::Post.new("parent:#{@post.id} -id:#{@post.id}", 1, 200)
|
||||||
|
@children_post_set.posts.reverse!
|
||||||
@parent_post_set = PostSets::Post.new("id:#{@post.parent_id} status:any")
|
@parent_post_set = PostSets::Post.new("id:#{@post.parent_id} status:any")
|
||||||
@siblings_post_set = PostSets::Post.new("parent:#{@post.parent_id} -id:#{@post.parent_id}", 1, 200)
|
@siblings_post_set = PostSets::Post.new("parent:#{@post.parent_id} -id:#{@post.parent_id}", 1, 200)
|
||||||
@siblings_post_set.posts.reverse!
|
@siblings_post_set.posts.reverse!
|
||||||
|
|
||||||
respond_with(@post)
|
respond_with(@post)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user