v0.0.166
This commit is contained in:
parent
21d241f9b1
commit
ac5ad640bd
@ -3,6 +3,7 @@ package wmo
|
||||
import (
|
||||
"context"
|
||||
"go.mongodb.org/mongo-driver/bson"
|
||||
"go.mongodb.org/mongo-driver/mongo"
|
||||
ct "gogs.mikescher.com/BlackForestBytes/goext/cursortoken"
|
||||
)
|
||||
|
||||
@ -11,9 +12,16 @@ func (c *Coll[TData]) List(ctx context.Context, filter ct.Filter, pageSize *int,
|
||||
return make([]TData, 0), ct.End(), nil
|
||||
}
|
||||
|
||||
pipeline := filter.FilterQuery()
|
||||
pipeline := mongo.Pipeline{}
|
||||
pf1 := "_id"
|
||||
pd1 := ct.SortASC
|
||||
pf2 := "_id"
|
||||
pd2 := ct.SortASC
|
||||
|
||||
pf1, pd1, pf2, pd2 := filter.Pagination()
|
||||
if filter != nil {
|
||||
pipeline = filter.FilterQuery()
|
||||
pf1, pd1, pf2, pd2 = filter.Pagination()
|
||||
}
|
||||
|
||||
sortPrimary := pf1
|
||||
sortDirPrimary := pd1
|
||||
|
Loading…
Reference in New Issue
Block a user