implement graphQL and init postgres
This commit is contained in:
@@ -107,7 +107,7 @@ func DefaultPagination() PaginationRequest {
|
||||
return PaginationRequest{
|
||||
Page: 1,
|
||||
Limit: 10,
|
||||
Sort: "dateCreated",
|
||||
Sort: "created_at",
|
||||
Order: "desc",
|
||||
}
|
||||
}
|
||||
@@ -121,7 +121,7 @@ func (p *PaginationRequest) Validate() {
|
||||
p.Limit = 10
|
||||
}
|
||||
if p.Sort == "" {
|
||||
p.Sort = "dateCreated"
|
||||
p.Sort = "created_at"
|
||||
}
|
||||
if p.Order != "asc" && p.Order != "desc" {
|
||||
p.Order = "desc"
|
||||
|
||||
Reference in New Issue
Block a user