fb / lib /db /src /schema /savedLists.ts
sare26's picture
Upload 83 files
312c2e2 verified
Raw
History Blame Contribute Delete
425 Bytes
import { pgTable, text, timestamp, serial, jsonb } from "drizzle-orm/pg-core";
export const savedListsTable = pgTable("saved_lists", {
id: serial("id").primaryKey(),
userId: text("user_id").notNull(),
name: text("name").notNull(),
groupIds: jsonb("group_ids").$type<string[]>().notNull(),
createdAt: timestamp("created_at").notNull().defaultNow(),
});
export type SavedList = typeof savedListsTable.$inferSelect;