summaryrefslogtreecommitdiff
path: root/db/schema/techVendors.ts
diff options
context:
space:
mode:
Diffstat (limited to 'db/schema/techVendors.ts')
-rw-r--r--db/schema/techVendors.ts30
1 files changed, 17 insertions, 13 deletions
diff --git a/db/schema/techVendors.ts b/db/schema/techVendors.ts
index 55060adf..dcf73611 100644
--- a/db/schema/techVendors.ts
+++ b/db/schema/techVendors.ts
@@ -11,29 +11,28 @@ export const techVendors = pgTable("tech_vendors", {
id: serial("id").primaryKey(),
vendorName: varchar("vendor_name", { length: 255 }).notNull(),
vendorCode: varchar("vendor_code", { length: 100 }),
- taxId: varchar("tax_id", { length: 100 }).notNull(),
- address: text("address"),
+ taxId: varchar("tax_id", { length: 100 }),
country: varchar("country", { length: 100 }),
+ countryEng: varchar("country_eng", { length: 100 }),
+ countryFab: varchar("country_fab", { length: 100 }),
+ agentName: varchar("agent_name", { length: 255 }),
+ agentPhone: varchar("agent_phone", { length: 50 }),
+ agentEmail: varchar("agent_email", { length: 255 }),
+ address: varchar("address", { length: 255 }),
phone: varchar("phone", { length: 50 }),
email: varchar("email", { length: 255 }),
website: varchar("website", { length: 255 }),
- // 벤더 타입 추가
- techVendorType: varchar("tech_vendor_type", {
- length: 20,
- enum: VENDOR_TYPES
- }).notNull(),
- // 상태 필드 추가
+ // 벤더 타입을 다중 선택 가능하도록 text 타입으로 변경 (JSON 배열 저장)
+ techVendorType: text("tech_vendor_type").notNull(),
+ // 상태 필드 - 더 많은 상태 추가
status: varchar("status", {
length: 30,
enum: [
- "PENDING_REVIEW",
- "IN_REVIEW",
- "REJECTED",
"ACTIVE",
"INACTIVE",
"BLACKLISTED"
]
- }).default("PENDING_REVIEW").notNull(),
+ }).default("ACTIVE").notNull(),
// 대표자 정보
representativeName: varchar("representative_name", { length: 255 }),
representativeEmail: varchar("representative_email", { length: 255 }),
@@ -108,6 +107,11 @@ export const techVendorDetailView = pgView("tech_vendor_detail_view").as((qb) =>
taxId: techVendors.taxId,
address: techVendors.address,
country: techVendors.country,
+ countryEng: techVendors.countryEng,
+ countryFab: techVendors.countryFab,
+ agentName: techVendors.agentName,
+ agentPhone: techVendors.agentPhone,
+ agentEmail: techVendors.agentEmail,
phone: techVendors.phone,
email: techVendors.email,
website: techVendors.website,
@@ -203,7 +207,7 @@ export const techVendorCandidates = pgTable("tech_vendor_candidates", {
contactEmail: varchar("contact_email", { length: 255 }),
contactPhone: varchar("contact_phone", { length: 50 }),
- taxId: varchar("tax_id", { length: 100 }).notNull(),
+ taxId: varchar("tax_id", { length: 100 }),
address: text("address"),
country: varchar("country", { length: 100 }),