From 18def5b86dc19d439d42d41e6e526d95948da9ae Mon Sep 17 00:00:00 2001 From: kitty Date: Thu, 14 Sep 2023 14:33:51 +0400 Subject: [PATCH] ECWID-124671 OE2: Send Order Data to Calculation and Display Changes: Bulk Discount Pricing. Added needCalculateWholesalePrice field, which enables calculating wholesale price in order item. --- .../com/ecwid/apiclient/v3/dto/cart/request/OrderForCalculate.kt | 1 + .../v3/rule/nullablepropertyrules/OrderForCalculateRules.kt | 1 + 2 files changed, 2 insertions(+) diff --git a/src/main/kotlin/com/ecwid/apiclient/v3/dto/cart/request/OrderForCalculate.kt b/src/main/kotlin/com/ecwid/apiclient/v3/dto/cart/request/OrderForCalculate.kt index 6a0e02e5..88b6f688 100644 --- a/src/main/kotlin/com/ecwid/apiclient/v3/dto/cart/request/OrderForCalculate.kt +++ b/src/main/kotlin/com/ecwid/apiclient/v3/dto/cart/request/OrderForCalculate.kt @@ -70,6 +70,7 @@ data class OrderForCalculate( val price: Double? = null, val productPrice: Double? = null, + val needCalculateWholesalePrice: Boolean? = null, val shipping: Double? = null, val tax: Double? = null, val fixedShippingRate: Double? = null, diff --git a/src/test/kotlin/com/ecwid/apiclient/v3/rule/nullablepropertyrules/OrderForCalculateRules.kt b/src/test/kotlin/com/ecwid/apiclient/v3/rule/nullablepropertyrules/OrderForCalculateRules.kt index e810da5d..5348ccf9 100644 --- a/src/test/kotlin/com/ecwid/apiclient/v3/rule/nullablepropertyrules/OrderForCalculateRules.kt +++ b/src/test/kotlin/com/ecwid/apiclient/v3/rule/nullablepropertyrules/OrderForCalculateRules.kt @@ -67,6 +67,7 @@ val orderForCalculateNullablePropertyRules: List> = l IgnoreNullable(OrderForCalculate.OrderItem::imageUrl), IgnoreNullable(OrderForCalculate.OrderItem::isShippingRequired), IgnoreNullable(OrderForCalculate.OrderItem::name), + AllowNullable(OrderForCalculate.OrderItem::needCalculateWholesalePrice), IgnoreNullable(OrderForCalculate.OrderItem::price), IgnoreNullable(OrderForCalculate.OrderItem::productId), IgnoreNullable(OrderForCalculate.OrderItem::productPrice),