@drax/identity-back 0.2.0 → 0.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/graphql/resolvers/role.resolvers.js +1 -1
- package/dist/graphql/resolvers/tenant.resolvers.js +1 -1
- package/dist/graphql/resolvers/user-api-key.resolvers.js +1 -1
- package/dist/graphql/resolvers/user.resolvers.js +2 -2
- package/dist/repository/mongo/RoleMongoRepository.js +5 -2
- package/dist/repository/mongo/TenantMongoRepository.js +5 -2
- package/dist/repository/mongo/UserApiKeyMongoRepository.js +5 -16
- package/dist/repository/mongo/UserMongoRepository.js +5 -16
- package/dist/repository/sqlite/RoleSqliteRepository.js +5 -2
- package/dist/repository/sqlite/TenantSqliteRepository.js +5 -2
- package/dist/repository/sqlite/UserApiKeySqliteRepository.js +6 -18
- package/dist/repository/sqlite/UserSqliteRepository.js +6 -19
- package/dist/routes/RoleRoutes.js +2 -2
- package/dist/routes/TenantRoutes.js +2 -2
- package/dist/routes/UserApiKeyRoutes.js +2 -2
- package/dist/routes/UserRoutes.js +3 -3
- package/dist/services/RoleService.js +2 -2
- package/dist/services/TenantService.js +2 -2
- package/dist/services/UserApiKeyService.js +2 -2
- package/dist/services/UserService.js +2 -2
- package/package.json +5 -5
- package/src/graphql/resolvers/role.resolvers.ts +1 -1
- package/src/graphql/resolvers/tenant.resolvers.ts +1 -1
- package/src/graphql/resolvers/user-api-key.resolvers.ts +1 -1
- package/src/graphql/resolvers/user.resolvers.ts +2 -2
- package/src/repository/mongo/RoleMongoRepository.ts +8 -4
- package/src/repository/mongo/TenantMongoRepository.ts +8 -4
- package/src/repository/mongo/UserApiKeyMongoRepository.ts +6 -16
- package/src/repository/mongo/UserMongoRepository.ts +12 -16
- package/src/repository/sqlite/RoleSqliteRepository.ts +12 -2
- package/src/repository/sqlite/TenantSqliteRepository.ts +6 -2
- package/src/repository/sqlite/UserApiKeySqliteRepository.ts +7 -18
- package/src/repository/sqlite/UserSqliteRepository.ts +13 -20
- package/src/routes/RoleRoutes.ts +2 -2
- package/src/routes/TenantRoutes.ts +2 -2
- package/src/routes/UserApiKeyRoutes.ts +2 -2
- package/src/routes/UserRoutes.ts +3 -3
- package/src/services/RoleService.ts +2 -2
- package/src/services/TenantService.ts +2 -2
- package/src/services/UserApiKeyService.ts +2 -2
- package/src/services/UserService.ts +2 -2
- package/tsconfig.tsbuildinfo +1 -1
- package/types/graphql/resolvers/role.resolvers.d.ts +1 -1
- package/types/graphql/resolvers/tenant.resolvers.d.ts +1 -1
- package/types/graphql/resolvers/user-api-key.resolvers.d.ts +1 -1
- package/types/graphql/resolvers/user.resolvers.d.ts +1 -1
- package/types/repository/mongo/RoleMongoRepository.d.ts +1 -1
- package/types/repository/mongo/RoleMongoRepository.d.ts.map +1 -1
- package/types/repository/mongo/TenantMongoRepository.d.ts +1 -1
- package/types/repository/mongo/TenantMongoRepository.d.ts.map +1 -1
- package/types/repository/mongo/UserApiKeyMongoRepository.d.ts +1 -1
- package/types/repository/mongo/UserApiKeyMongoRepository.d.ts.map +1 -1
- package/types/repository/mongo/UserMongoRepository.d.ts +1 -1
- package/types/repository/mongo/UserMongoRepository.d.ts.map +1 -1
- package/types/repository/sqlite/RoleSqliteRepository.d.ts +1 -1
- package/types/repository/sqlite/RoleSqliteRepository.d.ts.map +1 -1
- package/types/repository/sqlite/TenantSqliteRepository.d.ts +1 -1
- package/types/repository/sqlite/TenantSqliteRepository.d.ts.map +1 -1
- package/types/repository/sqlite/UserApiKeySqliteRepository.d.ts +1 -1
- package/types/repository/sqlite/UserApiKeySqliteRepository.d.ts.map +1 -1
- package/types/repository/sqlite/UserSqliteRepository.d.ts +1 -1
- package/types/repository/sqlite/UserSqliteRepository.d.ts.map +1 -1
- package/types/services/RoleService.d.ts +1 -1
- package/types/services/RoleService.d.ts.map +1 -1
- package/types/services/TenantService.d.ts +1 -1
- package/types/services/TenantService.d.ts.map +1 -1
- package/types/services/UserApiKeyService.d.ts +1 -1
- package/types/services/UserApiKeyService.d.ts.map +1 -1
- package/types/services/UserService.d.ts +1 -1
- package/types/services/UserService.d.ts.map +1 -1
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
import {UserModel} from "../../models/UserModel.js";
|
|
2
|
-
import {
|
|
2
|
+
import {
|
|
3
|
+
mongoose,
|
|
4
|
+
MongooseErrorToValidationError,
|
|
5
|
+
MongooseQueryFilter, MongooseSort,
|
|
6
|
+
MongoServerErrorToValidationError,
|
|
7
|
+
ValidationError
|
|
8
|
+
} from "@drax/common-back"
|
|
3
9
|
import type {IUser, IUserCreate, IUserUpdate} from "@drax/identity-share";
|
|
4
10
|
import {DeleteResult, MongoServerError} from "mongodb";
|
|
5
11
|
import type {IUserRepository} from "../../interfaces/IUserRepository";
|
|
@@ -70,7 +76,7 @@ class UserMongoRepository implements IUserRepository {
|
|
|
70
76
|
page= 1,
|
|
71
77
|
limit= 5,
|
|
72
78
|
orderBy= '',
|
|
73
|
-
|
|
79
|
+
order= false,
|
|
74
80
|
search= '',
|
|
75
81
|
filters= []} : IDraxPaginateOptions): Promise<IDraxPaginateResult<IUser>> {
|
|
76
82
|
|
|
@@ -84,21 +90,11 @@ class UserMongoRepository implements IUserRepository {
|
|
|
84
90
|
]
|
|
85
91
|
}
|
|
86
92
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
query[filter.field] = {$eq: filter.value}
|
|
91
|
-
}
|
|
92
|
-
if(['ne','$ne'].includes(filter.operator)){
|
|
93
|
-
query[filter.field] = {$ne: filter.value}
|
|
94
|
-
}
|
|
95
|
-
if(['in','$in'].includes(filter.operator)){
|
|
96
|
-
query[filter.field] = {$in: filter.value}
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
}
|
|
93
|
+
MongooseQueryFilter.applyFilters(query, filters)
|
|
94
|
+
|
|
95
|
+
const sort = MongooseSort.applySort(orderBy, order)
|
|
100
96
|
|
|
101
|
-
const options = {populate: ['role','tenant'], page
|
|
97
|
+
const options = {populate: ['role','tenant'], page, limit, sort }
|
|
102
98
|
|
|
103
99
|
const userPaginated: PaginateResult<IUser> = await UserModel.paginate(query, options)
|
|
104
100
|
return {
|
|
@@ -4,7 +4,13 @@ import sqlite from "better-sqlite3";
|
|
|
4
4
|
import {randomUUID} from "node:crypto";
|
|
5
5
|
import {IDraxPaginateResult, IDraxPaginateOptions} from "@drax/common-share";
|
|
6
6
|
import {IRole, IRoleBase} from "@drax/identity-share";
|
|
7
|
-
import {
|
|
7
|
+
import {
|
|
8
|
+
SqliteErrorToValidationError,
|
|
9
|
+
SqliteTableBuilder,
|
|
10
|
+
SqliteTableField,
|
|
11
|
+
SqlQueryFilter,
|
|
12
|
+
SqlSort
|
|
13
|
+
} from "@drax/common-back";
|
|
8
14
|
|
|
9
15
|
const tableFields: SqliteTableField[] = [
|
|
10
16
|
{name: "name", type: "TEXT", unique: true, primary: false},
|
|
@@ -106,7 +112,7 @@ class RoleSqliteRepository implements IRoleRepository{
|
|
|
106
112
|
page= 1,
|
|
107
113
|
limit= 5,
|
|
108
114
|
orderBy= '',
|
|
109
|
-
|
|
115
|
+
order= false,
|
|
110
116
|
search= '',
|
|
111
117
|
filters= []} : IDraxPaginateOptions): Promise<IDraxPaginateResult<IRole>>{
|
|
112
118
|
const offset = page > 1 ? (page - 1) * limit : 0
|
|
@@ -116,7 +122,11 @@ class RoleSqliteRepository implements IRoleRepository{
|
|
|
116
122
|
where = ` WHERE name LIKE '%${search}%'`
|
|
117
123
|
}
|
|
118
124
|
|
|
125
|
+
where = SqlQueryFilter.applyFilters(where, filters)
|
|
126
|
+
const sort = SqlSort.applySort(orderBy, order)
|
|
127
|
+
|
|
119
128
|
const rCount = this.db.prepare('SELECT COUNT(*) as count FROM roles'+where).get();
|
|
129
|
+
where += sort
|
|
120
130
|
const roles = this.db.prepare('SELECT * FROM roles ' + where + ' LIMIT ? OFFSET ?').all([limit, offset]);
|
|
121
131
|
|
|
122
132
|
for (const role of roles) {
|
|
@@ -4,7 +4,7 @@ import {UUID} from "crypto";
|
|
|
4
4
|
import sqlite from "better-sqlite3";
|
|
5
5
|
import {randomUUID} from "node:crypto";
|
|
6
6
|
import {IDraxPaginateResult, IDraxPaginateOptions} from "@drax/common-share";
|
|
7
|
-
import {SqliteErrorToValidationError, SqliteTableBuilder} from "@drax/common-back";
|
|
7
|
+
import {SqliteErrorToValidationError, SqliteTableBuilder, SqlQueryFilter, SqlSort} from "@drax/common-back";
|
|
8
8
|
import type {SqliteTableField} from "@drax/common-back";
|
|
9
9
|
|
|
10
10
|
|
|
@@ -118,7 +118,7 @@ class TenantSqliteRepository implements ITenantRepository{
|
|
|
118
118
|
page= 1,
|
|
119
119
|
limit= 5,
|
|
120
120
|
orderBy= '',
|
|
121
|
-
|
|
121
|
+
order= false,
|
|
122
122
|
search= '',
|
|
123
123
|
filters= []} : IDraxPaginateOptions): Promise<IDraxPaginateResult<ITenant>>{
|
|
124
124
|
const offset = page > 1 ? (page - 1) * limit : 0
|
|
@@ -128,7 +128,11 @@ class TenantSqliteRepository implements ITenantRepository{
|
|
|
128
128
|
where = ` WHERE name LIKE '%${search}%'`
|
|
129
129
|
}
|
|
130
130
|
|
|
131
|
+
where = SqlQueryFilter.applyFilters(where, filters)
|
|
132
|
+
const sort = SqlSort.applySort(orderBy, order)
|
|
133
|
+
|
|
131
134
|
const rCount = this.db.prepare('SELECT COUNT(*) as count FROM tenants'+where).get();
|
|
135
|
+
where += sort
|
|
132
136
|
const tenants = this.db.prepare('SELECT * FROM tenants ' + where + ' LIMIT ? OFFSET ?').all([limit, offset]);
|
|
133
137
|
|
|
134
138
|
return {
|
|
@@ -4,7 +4,7 @@ import {UUID} from "crypto";
|
|
|
4
4
|
import sqlite from "better-sqlite3";
|
|
5
5
|
import {randomUUID} from "node:crypto";
|
|
6
6
|
import {IDraxPaginateResult, IDraxPaginateOptions} from "@drax/common-share";
|
|
7
|
-
import {SqliteErrorToValidationError, SqliteTableBuilder} from "@drax/common-back";
|
|
7
|
+
import {SqliteErrorToValidationError, SqliteTableBuilder, SqlQueryFilter, SqlSort} from "@drax/common-back";
|
|
8
8
|
import type {SqliteTableField} from "@drax/common-back";
|
|
9
9
|
import UserSqliteRepository from "./UserSqliteRepository.js";
|
|
10
10
|
|
|
@@ -146,7 +146,7 @@ class UserApiKeySqliteRepository implements IUserApiKeyRepository {
|
|
|
146
146
|
page = 1,
|
|
147
147
|
limit = 5,
|
|
148
148
|
orderBy = '',
|
|
149
|
-
|
|
149
|
+
order = false,
|
|
150
150
|
search = '',
|
|
151
151
|
filters = []
|
|
152
152
|
}: IDraxPaginateOptions): Promise<IDraxPaginateResult<IUserApiKey>> {
|
|
@@ -157,24 +157,13 @@ class UserApiKeySqliteRepository implements IUserApiKeyRepository {
|
|
|
157
157
|
where = ` WHERE name LIKE '%${search}%'`
|
|
158
158
|
}
|
|
159
159
|
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
if(['eq','$eq'].includes(filter.operator)){
|
|
165
|
-
whereFilters.push(` ${filter.field} = '${filter.value}' `)
|
|
166
|
-
}
|
|
167
|
-
if(['ne','$ne'].includes(filter.operator)){
|
|
168
|
-
whereFilters.push(` ${filter.field} != '${filter.value}' `)
|
|
169
|
-
}
|
|
170
|
-
if(['in','$in'].includes(filter.operator)){
|
|
171
|
-
whereFilters.push(` ${filter.field} LIKE '%${filter.value}%' `)
|
|
172
|
-
}
|
|
173
|
-
}
|
|
174
|
-
where += whereFilters.join(" AND ")
|
|
175
|
-
}
|
|
160
|
+
where = SqlQueryFilter.applyFilters(where, filters)
|
|
161
|
+
const sort = SqlSort.applySort(orderBy, order)
|
|
162
|
+
|
|
163
|
+
console.log("where", where)
|
|
176
164
|
|
|
177
165
|
const rCount = this.db.prepare('SELECT COUNT(*) as count FROM user_api_keys' + where).get();
|
|
166
|
+
where += sort
|
|
178
167
|
const userApiKeys = this.db.prepare('SELECT * FROM user_api_keys ' + where + ' LIMIT ? OFFSET ?').all([limit, offset]);
|
|
179
168
|
|
|
180
169
|
for (const userApiKey of userApiKeys) {
|
|
@@ -4,7 +4,13 @@ import {randomUUID} from "node:crypto";
|
|
|
4
4
|
import {UUID} from "crypto";
|
|
5
5
|
import {IUserRepository} from "../../interfaces/IUserRepository";
|
|
6
6
|
import {IDraxPaginateResult, IDraxPaginateOptions} from "@drax/common-share";
|
|
7
|
-
import {
|
|
7
|
+
import {
|
|
8
|
+
SqliteErrorToValidationError,
|
|
9
|
+
SqliteTableBuilder,
|
|
10
|
+
SqlQueryFilter,
|
|
11
|
+
SqlSort,
|
|
12
|
+
ValidationError
|
|
13
|
+
} from "@drax/common-back";
|
|
8
14
|
import type {SqliteTableField} from "@drax/common-back";
|
|
9
15
|
import RoleSqliteRepository from "./RoleSqliteRepository.js";
|
|
10
16
|
import TenantSqliteRepository from "./TenantSqliteRepository.js";
|
|
@@ -148,7 +154,7 @@ class UserSqliteRepository implements IUserRepository {
|
|
|
148
154
|
page= 1,
|
|
149
155
|
limit= 5,
|
|
150
156
|
orderBy= '',
|
|
151
|
-
|
|
157
|
+
order= false,
|
|
152
158
|
search= '',
|
|
153
159
|
filters= []} : IDraxPaginateOptions): Promise<IDraxPaginateResult<IUser>> {
|
|
154
160
|
|
|
@@ -159,27 +165,14 @@ class UserSqliteRepository implements IUserRepository {
|
|
|
159
165
|
where = ` WHERE (name LIKE '%${search}%' OR username LIKE '%${search}%') `
|
|
160
166
|
}
|
|
161
167
|
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
where = where ? ` AND ` : ` WHERE `
|
|
165
|
-
for(const filter of filters){
|
|
166
|
-
if(['eq','$eq'].includes(filter.operator)){
|
|
167
|
-
whereFilters.push(` ${filter.field} = '${filter.value}' `)
|
|
168
|
-
}
|
|
169
|
-
if(['ne','$ne'].includes(filter.operator)){
|
|
170
|
-
whereFilters.push(` ${filter.field} != '${filter.value}' `)
|
|
171
|
-
}
|
|
172
|
-
if(['in','$in'].includes(filter.operator)){
|
|
173
|
-
whereFilters.push(` ${filter.field} LIKE '%${filter.value}%' `)
|
|
174
|
-
}
|
|
175
|
-
}
|
|
176
|
-
where += whereFilters.join(" AND ")
|
|
177
|
-
}
|
|
168
|
+
where = SqlQueryFilter.applyFilters(where, filters)
|
|
169
|
+
const sort = SqlSort.applySort(orderBy, order)
|
|
178
170
|
|
|
179
|
-
console.log("paginate where ", where, "search", search, "filters", filters, "whereFilters", whereFilters)
|
|
180
171
|
|
|
181
|
-
|
|
172
|
+
console.log("paginate where ", where, "search", search, "filters", filters)
|
|
182
173
|
|
|
174
|
+
const rCount = this.db.prepare('SELECT COUNT(*) as count FROM users' + where).get();
|
|
175
|
+
where += sort
|
|
183
176
|
const users = this.db.prepare('SELECT * FROM users' + where + ' LIMIT ? OFFSET ?').all([limit, offset]);
|
|
184
177
|
|
|
185
178
|
for (const user of users) {
|
package/src/routes/RoleRoutes.ts
CHANGED
|
@@ -102,10 +102,10 @@ async function RoleRoutes(fastify, options) {
|
|
|
102
102
|
const page = request.query.page
|
|
103
103
|
const limit = request.query.limit
|
|
104
104
|
const orderBy = request.query.orderBy
|
|
105
|
-
const
|
|
105
|
+
const order = request.query.order
|
|
106
106
|
const search = request.query.search
|
|
107
107
|
const roleService = RoleServiceFactory()
|
|
108
|
-
let paginateResult = await roleService.paginate({page, limit, search, orderBy,
|
|
108
|
+
let paginateResult = await roleService.paginate({page, limit, search, orderBy, order})
|
|
109
109
|
return paginateResult
|
|
110
110
|
} catch (e) {
|
|
111
111
|
console.error(e)
|
|
@@ -84,10 +84,10 @@ async function TenantRoutes(fastify, options) {
|
|
|
84
84
|
const page = request.query.page
|
|
85
85
|
const limit = request.query.limit
|
|
86
86
|
const orderBy = request.query.orderBy
|
|
87
|
-
const
|
|
87
|
+
const order = request.query.order
|
|
88
88
|
const search = request.query.search
|
|
89
89
|
const tenantService = TenantServiceFactory()
|
|
90
|
-
let paginateResult = await tenantService.paginate({page, limit,orderBy,
|
|
90
|
+
let paginateResult = await tenantService.paginate({page, limit,orderBy, order, search})
|
|
91
91
|
return paginateResult
|
|
92
92
|
} catch (e) {
|
|
93
93
|
console.error(e)
|
|
@@ -27,12 +27,12 @@ async function UserApiKeyRoutes(fastify, options) {
|
|
|
27
27
|
const page = request.query.page
|
|
28
28
|
const limit = request.query.limit
|
|
29
29
|
const orderBy = request.query.orderBy
|
|
30
|
-
const
|
|
30
|
+
const order = request.query.order
|
|
31
31
|
const search = request.query.search
|
|
32
32
|
const userApiKeyService = UserApiKeyServiceFactory()
|
|
33
33
|
|
|
34
34
|
|
|
35
|
-
let paginateResult = await userApiKeyService.paginate({page, limit, orderBy,
|
|
35
|
+
let paginateResult = await userApiKeyService.paginate({page, limit, orderBy, order, search, filters})
|
|
36
36
|
return paginateResult
|
|
37
37
|
} catch (e) {
|
|
38
38
|
console.log("/api/user-api-keys",e)
|
package/src/routes/UserRoutes.ts
CHANGED
|
@@ -62,14 +62,14 @@ async function UserRoutes(fastify, options) {
|
|
|
62
62
|
const page = request.query.page
|
|
63
63
|
const limit = request.query.limit
|
|
64
64
|
const orderBy = request.query.orderBy
|
|
65
|
-
const
|
|
65
|
+
const order = request.query.order
|
|
66
66
|
const search = request.query.search
|
|
67
67
|
const userService = UserServiceFactory()
|
|
68
68
|
const filters = []
|
|
69
69
|
if(request.rbac.getAuthUser.tenantId){
|
|
70
|
-
filters.push({field: 'tenant', operator: '
|
|
70
|
+
filters.push({field: 'tenant', operator: 'eq', value: request.rbac.getAuthUser.tenantId})
|
|
71
71
|
}
|
|
72
|
-
let paginateResult = await userService.paginate({page, limit, orderBy,
|
|
72
|
+
let paginateResult = await userService.paginate({page, limit, orderBy, order, search, filters})
|
|
73
73
|
for(let item of paginateResult.items){
|
|
74
74
|
item.password = undefined
|
|
75
75
|
delete item.password
|
|
@@ -85,12 +85,12 @@ class RoleService {
|
|
|
85
85
|
page = 1,
|
|
86
86
|
limit = 5,
|
|
87
87
|
orderBy = '',
|
|
88
|
-
|
|
88
|
+
order = false,
|
|
89
89
|
search = '',
|
|
90
90
|
filters = []
|
|
91
91
|
}: IDraxPaginateOptions): Promise<IDraxPaginateResult<IRole>> {
|
|
92
92
|
try{
|
|
93
|
-
const pagination = await this._repository.paginate({page, limit, orderBy,
|
|
93
|
+
const pagination = await this._repository.paginate({page, limit, orderBy, order, search, filters});
|
|
94
94
|
return pagination;
|
|
95
95
|
}catch (e){
|
|
96
96
|
console.error("Error paginating roles", e)
|
|
@@ -92,12 +92,12 @@ class TenantService {
|
|
|
92
92
|
page = 1,
|
|
93
93
|
limit = 5,
|
|
94
94
|
orderBy = '',
|
|
95
|
-
|
|
95
|
+
order = false,
|
|
96
96
|
search = '',
|
|
97
97
|
filters = []
|
|
98
98
|
}: IDraxPaginateOptions): Promise<IDraxPaginateResult<ITenant>> {
|
|
99
99
|
try {
|
|
100
|
-
const pagination = await this._repository.paginate({page, limit, orderBy,
|
|
100
|
+
const pagination = await this._repository.paginate({page, limit, orderBy, order, search, filters});
|
|
101
101
|
return pagination;
|
|
102
102
|
} catch (e) {
|
|
103
103
|
console.error("Error paginating tenants", e)
|
|
@@ -92,12 +92,12 @@ class UserApiKeyService {
|
|
|
92
92
|
page = 1,
|
|
93
93
|
limit = 5,
|
|
94
94
|
orderBy = '',
|
|
95
|
-
|
|
95
|
+
order = false,
|
|
96
96
|
search = '',
|
|
97
97
|
filters = []
|
|
98
98
|
}: IDraxPaginateOptions): Promise<IDraxPaginateResult<IUserApiKey>> {
|
|
99
99
|
try {
|
|
100
|
-
const pagination = await this._repository.paginate({page, limit, orderBy,
|
|
100
|
+
const pagination = await this._repository.paginate({page, limit, orderBy, order, search, filters});
|
|
101
101
|
return pagination;
|
|
102
102
|
} catch (e) {
|
|
103
103
|
console.error("Error paginating userApiKeys", e)
|
|
@@ -158,12 +158,12 @@ class UserService {
|
|
|
158
158
|
page = 1,
|
|
159
159
|
limit = 5,
|
|
160
160
|
orderBy = '',
|
|
161
|
-
|
|
161
|
+
order = false,
|
|
162
162
|
search = '',
|
|
163
163
|
filters = []
|
|
164
164
|
}: IDraxPaginateOptions): Promise<IDraxPaginateResult<IUser>> {
|
|
165
165
|
try {
|
|
166
|
-
const pagination = await this._repository.paginate({page, limit, orderBy,
|
|
166
|
+
const pagination = await this._repository.paginate({page, limit, orderBy, order, search, filters});
|
|
167
167
|
return pagination;
|
|
168
168
|
} catch (e) {
|
|
169
169
|
console.error("Error paginating users", e)
|