mirror of
https://github.com/fosrl/pangolin.git
synced 2026-03-03 01:06:39 +00:00
Filtering on all tables
This commit is contained in:
@@ -55,6 +55,7 @@ export const queryAccessAuditLogsQuery = z.object({
|
||||
.optional(),
|
||||
actor: z.string().optional(),
|
||||
type: z.string().optional(),
|
||||
location: z.string().optional(),
|
||||
limit: z
|
||||
.string()
|
||||
.optional()
|
||||
@@ -91,6 +92,7 @@ function getWhere(data: Q) {
|
||||
? eq(accessAuditLog.actorType, data.actorType)
|
||||
: undefined,
|
||||
data.actorId ? eq(accessAuditLog.actorId, data.actorId) : undefined,
|
||||
data.location ? eq(accessAuditLog.location, data.location) : undefined,
|
||||
data.type ? eq(accessAuditLog.type, data.type) : undefined,
|
||||
data.action !== undefined
|
||||
? eq(accessAuditLog.action, data.action)
|
||||
|
||||
Reference in New Issue
Block a user