feat: add new snapshot for version 6 with updated schema and relationships
All checks were successful
Build Docker Image / build (push) Successful in 1m23s
All checks were successful
Build Docker Image / build (push) Successful in 1m23s
- Created a new snapshot file for version 6 of the database schema. - Added tables for arc, character, characterHistory, characterOverride, characterScrapeValidation, config, devilFruit, userCharacterHistory, account, session, user, and verification with appropriate columns and constraints. - Updated the journal to include new entries for version 6. - Modified the userCharacterHistory table to enforce unique constraints on userId and characterHistoryId. - Enhanced daily game logic to track user attempts and prevent duplicate entries for the same day.
This commit is contained in:
15
drizzle/0005_large_jane_foster.sql
Normal file
15
drizzle/0005_large_jane_foster.sql
Normal file
@@ -0,0 +1,15 @@
|
||||
PRAGMA foreign_keys=OFF;--> statement-breakpoint
|
||||
CREATE TABLE `__new_userCharacterHistory` (
|
||||
`id` text PRIMARY KEY NOT NULL,
|
||||
`userId` text,
|
||||
`characterHistoryId` text,
|
||||
`tryCount` integer NOT NULL,
|
||||
`createdAt` integer NOT NULL,
|
||||
FOREIGN KEY (`userId`) REFERENCES `user`(`id`) ON UPDATE no action ON DELETE no action,
|
||||
FOREIGN KEY (`characterHistoryId`) REFERENCES `characterHistory`(`id`) ON UPDATE no action ON DELETE no action
|
||||
);
|
||||
--> statement-breakpoint
|
||||
INSERT INTO `__new_userCharacterHistory`("id", "userId", "characterHistoryId", "tryCount", "createdAt") SELECT "id", "userId", "characterId", "tryCount", "createdAt" FROM `userCharacterHistory`;--> statement-breakpoint
|
||||
DROP TABLE `userCharacterHistory`;--> statement-breakpoint
|
||||
ALTER TABLE `__new_userCharacterHistory` RENAME TO `userCharacterHistory`;--> statement-breakpoint
|
||||
PRAGMA foreign_keys=ON;
|
||||
1
drizzle/0006_premium_mesmero.sql
Normal file
1
drizzle/0006_premium_mesmero.sql
Normal file
@@ -0,0 +1 @@
|
||||
CREATE UNIQUE INDEX `userCharacterHistory_userId_characterHistoryId_unique` ON `userCharacterHistory` (`userId`,`characterHistoryId`);
|
||||
1166
drizzle/meta/0005_snapshot.json
Normal file
1166
drizzle/meta/0005_snapshot.json
Normal file
File diff suppressed because it is too large
Load Diff
1173
drizzle/meta/0006_snapshot.json
Normal file
1173
drizzle/meta/0006_snapshot.json
Normal file
File diff suppressed because it is too large
Load Diff
@@ -36,6 +36,20 @@
|
||||
"when": 1772480377099,
|
||||
"tag": "0004_unique_lorna_dane",
|
||||
"breakpoints": true
|
||||
},
|
||||
{
|
||||
"idx": 5,
|
||||
"version": "6",
|
||||
"when": 1772562012631,
|
||||
"tag": "0005_large_jane_foster",
|
||||
"breakpoints": true
|
||||
},
|
||||
{
|
||||
"idx": 6,
|
||||
"version": "6",
|
||||
"when": 1772562364830,
|
||||
"tag": "0006_premium_mesmero",
|
||||
"breakpoints": true
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user