feature(dashboard): add conversion rate graph

This commit is contained in:
Carl-Gerhard Lindesvärd
2025-03-28 09:21:10 +01:00
parent be358ea886
commit 8a21fadc0d
23 changed files with 807 additions and 29 deletions

View File

@@ -0,0 +1,5 @@
-- DropForeignKey
ALTER TABLE "clients" DROP CONSTRAINT "clients_organizationId_fkey";
-- AddForeignKey
ALTER TABLE "clients" ADD CONSTRAINT "clients_organizationId_fkey" FOREIGN KEY ("organizationId") REFERENCES "organizations"("id") ON DELETE CASCADE ON UPDATE CASCADE;

View File

@@ -0,0 +1,2 @@
-- AlterEnum
ALTER TYPE "ChartType" ADD VALUE 'conversion';

View File

@@ -230,7 +230,7 @@ model Client {
type ClientType @default(write)
projectId String?
project Project? @relation(fields: [projectId], references: [id], onDelete: Cascade)
organization Organization @relation(fields: [organizationId], references: [id])
organization Organization @relation(fields: [organizationId], references: [id], onDelete: Cascade)
organizationId String
createdAt DateTime @default(now())
@@ -257,6 +257,7 @@ enum ChartType {
map
funnel
retention
conversion
}
model Dashboard {