mirror of
https://github.com/p-stream/backend.git
synced 2026-01-11 20:10:33 +00:00
add group var to bookmarks
This commit is contained in:
parent
d229a2fc84
commit
ba50d9760b
4 changed files with 5 additions and 1 deletions
|
|
@ -0,0 +1,2 @@
|
|||
-- AlterTable
|
||||
ALTER TABLE "bookmarks" ADD COLUMN "group" TEXT;
|
||||
|
|
@ -1,3 +1,3 @@
|
|||
# Please do not edit this file manually
|
||||
# It should be added in your version-control system (e.g., Git)
|
||||
provider = "postgresql"
|
||||
provider = "postgresql"
|
||||
|
|
|
|||
|
|
@ -13,6 +13,7 @@ model bookmarks {
|
|||
user_id String @db.VarChar(255)
|
||||
meta Json
|
||||
updated_at DateTime @db.Timestamptz(0)
|
||||
group String?
|
||||
|
||||
@@id([tmdb_id, user_id])
|
||||
@@unique([tmdb_id, user_id], map: "bookmarks_tmdb_id_user_id_unique")
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@ const bookmarkMetaSchema = z.object({
|
|||
year: z.number(),
|
||||
poster: z.string().optional(),
|
||||
type: z.enum(['movie', 'show']),
|
||||
group: z.string().optional(),
|
||||
});
|
||||
|
||||
// Support both formats: direct fields or nested under meta
|
||||
|
|
|
|||
Loading…
Reference in a new issue