mirror of
https://github.com/kevin-DL/services.git
synced 2026-01-12 03:05:14 +00:00
call model with limits in post (#65)
This commit is contained in:
@@ -187,6 +187,8 @@ func (p *Posts) Index(ctx context.Context, req *proto.IndexRequest, rsp *proto.I
|
||||
// create a simple descending order query
|
||||
q := model.QueryEquals("created", nil)
|
||||
q.Order.Type = model.OrderTypeDesc
|
||||
q.Offset = req.Offset
|
||||
q.Limit = req.Limit
|
||||
|
||||
var posts []*proto.Post
|
||||
|
||||
|
||||
Reference in New Issue
Block a user