Ignore:
Timestamp:
01/28/26 12:12:43 (5 months ago)
Author:
Tome <gjorgievtome@…>
Branches:
main
Children:
a744c90
Parents:
ad211d1
Message:

Fix missing attribute in buildComponents relation

File:
1 edited

Legend:

Unmodified
Added
Removed
  • database/drizzle/schema/builds.ts

    rad211d1 re03e6fb  
    1717
    1818export const buildComponentsTable = pgTable("build_component", {
    19         id: serial("id").primaryKey(),
    2019        buildId: integer("build_id")
    2120            .notNull()
     
    2423            .notNull()
    2524            .references(() => componentsTable.id, { onDelete: "cascade", onUpdate: "cascade" }),
     25        numComponents: integer("num_components")
     26            .notNull()
     27            .default(1),
    2628    },
     29    (t) => ({
     30        pk: primaryKey({ columns: [t.buildId, t.componentId] }),
     31    }),
    2732);
    2833
Note: See TracChangeset for help on using the changeset viewer.