Skip to content

Commit 81b7338

Browse files
Merge pull request #427 from Ecwid/ECWID-145869
ECWID-145869 New customer import: improve the default phone update logic - customer.primaryPhone in apiv3
2 parents 804bef0 + 5ead16d commit 81b7338

2 files changed

Lines changed: 2 additions & 0 deletions

File tree

src/main/kotlin/com/ecwid/apiclient/v3/dto/customer/request/UpdatedCustomer.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ data class UpdatedCustomer(
2121
val lang: String? = null,
2222
val privateAdminNotes: String? = null,
2323
val extrafields: List<CustomerExtrafield>? = null,
24+
val primaryPhone: String? = null,
2425

2526
@JsonFieldName("b2b_b2c")
2627
val commercialRelationshipScheme: CommercialRelationshipScheme? = null,

src/test/kotlin/com/ecwid/apiclient/v3/rule/NonDuplicablePropertyRules.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ val nonDuplicablePropertyRules: List<NonDuplicablePropertyRule<*, *>> = listOf(
1919
WriteOnly(UpdatedVariation.AttributeValue::alias),
2020
WriteOnly(UpdatedVariation.AttributeValue::name),
2121
WriteOnly(UpdatedProduct.RelatedProducts::productSkus),
22+
WriteOnly(UpdatedCustomer::primaryPhone), // contact becomes impossible to delete - rest4j replaces null with current value on writes
2223

2324
)
2425

0 commit comments

Comments
 (0)