Add bruno

This commit is contained in:
Owen Schwartz 2024-10-06 17:42:28 -04:00
parent 81017139c5
commit 797f72e1d0
No known key found for this signature in database
GPG key ID: 8271FDFFD9E0CCBD
10 changed files with 139 additions and 5 deletions

View file

@ -202,6 +202,14 @@ export const userResources = sqliteTable("userResources", {
.references(() => resources.resourceId, { onDelete: "cascade" }),
});
export const limitsTable = sqliteTable("limits", {
limitId: integer("limitId").primaryKey({ autoIncrement: true }),
orgId: integer("orgId").references(() => orgs.orgId, { onDelete: "cascade" }),
name: text("name").notNull(),
value: integer("value").notNull(),
description: text("description"),
});
// Define the model types for type inference
export type Org = InferSelectModel<typeof orgs>;
export type User = InferSelectModel<typeof users>;
@ -223,4 +231,5 @@ export type UserAction = InferSelectModel<typeof userActions>;
export type RoleSite = InferSelectModel<typeof roleSites>;
export type UserSite = InferSelectModel<typeof userSites>;
export type RoleResource = InferSelectModel<typeof roleResources>;
export type UserResource = InferSelectModel<typeof userResources>;
export type UserResource = InferSelectModel<typeof userResources>;
export type Limit = InferSelectModel<typeof limitsTable>;