Create the CMS-owned feature tables in the live DB (amx_test)
The live DB lacked 32 tables the conversion's own CMS features need (radio_*, game_*/challenges, staff_activities, alert_logs, email_templates, social_accounts, website_article_comments/reactions). Generated idempotent CREATE TABLE DDL from `prisma migrate diff` (CREATE statements ONLY — every ALTER/DROP excluded so no emulator-owned table is ever touched), as migration 0004. Applied to amx_test via the existing idempotent runner. 0005: radio_listener_points shipped as a stub (id+timestamps); the /radio/leaderboard raw query needs user_id + points, so add them (model + ALTER migration). Verified against amx_test: drift check now reports 0 missing modeled tables (live tables 255 -> 287), and a full route sweep logs ZERO prisma errors (radio/leaderboard + all radio pages 200). tsc 0, vitest 49/49, next build 0.
This commit is contained in:
1 parent
b97a88c561
commit
61a5fab0d9
3 files changed
+450
No files matched your search
@@ -2106,6 +2106,8 @@ model RadioGiveaways {
|
||||
|
||||
model RadioListenerPoints {
|
||||
id BigInt @id @default(autoincrement()) @db.UnsignedBigInt
|
||||
userId Int @map("user_id")
|
||||
points Int @default(0)
|
||||
createdAt DateTime? @map("created_at") @db.Timestamp(0)
|
||||
updatedAt DateTime? @map("updated_at") @db.Timestamp(0)
|
||||
|
||||
|
||||
Reference in new issue
Block a user