mirror of
https://github.com/Portabase/portabase.git
synced 2026-07-14 11:16:13 +02:00
feat: migration-tool (#269)
* feat: working on migration backup tool * feat: add migration sequences * fix: responsive for migration tool * fix: truncate database name in migration * fix: filter on databases success for migration tool --------- Co-authored-by: charles-gauthereau <charles.gauthereau@soluce-technologies.com>
This commit is contained in:
co-authored by
charles-gauthereau
parent
ab55ab349a
commit
ff28a80d7c
@@ -0,0 +1 @@
|
||||
ALTER TABLE "backups" ADD COLUMN "migrated" boolean DEFAULT false;
|
||||
File diff suppressed because it is too large
Load Diff
@@ -372,6 +372,13 @@
|
||||
"when": 1775803959723,
|
||||
"tag": "0052_cute_punisher",
|
||||
"breakpoints": true
|
||||
},
|
||||
{
|
||||
"idx": 53,
|
||||
"version": "7",
|
||||
"when": 1777204042208,
|
||||
"tag": "0053_lyrical_union_jack",
|
||||
"breakpoints": true
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -3,7 +3,7 @@ import {relations} from "drizzle-orm";
|
||||
import {Organization, organization} from "./03_organization";
|
||||
import {createSelectSchema} from "drizzle-zod";
|
||||
import {z} from "zod";
|
||||
import {Database, database} from "./07_database";
|
||||
import {Database, database, DatabaseWith} from "./07_database";
|
||||
import {timestamps} from "@/db/schema/00_common";
|
||||
|
||||
export const project = pgTable("projects", {
|
||||
@@ -32,3 +32,9 @@ export type ProjectWith = Project & {
|
||||
databases: Database[];
|
||||
organization: Organization;
|
||||
};
|
||||
|
||||
export type ProjectWithDatabasesAndBackups = Project & {
|
||||
databases: DatabaseWith[];
|
||||
organization: Organization;
|
||||
};
|
||||
|
||||
|
||||
@@ -42,6 +42,7 @@ export const backup = pgTable(
|
||||
.notNull()
|
||||
.references(() => database.id, {onDelete: "cascade"}),
|
||||
imported: boolean('imported').default(false),
|
||||
migrated: boolean('migrated').default(false),
|
||||
...timestamps
|
||||
},
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user