game version re-ordering

This commit is contained in:
DecDuck
2024-10-14 20:34:23 +11:00
parent 8674ac7211
commit 329c74d3ce
18 changed files with 354 additions and 50 deletions

View File

@ -0,0 +1,9 @@
/*
Warnings:
- Added the required column `versionIndex` to the `GameVersion` table without a default value. This is not possible if the table is not empty.
*/
-- AlterTable
ALTER TABLE "GameVersion" ADD COLUMN "delta" BOOLEAN NOT NULL DEFAULT false,
ADD COLUMN "versionIndex" INTEGER NOT NULL;

View File

@ -0,0 +1,8 @@
/*
Warnings:
- You are about to drop the column `versionOrder` on the `Game` table. All the data in the column will be lost.
*/
-- AlterTable
ALTER TABLE "Game" DROP COLUMN "versionOrder";

View File

@ -91,7 +91,6 @@ model Game {
mCoverId String
mImageLibrary String[] // linked to objects in s3
versionOrder String[]
versions GameVersion[]
libraryBasePath String @unique // Base dir for all the game versions
@ -109,6 +108,9 @@ model GameVersion {
setupCommand String // Command to setup game (dependencies and such)
dropletManifest Json // Results from droplet
versionIndex Int
delta Boolean @default(false)
@@id([gameId, versionName])
}