Skip to content

Commit

Permalink
ECWID-136865 Use pre calculated order count for customers api
Browse files Browse the repository at this point in the history
  • Loading branch information
winrokru committed Aug 7, 2024
1 parent 1afd5e7 commit be8e873
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ data class CustomersSearchRequest(
val name: String? = null,
val email: String? = null,
val customerGroupId: Int? = null,
val usePrecalculatedOrderCount: Boolean? = null,
val minOrderCount: Int? = null,
val maxOrderCount: Int? = null,
val minSalesValue: Int? = null,
Expand Down Expand Up @@ -70,6 +71,7 @@ data class CustomersSearchRequest(
request.name?.let { put("name", it) }
request.email?.let { put("email", it) }
request.customerGroupId?.let { put("customerGroup", it.toString()) }
request.usePrecalculatedOrderCount?.let { put("usePrecalculatedOrderCount", it.toString()) }
request.minOrderCount?.let { put("minOrderCount", it.toString()) }
request.maxOrderCount?.let { put("maxOrderCount", it.toString()) }
request.minSalesValue?.let { put("minSalesValue", it.toString()) }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ val customersSearchRequestNullablePropertyRules: List<NullablePropertyRule<*, *>
AllowNullable(CustomersSearchRequest::customerGroupId),
AllowNullable(CustomersSearchRequest::email),
AllowNullable(CustomersSearchRequest::keyword),
AllowNullable(CustomersSearchRequest::usePrecalculatedOrderCount),
AllowNullable(CustomersSearchRequest::maxOrderCount),
AllowNullable(CustomersSearchRequest::minOrderCount),
AllowNullable(CustomersSearchRequest::maxSalesValue),
Expand Down

0 comments on commit be8e873

Please sign in to comment.