GET comments of article is paginate

This commit is contained in:
2019-10-01 09:54:18 +02:00
parent 3a77eff86e
commit be03bc4df8
5 changed files with 23 additions and 9 deletions

View File

@@ -30,7 +30,6 @@ begin
and created_by_id = _created_by_id
order by
created_at desc,
com.created_at desc
limit "limit" offset "offset"

View File

@@ -17,7 +17,7 @@ begin
find_citizen_by_id(com.created_by_id) as created_by
from "comment" as com
where parent_id = _parent_id
order by created_at desc,
order by created_at asc,
com.created_at desc
limit "limit" offset "offset"
) as t;

View File

@@ -17,7 +17,7 @@ begin
find_citizen_by_id(com.created_by_id) as created_by
from "comment" as com
where com.parent_id = _target_id
order by created_at desc,
order by created_at asc,
com.created_at desc
limit "limit" offset "offset"
) as t;