diff options
| author | dujinkim <dujin.kim@dtsolution.co.kr> | 2025-03-26 00:37:41 +0000 |
|---|---|---|
| committer | dujinkim <dujin.kim@dtsolution.co.kr> | 2025-03-26 00:37:41 +0000 |
| commit | e0dfb55c5457aec489fc084c4567e791b4c65eb1 (patch) | |
| tree | 68543a65d88f5afb3a0202925804103daa91bc6f /db/schema/items.ts | |
3/25 까지의 대표님 작업사항
Diffstat (limited to 'db/schema/items.ts')
| -rw-r--r-- | db/schema/items.ts | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/db/schema/items.ts b/db/schema/items.ts new file mode 100644 index 00000000..1d4b0ded --- /dev/null +++ b/db/schema/items.ts @@ -0,0 +1,12 @@ +import { pgTable, varchar, text, timestamp ,serial} from "drizzle-orm/pg-core" + +export const items = pgTable("items", { + id: serial("id").primaryKey(), + itemCode: varchar("item_code", { length: 100 }).unique(), + itemName: varchar("item_name", { length: 255 }).notNull(), + description: text("description"), + createdAt: timestamp("created_at").defaultNow().notNull(), + updatedAt: timestamp("updated_at").defaultNow().notNull(), +}); + +export type Item = typeof items.$inferSelect |
