Fix paging cursor sort-direction flag

Fixes issue cortezaproject/corteza-webapp-compose#213
This commit is contained in:
Denis Arh
2021-01-25 16:45:21 +01:00
committed by Jože Fortun
parent 9dd7a609e9
commit 34d9f6bf7b
16 changed files with 69 additions and 35 deletions
+1 -1
View File
@@ -651,7 +651,7 @@ func (s Store) internal{{ export $.Types.Singular }}Encoder(res *{{ $.Types.GoTy
// undeleted items)
func (s Store) collect{{ export $.Types.Singular }}CursorValues({{ template "extraArgsDef" $ }}res *{{ $.Types.GoType }}, cc ...*filter.SortExpr) *filter.PagingCursor {
var (
cursor = &filter.PagingCursor{}
cursor = &filter.PagingCursor{LThen: filter.SortExprSet(cc).Reversed()}
hasUnique bool