Update hivegrid-cloud reference to latest main

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
davidandClaude Fable 5 committed 2026-07-08 16:15:37 +02:00
1 parent e98d38e716
commit 7b21524c86
3781 files changed
+373484 -225607

No files matched your search

@@ -1,44 +1,5 @@
import { getDbClient } from "./client.server.js";
import type { EntityWebhook, EntityWebhookLog, Log, Prisma } from "./prisma-browser.js";
export type LegacyEntityWebhook = Pick<EntityWebhook, "id" | "method" | "endpoint">;
export type LegacyRowLogCreateData = {
tenantId: string | null;
userId?: string | null;
apiKeyId?: string | null;
url: string;
rowId?: string | null;
action: string;
details?: string | null;
commentId?: string | null;
};
export type LegacyLogWriterClient = {
log: {
create(args: {
data: {
tenantId: string | null;
userId: string | null;
apiKeyId: string | null;
url: string;
rowId: string | null;
action: string;
details: string | null;
commentId: string | null;
};
}): Promise<Log>;
};
};
export type LegacyEntityWebhookClient = {
entityWebhook: {
findMany(args: { where: { entityId: string; action: string } }): Promise<LegacyEntityWebhook[]>;
};
entityWebhookLog: {
create(args: { data: { webhookId: string; logId: string; status: number } }): Promise<EntityWebhookLog>;
};
};
import type { Log, Prisma } from "./prisma-browser.js";
export type AdminAuditLogFilters = {
q?: string | null;
@@ -68,7 +29,6 @@ export type AdminAuditLogRow = Log & {
tenant?: { id: string; name: string; slug?: string | null } | null;
user?: { id: string; email: string; firstName?: string | null; lastName?: string | null } | null;
apiKey?: { id: string; alias: string } | null;
comment?: { id: string; value: string } | null;
};
export type AdminAuditLogListResult = {
@@ -95,7 +55,6 @@ export const adminAuditLogInclude = {
user: { select: { id: true, email: true, firstName: true, lastName: true } },
tenant: { select: { id: true, name: true, slug: true } },
apiKey: { select: { id: true, alias: true } },
comment: { select: { id: true, value: true } },
} satisfies Prisma.LogInclude;
const DEFAULT_AUDIT_LOG_TAKE = 50;
@@ -177,29 +136,6 @@ export function serializeAdminAuditLogsCsv(rows: readonly AdminAuditLogRow[]): s
return `${lines.join("\n")}\n`;
}
export async function createLegacyRowLog(data: LegacyRowLogCreateData, client: LegacyLogWriterClient = getDbClient() as unknown as LegacyLogWriterClient): Promise<Log> {
return client.log.create({
data: {
tenantId: data.tenantId,
userId: data.userId ?? null,
apiKeyId: data.apiKeyId ?? null,
url: data.url,
rowId: data.rowId ?? null,
action: data.action,
details: redactLogDetails(data.details),
commentId: data.commentId ?? null,
},
});
}
export async function getLegacyEntityWebhooksByAction(entityId: string, action: string, client: LegacyEntityWebhookClient = getDbClient() as unknown as LegacyEntityWebhookClient): Promise<LegacyEntityWebhook[]> {
return client.entityWebhook.findMany({ where: { entityId, action } });
}
export async function createLegacyEntityWebhookLog(data: { webhookId: string; logId: string; status: number }, client: LegacyEntityWebhookClient = getDbClient() as unknown as LegacyEntityWebhookClient): Promise<EntityWebhookLog> {
return client.entityWebhookLog.create({ data });
}
async function getAuditLogListWithWhere(
where: Prisma.LogWhereInput,
args: { take?: number | null; skip?: number | null },