mirror of
https://github.com/Dokploy/dokploy.git
synced 2026-06-15 20:25:23 +02:00
feat: add patch table and related constraints
- Introduced a new SQL file to create a "patch" table with a custom ENUM type "patchType" for tracking changes. - Added foreign key constraints linking "applicationId" and "composeId" to their respective tables. - Removed the previous SQL file that contained redundant definitions for the "patchType" and its column in the "patch" table.
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
CREATE TYPE "public"."patchType" AS ENUM('create', 'update', 'delete');--> statement-breakpoint
|
||||
CREATE TABLE "patch" (
|
||||
"patchId" text PRIMARY KEY NOT NULL,
|
||||
"type" "patchType" DEFAULT 'update' NOT NULL,
|
||||
"filePath" text NOT NULL,
|
||||
"enabled" boolean DEFAULT true NOT NULL,
|
||||
"content" text NOT NULL,
|
||||
@@ -1,2 +0,0 @@
|
||||
CREATE TYPE "public"."patchType" AS ENUM('create', 'update', 'delete');--> statement-breakpoint
|
||||
ALTER TABLE "patch" ADD COLUMN "type" "patchType" DEFAULT 'update' NOT NULL;
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"id": "5ba7ed04-440d-49a1-a7b6-8d4f4b147fc8",
|
||||
"id": "ec86a5ad-8776-483e-a003-346d32f65089",
|
||||
"prevId": "50c73964-11f8-41d6-a282-780e38bdddd9",
|
||||
"version": "7",
|
||||
"dialect": "postgresql",
|
||||
@@ -4983,6 +4983,14 @@
|
||||
"primaryKey": true,
|
||||
"notNull": true
|
||||
},
|
||||
"type": {
|
||||
"name": "type",
|
||||
"type": "patchType",
|
||||
"typeSchema": "public",
|
||||
"primaryKey": false,
|
||||
"notNull": true,
|
||||
"default": "'update'"
|
||||
},
|
||||
"filePath": {
|
||||
"name": "filePath",
|
||||
"type": "text",
|
||||
@@ -7343,6 +7351,15 @@
|
||||
"teams"
|
||||
]
|
||||
},
|
||||
"public.patchType": {
|
||||
"name": "patchType",
|
||||
"schema": "public",
|
||||
"values": [
|
||||
"create",
|
||||
"update",
|
||||
"delete"
|
||||
]
|
||||
},
|
||||
"public.protocolType": {
|
||||
"name": "protocolType",
|
||||
"schema": "public",
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1020,15 +1020,8 @@
|
||||
{
|
||||
"idx": 145,
|
||||
"version": "7",
|
||||
"when": 1771307553867,
|
||||
"tag": "0145_bitter_vivisector",
|
||||
"breakpoints": true
|
||||
},
|
||||
{
|
||||
"idx": 146,
|
||||
"version": "7",
|
||||
"when": 1771315685460,
|
||||
"tag": "0146_clammy_titanium_man",
|
||||
"when": 1771447229358,
|
||||
"tag": "0145_remarkable_titania",
|
||||
"breakpoints": true
|
||||
}
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user