feat: convert board router to supabase
This commit is contained in:
@@ -1,11 +1,5 @@
|
||||
import { sql } from '@vercel/postgres'
|
||||
import { drizzle } from 'drizzle-orm/vercel-postgres'
|
||||
import { createClient } from '@supabase/supabase-js'
|
||||
import { type Database } from "~/types/database.types";
|
||||
const supabaseUrl = process.env.NEXT_PUBLIC_SUPABASE_URL;
|
||||
const supabaseKey = process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY;
|
||||
|
||||
export const supabase = createClient<Database>(supabaseUrl!, supabaseKey!);
|
||||
|
||||
import * as schema from "./schema";
|
||||
|
||||
|
||||
1
src/server/db/migrations/0001_stale_mattie_franklin.sql
Normal file
1
src/server/db/migrations/0001_stale_mattie_franklin.sql
Normal file
@@ -0,0 +1 @@
|
||||
ALTER TABLE "board" ALTER COLUMN "deletedAt" DROP DEFAULT;
|
||||
1179
src/server/db/migrations/meta/0001_snapshot.json
Normal file
1179
src/server/db/migrations/meta/0001_snapshot.json
Normal file
File diff suppressed because it is too large
Load Diff
@@ -8,6 +8,13 @@
|
||||
"when": 1711571659259,
|
||||
"tag": "0000_legal_quicksilver",
|
||||
"breakpoints": true
|
||||
},
|
||||
{
|
||||
"idx": 1,
|
||||
"version": "5",
|
||||
"when": 1713021051974,
|
||||
"tag": "0001_stale_mattie_franklin",
|
||||
"breakpoints": true
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -27,7 +27,7 @@ export const boards = pgTable(
|
||||
createdBy: uuid("createdBy").notNull().references(() => users.id),
|
||||
createdAt: timestamp("createdAt").defaultNow().notNull(),
|
||||
updatedAt: timestamp("updatedAt"),
|
||||
deletedAt: timestamp("deletedAt").defaultNow(),
|
||||
deletedAt: timestamp("deletedAt"),
|
||||
deletedBy: uuid("deletedBy").references(() => users.id),
|
||||
importId: bigint("importId", { mode: "number" }).references(() => imports.id),
|
||||
workspaceId: bigint("workspaceId", { mode: "number" }).notNull().references(() => workspaces.id),
|
||||
|
||||
Reference in New Issue
Block a user