Skip to content

Commit 01d0d0f

Browse files
committed
Merge remote-tracking branch 'origin/master'
2 parents fc32597 + 70bcb2a commit 01d0d0f

8 files changed

Lines changed: 34 additions & 0 deletions

File tree

src/main/kotlin/com/ecwid/apiclient/v3/converter/FetchedStoreProfile.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,7 @@ fun FetchedStoreProfile.Settings.toUpdated(): UpdatedStoreProfile.Settings {
104104
googleRemarketingEnabled = googleRemarketingEnabled,
105105
googleTagId = googleTagId,
106106
hideOutOfStockProductsInStorefront = hideOutOfStockProductsInStorefront,
107+
highlightCompositeProductsOnStorefront = highlightCompositeProductsOnStorefront,
107108
openBagOnAddition = openBagOnAddition,
108109
orderCommentsCaption = orderCommentsCaption,
109110
orderCommentsEnabled = orderCommentsEnabled,
@@ -410,6 +411,7 @@ fun FetchedStoreProfile.DesignSettings.toUpdated(): UpdatedStoreProfile.DesignSe
410411
productFiltersVisibleOnCatalogPages = productFiltersVisibleOnCatalogPages,
411412
productListBuyNowBehaviour = productListBuyNowBehaviour,
412413
productListCardLayout = productListCardLayout,
414+
productListCardSpacingType = productListCardSpacingType,
413415
productListCategoryCellSpacing = productListCategoryCellSpacing,
414416
productListCategoryImageLayout = productListCategoryImageLayout,
415417
productListCategoryImagePosition = productListCategoryImagePosition,
@@ -422,6 +424,7 @@ fun FetchedStoreProfile.DesignSettings.toUpdated(): UpdatedStoreProfile.DesignSe
422424
productListImageSize = productListImageSize,
423425
productListNameBehaviour = productListNameBehaviour,
424426
productListPriceBehaviour = productListPriceBehaviour,
427+
productListShowPriceRanges = productListShowPriceRanges,
425428
productListRatingSectionBehavior = productListRatingSectionBehavior,
426429
productListSKUBehaviour = productListSKUBehaviour,
427430
productListShowAdditionalImage = productListShowAdditionalImage,
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
package com.ecwid.apiclient.v3.dto.profile.enums
2+
3+
enum class HighlightCompositeProductsOnStorefront {
4+
DISABLED,
5+
ENABLED,
6+
}

src/main/kotlin/com/ecwid/apiclient/v3/dto/profile/request/UpdatedStoreProfile.kt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import com.ecwid.apiclient.v3.dto.common.ApiUpdatedDTO
44
import com.ecwid.apiclient.v3.dto.common.ApiUpdatedDTO.ModifyKind
55
import com.ecwid.apiclient.v3.dto.common.LocalizedValueMap
66
import com.ecwid.apiclient.v3.dto.common.ProductCondition
7+
import com.ecwid.apiclient.v3.dto.profile.enums.HighlightCompositeProductsOnStorefront
78
import com.ecwid.apiclient.v3.dto.profile.enums.ProductFilterType
89
import com.ecwid.apiclient.v3.dto.profile.result.FetchedStoreProfile
910
import com.ecwid.apiclient.v3.jsontransformer.JsonFieldName
@@ -98,6 +99,7 @@ data class UpdatedStoreProfile(
9899
val googleRemarketingEnabled: Boolean? = null,
99100
val googleTagId: String? = null,
100101
val hideOutOfStockProductsInStorefront: Boolean? = null,
102+
val highlightCompositeProductsOnStorefront: HighlightCompositeProductsOnStorefront? = null,
101103
val orderCommentsCaption: String? = null,
102104
val orderCommentsEnabled: Boolean? = null,
103105
val orderCommentsRequired: Boolean? = null,
@@ -550,6 +552,9 @@ data class UpdatedStoreProfile(
550552
@JsonFieldName("product_list_product_info_layout")
551553
val productListCardLayout: String? = null,
552554

555+
@JsonFieldName("product_list_card_spacing_type")
556+
val productListCardSpacingType: String? = null,
557+
553558
@JsonFieldName("product_list_category_cell_spacing")
554559
val productListCategoryCellSpacing: Int? = null,
555560

@@ -586,6 +591,9 @@ data class UpdatedStoreProfile(
586591
@JsonFieldName("product_list_price_behavior")
587592
val productListPriceBehaviour: String? = null,
588593

594+
@JsonFieldName("product_list_show_price_ranges")
595+
val productListShowPriceRanges: Boolean? = null,
596+
589597
@JsonFieldName("product_list_rating_section_behavior")
590598
val productListRatingSectionBehavior: String? = null,
591599

src/main/kotlin/com/ecwid/apiclient/v3/dto/profile/result/FetchedStoreProfile.kt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import com.ecwid.apiclient.v3.dto.common.ApiFetchedDTO.ModifyKind
55
import com.ecwid.apiclient.v3.dto.common.ApiResultDTO
66
import com.ecwid.apiclient.v3.dto.common.LocalizedValueMap
77
import com.ecwid.apiclient.v3.dto.common.ProductCondition
8+
import com.ecwid.apiclient.v3.dto.profile.enums.HighlightCompositeProductsOnStorefront
89
import com.ecwid.apiclient.v3.dto.profile.enums.ProductFilterType
910
import com.ecwid.apiclient.v3.dto.profile.request.UpdatedPaymentOption
1011
import com.ecwid.apiclient.v3.dto.profile.request.UpdatedStoreProfile
@@ -127,6 +128,7 @@ data class FetchedStoreProfile(
127128
val googleRemarketingEnabled: Boolean? = null,
128129
val googleTagId: String? = null,
129130
val hideOutOfStockProductsInStorefront: Boolean? = null,
131+
val highlightCompositeProductsOnStorefront: HighlightCompositeProductsOnStorefront = HighlightCompositeProductsOnStorefront.DISABLED,
130132
val invoiceLogoUrl: String? = null,
131133
val openBagOnAddition: Boolean = false,
132134
val orderCommentsCaption: String? = null,
@@ -650,6 +652,9 @@ data class FetchedStoreProfile(
650652
@JsonFieldName("product_list_product_info_layout")
651653
val productListCardLayout: String? = null,
652654

655+
@JsonFieldName("product_list_card_spacing_type")
656+
val productListCardSpacingType: String? = null,
657+
653658
@JsonFieldName("product_list_category_cell_spacing")
654659
val productListCategoryCellSpacing: Int? = null,
655660

@@ -686,6 +691,9 @@ data class FetchedStoreProfile(
686691
@JsonFieldName("product_list_price_behavior")
687692
val productListPriceBehaviour: String? = null,
688693

694+
@JsonFieldName("product_list_show_price_ranges")
695+
val productListShowPriceRanges: Boolean? = null,
696+
689697
@JsonFieldName("product_list_rating_section_behavior")
690698
val productListRatingSectionBehavior: String? = null,
691699

src/main/kotlin/com/ecwid/apiclient/v3/dto/report/enums/ReportType.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,11 @@ enum class ReportType {
4444
siteActivity,
4545
siteSocialActivity,
4646
siteAggregatedActivity,
47+
siteAggregatedActivityNewAndReturn,
4748
siteGroupActivity,
4849
siteGroupActivityNew,
4950
siteGroupActivityReturn,
5051
siteUniqueNewVisitorsByGroup,
52+
sitePotentialLeads,
53+
siteGroupEngagedActivity,
5154
}

src/test/kotlin/com/ecwid/apiclient/v3/entity/StoreProfileTest.kt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ package com.ecwid.apiclient.v3.entity
22

33
import com.ecwid.apiclient.v3.converter.toUpdated
44
import com.ecwid.apiclient.v3.dto.common.ProductCondition
5+
import com.ecwid.apiclient.v3.dto.profile.enums.HighlightCompositeProductsOnStorefront
56
import com.ecwid.apiclient.v3.dto.profile.enums.ProductFilterType
67
import com.ecwid.apiclient.v3.dto.profile.request.StoreProfileRequest
78
import com.ecwid.apiclient.v3.dto.profile.request.StoreProfileUpdateRequest
@@ -49,6 +50,7 @@ class StoreProfileTest : BaseEntityTest() {
4950
orderCommentsCaption = "orderCommentsCaption",
5051
orderCommentsRequired = true,
5152
hideOutOfStockProductsInStorefront = true,
53+
highlightCompositeProductsOnStorefront = HighlightCompositeProductsOnStorefront.ENABLED,
5254
askCompanyName = true,
5355
favoritesEnabled = true,
5456
defaultProductSortOrder = UpdatedStoreProfile.ProductSortOrder.NAME_ASC,

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

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import com.ecwid.apiclient.v3.dto.coupon.request.UpdatedCoupon
55
import com.ecwid.apiclient.v3.dto.customergroup.request.UpdatedCustomerGroup
66
import com.ecwid.apiclient.v3.dto.product.request.UpdatedProduct
77
import com.ecwid.apiclient.v3.dto.profile.request.UpdatedStoreProfile
8+
import com.ecwid.apiclient.v3.dto.profile.result.FetchedStoreProfile
89
import com.ecwid.apiclient.v3.dto.storage.request.UpdatedStorageData
910
import com.ecwid.apiclient.v3.dto.variation.request.UpdatedVariation
1011
import com.ecwid.apiclient.v3.rule.NonnullPropertyRule.AllowNonnull
@@ -56,6 +57,7 @@ val nonnullPropertyRules: List<NonnullPropertyRule<*, *>> = listOf(
5657
AllowNonnull(UpdatedStoreProfile.ProductFiltersSettings::filterSections),
5758
AllowNonnull(UpdatedVariation.RecurringChargeSettings::recurringInterval),
5859
AllowNonnull(UpdatedVariation.RecurringChargeSettings::recurringIntervalCount),
60+
AllowNonnull(FetchedStoreProfile.Settings::highlightCompositeProductsOnStorefront),
5961
)
6062

6163
sealed class NonnullPropertyRule<T, R>(

src/test/kotlin/com/ecwid/apiclient/v3/rule/nullablepropertyrules/FetchedStoreProfileRules.kt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,7 @@ val fetchedStoreProfileNullablePropertyRules: List<NullablePropertyRule<*, *>> =
136136
AllowNullable(FetchedStoreProfile.DesignSettings::productFiltersVisibleOnCatalogPages),
137137
AllowNullable(FetchedStoreProfile.DesignSettings::productListBuyNowBehaviour),
138138
AllowNullable(FetchedStoreProfile.DesignSettings::productListCardLayout),
139+
AllowNullable(FetchedStoreProfile.DesignSettings::productListCardSpacingType),
139140
AllowNullable(FetchedStoreProfile.DesignSettings::productListCategoryCellSpacing),
140141
AllowNullable(FetchedStoreProfile.DesignSettings::productListCategoryImageLayout),
141142
AllowNullable(FetchedStoreProfile.DesignSettings::productListCategoryImagePosition),
@@ -148,6 +149,7 @@ val fetchedStoreProfileNullablePropertyRules: List<NullablePropertyRule<*, *>> =
148149
AllowNullable(FetchedStoreProfile.DesignSettings::productListImageSize),
149150
AllowNullable(FetchedStoreProfile.DesignSettings::productListNameBehaviour),
150151
AllowNullable(FetchedStoreProfile.DesignSettings::productListPriceBehaviour),
152+
AllowNullable(FetchedStoreProfile.DesignSettings::productListShowPriceRanges),
151153
AllowNullable(FetchedStoreProfile.DesignSettings::productListRatingSectionBehavior),
152154
AllowNullable(FetchedStoreProfile.DesignSettings::productListSKUBehaviour),
153155
AllowNullable(FetchedStoreProfile.DesignSettings::productListShowAdditionalImage),

0 commit comments

Comments
 (0)