mirror of
https://github.com/zoriya/Kyoo.git
synced 2025-06-04 06:04:39 -04:00
Add lastPlayedAt
in watchlists & sort nextup with it
This commit is contained in:
parent
d8566355bb
commit
67d7643261
1
api/drizzle/0019_nextup.sql
Normal file
1
api/drizzle/0019_nextup.sql
Normal file
@ -0,0 +1 @@
|
|||||||
|
ALTER TABLE "kyoo"."watchlist" ADD COLUMN "last_played_at" timestamp with time zone;
|
1845
api/drizzle/meta/0019_snapshot.json
Normal file
1845
api/drizzle/meta/0019_snapshot.json
Normal file
File diff suppressed because it is too large
Load Diff
@ -134,6 +134,13 @@
|
|||||||
"when": 1744053556621,
|
"when": 1744053556621,
|
||||||
"tag": "0018_history",
|
"tag": "0018_history",
|
||||||
"breakpoints": true
|
"breakpoints": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"idx": 19,
|
||||||
|
"version": "7",
|
||||||
|
"when": 1744120518941,
|
||||||
|
"tag": "0019_nextup",
|
||||||
|
"breakpoints": true
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@ -36,10 +36,10 @@ const nextupSort = Sort(
|
|||||||
|
|
||||||
started: watchlist.startedAt,
|
started: watchlist.startedAt,
|
||||||
added: watchlist.createdAt,
|
added: watchlist.createdAt,
|
||||||
updated: watchlist.updatedAt,
|
lastPlayed: watchlist.lastPlayedAt,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
default: ["updated"],
|
default: ["lastPlayed"],
|
||||||
tablePk: entries.pk,
|
tablePk: entries.pk,
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
|
@ -30,6 +30,7 @@ export const watchlist = schema.table(
|
|||||||
score: integer(),
|
score: integer(),
|
||||||
|
|
||||||
startedAt: timestamp({ withTimezone: true, mode: "string" }),
|
startedAt: timestamp({ withTimezone: true, mode: "string" }),
|
||||||
|
lastPlayedAt: timestamp({ withTimezone: true, mode: "string" }),
|
||||||
completedAt: timestamp({ withTimezone: true, mode: "string" }),
|
completedAt: timestamp({ withTimezone: true, mode: "string" }),
|
||||||
|
|
||||||
createdAt: timestamp({ withTimezone: true, mode: "string" })
|
createdAt: timestamp({ withTimezone: true, mode: "string" })
|
||||||
|
Loading…
x
Reference in New Issue
Block a user