feat(sync): add company details to customer addresses
Addresses with a company are completed through GET /customers_addresses/:id (tax number, company number, legal status), which the customer payload does not embed. Addresses without company get these fields set to null; a failed call keeps the stored values. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -151,19 +151,25 @@ model CustomerAddress {
|
||||
id String @id @default(uuid())
|
||||
updatedAt DateTime @updatedAt
|
||||
|
||||
address String
|
||||
city String
|
||||
company String?
|
||||
country String
|
||||
firstName String
|
||||
hiboutikId Int @unique
|
||||
isDefault Boolean @default(false)
|
||||
lastName String
|
||||
address String
|
||||
city String
|
||||
company String?
|
||||
/// Company registration number (SIRET...), only for an address with a company
|
||||
companyNumber String?
|
||||
country String
|
||||
firstName String
|
||||
hiboutikId Int @unique
|
||||
isDefault Boolean @default(false)
|
||||
lastName String
|
||||
/// Company legal status (SAS, SARL...), only for an address with a company
|
||||
legalStatus String?
|
||||
/// Free complement (building, floor, door code...)
|
||||
other String?
|
||||
phone String?
|
||||
state String?
|
||||
zipCode String
|
||||
other String?
|
||||
phone String?
|
||||
state String?
|
||||
/// Company VAT number, only for an address with a company
|
||||
taxNumber String?
|
||||
zipCode String
|
||||
|
||||
customer Customer @relation(fields: [customerId], references: [id], onDelete: Cascade)
|
||||
customerId String
|
||||
|
||||
Reference in New Issue
Block a user