mirror of
https://github.com/Portabase/portabase.git
synced 2026-07-14 11:16:13 +02:00
Ready for 1.1.5-rc.1
This commit is contained in:
@@ -0,0 +1 @@
|
||||
ALTER TABLE "agents" ADD COLUMN "version" text;
|
||||
File diff suppressed because it is too large
Load Diff
@@ -85,6 +85,13 @@
|
||||
"when": 1765097874110,
|
||||
"tag": "0011_outgoing_blob",
|
||||
"breakpoints": true
|
||||
},
|
||||
{
|
||||
"idx": 12,
|
||||
"version": "7",
|
||||
"when": 1766308683196,
|
||||
"tag": "0012_peaceful_leopardon",
|
||||
"breakpoints": true
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -8,9 +8,6 @@ import {member, OrganizationMember} from "@/db/schema/04_member";
|
||||
import {User} from "@/db/schema/02_user";
|
||||
import {timestamps} from "@/db/schema/00_common";
|
||||
import {NotificationChannel, organizationNotificationChannel} from "@/db/schema/09_notification-channel";
|
||||
import {Agent} from "@/db/schema/08_agent";
|
||||
import {AlertPolicy} from "@/db/schema/10_alert-policy";
|
||||
import {Backup, Database, Restoration, RetentionPolicy} from "@/db/schema/07_database";
|
||||
|
||||
export const organization = pgTable("organization", {
|
||||
id: uuid("id").defaultRandom().primaryKey(),
|
||||
|
||||
@@ -1,25 +1,30 @@
|
||||
import {boolean, pgTable, text, timestamp, uuid} from "drizzle-orm/pg-core";
|
||||
import { createSelectSchema } from "drizzle-zod";
|
||||
import { z } from "zod";
|
||||
import {database} from "@/db/schema/07_database";
|
||||
import {createSelectSchema} from "drizzle-zod";
|
||||
import {z} from "zod";
|
||||
import {Database, database} from "@/db/schema/07_database";
|
||||
import {relations} from "drizzle-orm";
|
||||
import {timestamps} from "@/db/schema/00_common";
|
||||
|
||||
export const agent = pgTable("agents", {
|
||||
id: uuid("id").primaryKey().defaultRandom(),
|
||||
slug: text("slug").notNull().unique(),
|
||||
version: text("version"),
|
||||
name: text("name").notNull().notNull(),
|
||||
description: text("description").notNull(),
|
||||
isArchived: boolean("is_archived").default(false),
|
||||
lastContact: timestamp("last_contact"),
|
||||
...timestamps
|
||||
|
||||
});
|
||||
|
||||
export const agentSchema = createSelectSchema(agent);
|
||||
export type Agent = z.infer<typeof agentSchema>;
|
||||
|
||||
|
||||
export const agentRelations = relations(agent, ({ many }) => ({
|
||||
export const agentRelations = relations(agent, ({many}) => ({
|
||||
databases: many(database),
|
||||
}));
|
||||
}));
|
||||
|
||||
|
||||
export type AgentWith = Agent & {
|
||||
databases?: Database[] | null;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user