Skip to content

Commit

Permalink
Merge pull request #372 from Ecwid/ECWID-134536_2
Browse files Browse the repository at this point in the history
ECWID-134536 added checkOnlyCustomerId field to search parametrs
  • Loading branch information
winrokru authored Feb 9, 2024
2 parents 9ea3f5f + f0bed8a commit 8bd5c44
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ data class CustomersIdsRequest(
request.maxOrderCount?.let { put("maxOrderCount", it.toString()) }
request.minSalesValue?.let { put("minSalesValue", it.toString()) }
request.maxSalesValue?.let { put("maxSalesValue", it.toString()) }
request.checkOnlyCustomerId?.let { put("checkOnlyCustomerId", it.toString()) }
request.taxExempt?.let { put("taxExempt", it.toString()) }
request.acceptMarketing?.let { put("acceptMarketing", it.toString()) }
request.purchasedProductIds?.let { put("purchasedProductIds", it) }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ data class CustomersMassUpdateRequest(
request.maxOrderCount?.let { put("maxOrderCount", it.toString()) }
request.minSalesValue?.let { put("minSalesValue", it.toString()) }
request.maxSalesValue?.let { put("maxSalesValue", it.toString()) }
request.checkOnlyCustomerId?.let { put("checkOnlyCustomerId", it.toString()) }
request.taxExempt?.let { put("taxExempt", it.toString()) }
request.acceptMarketing?.let { put("acceptMarketing", it.toString()) }
request.purchasedProductIds?.let { put("purchasedProductIds", it) }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ data class CustomersRequestFields(
val maxOrderCount: Int? = null,
val minSalesValue: Int? = null,
val maxSalesValue: Int? = null,
val checkOnlyCustomerId: Boolean? = null,
val taxExempt: Boolean? = null,
val acceptMarketing: Boolean? = null,
val purchasedProductIds: String? = null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ data class CustomersSearchRequest(
val maxOrderCount: Int? = null,
val minSalesValue: Int? = null,
val maxSalesValue: Int? = null,
val checkOnlyCustomerId: Boolean? = null,
val taxExempt: Boolean? = null,
val acceptMarketing: Boolean? = null,
val purchasedProductIds: String? = null,
Expand Down Expand Up @@ -68,6 +69,7 @@ data class CustomersSearchRequest(
request.maxOrderCount?.let { put("maxOrderCount", it.toString()) }
request.minSalesValue?.let { put("minSalesValue", it.toString()) }
request.maxSalesValue?.let { put("maxSalesValue", it.toString()) }
request.checkOnlyCustomerId?.let { put("checkOnlyCustomerId", it.toString()) }
request.createdFrom?.let { put("createdFrom", TimeUnit.MILLISECONDS.toSeconds(it.time).toString()) }
request.createdTo?.let { put("createdTo", TimeUnit.MILLISECONDS.toSeconds(it.time).toString()) }
request.updatedFrom?.let { put("updatedFrom", TimeUnit.MILLISECONDS.toSeconds(it.time).toString()) }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,5 @@ val customersIdsRequestNullablePropertyRules: List<NullablePropertyRule<*, *>> =
AllowNullable(CustomersRequestFields::taxExempt),
AllowNullable(CustomersRequestFields::acceptMarketing),
AllowNullable(CustomersRequestFields::lang),
AllowNullable(CustomersRequestFields::checkOnlyCustomerId),
)
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ val customersMassUpdatedRequestNullablePropertyRules: List<NullablePropertyRule<
AllowNullable(CustomersRequestFields::taxExempt),
AllowNullable(CustomersRequestFields::acceptMarketing),
AllowNullable(CustomersRequestFields::lang),
AllowNullable(CustomersRequestFields::checkOnlyCustomerId),

AllowNullable(MassUpdateCustomer::ids),
AllowNullable(MassUpdateCustomer::delete),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,5 @@ val customersSearchRequestNullablePropertyRules: List<NullablePropertyRule<*, *>
AllowNullable(CustomersSearchRequest::taxExempt),
AllowNullable(CustomersSearchRequest::acceptMarketing),
AllowNullable(CustomersSearchRequest::lang),
AllowNullable(CustomersSearchRequest::checkOnlyCustomerId),
)

0 comments on commit 8bd5c44

Please sign in to comment.