fix(server): fix case-insensitive sort order and add indexes to improve performance (#3425)
* refactor(server): better sort mappings * refactor(server): simplify GetIndex * fix: recreate tables and indexes using proper collation Also add tests to ensure proper collation * chore: remove unused method * fix: sort expressions * fix: lint errors * fix: cleanup
This commit is contained in:
@@ -23,10 +23,10 @@ func NewShareRepository(ctx context.Context, db dbx.Builder) model.ShareReposito
|
||||
r := &shareRepository{}
|
||||
r.ctx = ctx
|
||||
r.db = db
|
||||
r.registerModel(&model.Share{}, map[string]filterFunc{})
|
||||
r.sortMappings = map[string]string{
|
||||
r.registerModel(&model.Share{}, nil)
|
||||
r.setSortMappings(map[string]string{
|
||||
"username": "username",
|
||||
}
|
||||
})
|
||||
return r
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user