All Release Notes

Added Store based price filtering

14 July 2020
Enhancement
PricingProduct CatalogStores

You can now add Product Distribution Channels to Stores. When querying ProductProjections, you can then use the query parameter storeProjection to remove all prices from the response payload that don't correspond to the Channels set in the Store.

Setting Product Distribution Channels on Stores also affects cart line items. If a cart is bound to a store and the store has Product Distribution Channels set, then only prices from these channels (and prices not linked not any channel) are included in the product variant information of the line item. Additionally, the distributionChannel field on the cart used for the LineItem Price Selection can only be set to one of the channels set in the store.

To enable the configuration of product distribution channels in Stores, the following changes have been made:

  • [API] Added distributionChannels field to StoreDraft
  • [API] Added distributionChannels field to Store
  • [API] Added setDistributionChannels update action to Store
  • [API] Added addDistributionChannel update action to Store
  • [API] Added removeDistributionChannel update action to Store
  • [GraphQL API] Added the following types to the GraphQL schema: SetStoreDistributionChannels
  • [GraphQL API] Changed the StoreUpdateAction type:
    • Input field setDistributionChannels was added to StoreUpdateAction type
    • Input field addDistributionChannel was added to StoreUpdateAction type
    • Input field removeDistributionChannel was added to StoreUpdateAction type
  • [GraphQL API] Changed the CreateStore type:
    • Input field distributionChannels was added to CreateStore type
  • [GraphQL API] Changed the Store type:
    • Added the distributionChannelsRef field to the Store type.
    • Added the distributionChannels field to the Store type.

Introduced the following changes to the GraphQL schema (in SDL format):

extend type Store {
distributionChannels: [Channel!]!
distributionChannelsRef: [Reference!]!
}
extend input StoreUpdateAction {
setDistributionChannels: SetStoreDistributionChannels
addDistributionChannel: AddStoreDistributionChannel
removeDistributionChannel: RemoveStoreDistributionChannel
}
extend input CreateStore {
distributionChannels: [ResourceIdentifierInput!]
}
input SetStoreDistributionChannels {
distributionChannels: [ResourceIdentifierInput!]
}
input AddStoreDistributionChannel {
distributionChannel: ResourceIdentifierInput!
}
input RemoveStoreDistributionChannel {
distributionChannel: ResourceIdentifierInput!
}