A decentralized music tracking and discovery platform built on AT Protocol 馃幍
at feat/discord-webhook 20 lines 673 B view raw
1import type { InferInsertModel, InferSelectModel } from "drizzle-orm"; 2import { pgTable, text, timestamp } from "drizzle-orm/pg-core"; 3import shouts from "./shouts"; 4import users from "./users"; 5 6const shoutReports = pgTable("shout_reports", { 7 id: text("xata_id").primaryKey(), 8 userId: text("user_id") 9 .notNull() 10 .references(() => users.id), 11 shoutId: text("shout_id") 12 .notNull() 13 .references(() => shouts.id), 14 createdAt: timestamp("xata_createdat").defaultNow().notNull(), 15}); 16 17export type SelectShoutReport = InferSelectModel<typeof shoutReports>; 18export type InsertShoutReport = InferInsertModel<typeof shoutReports>; 19 20export default shoutReports;