summaryrefslogtreecommitdiff
path: root/db
diff options
context:
space:
mode:
authorjoonhoekim <26rote@gmail.com>2025-11-10 17:57:27 +0900
committerjoonhoekim <26rote@gmail.com>2025-11-10 17:57:27 +0900
commit64b16282fea10ed94dc1c4f1b81703c4875d9f7e (patch)
tree3bfcc0d1c13424b82e3bda5433c92d928f8cf537 /db
parenta8ea14922ded4589005ef44164e25d07409ec215 (diff)
(김준회) taxId 필수값에서 제거 (MDG에서 사업자번호(세금번호) 없는 벤더가 들어오기 때문)
Diffstat (limited to 'db')
-rw-r--r--db/schema/vendors.ts6
1 files changed, 4 insertions, 2 deletions
diff --git a/db/schema/vendors.ts b/db/schema/vendors.ts
index fbf094cc..25255379 100644
--- a/db/schema/vendors.ts
+++ b/db/schema/vendors.ts
@@ -21,7 +21,8 @@ export const vendors = pgTable("vendors", {
// 벤더 코드 유니크 아니어도 괜찮은지?
vendorCode: varchar("vendor_code", { length: 100 }),
//사업자번호이고, 법인등록번호는 corporateRegistrationNumber
- taxId: varchar("tax_id", { length: 100 }).notNull(),
+ // MDG에서 taxId 없이 수신되는 벤더도 저장 가능하도록 nullable로 변경
+ taxId: varchar("tax_id", { length: 100 }),
address: text("address"),
addressDetail: text("address_detail"),
postalCode: varchar("postal_code", { length: 20 }),
@@ -233,7 +234,8 @@ export const vendorCandidates = pgTable("vendor_candidates", {
contactEmail: varchar("contact_email", { length: 255 }),
contactPhone: varchar("contact_phone", { length: 50 }),
- taxId: varchar("tax_id", { length: 100 }).notNull(),
+ // 후보 업체는 사업자번호가 없을 수 있으므로 nullable로 변경
+ taxId: varchar("tax_id", { length: 100 }),
address: text("address"),
country: varchar("country", { length: 100 }),