Marketplace Shipment + Customer feature integration

Edit on GitHub

This document describes how to integrate the Marketplace Shipment + Customer feature into a Spryker project.

Install feature core

Follow the steps below to install the Marketplace Shipment + Customer feature core.

Prerequisites

To start feature integration, integrate the required features:

NAME VERSION INTEGRATION GUIDE
Marketplace Shipment 202108.0 Marketplace Shipment feature integration
Customer 202108.0

1) Set up behavior

Enable the following behaviors by registering the plugins:

PLUGIN SPECIFICATION PREREQUISITES NAMESPACE
MerchantShipmentCheckoutAddressStepPreGroupItemsByShipmentPlugin Sets shipment merchant reference in the initial checkout step to avoid wrong grouping by merchant reference. Spryker\Yves\MerchantShipment\Plugin\CustomerPage
ssrc/Pyz/Yves/CustomerPage/CustomerPageDependencyProvider.php
<?php

namespace Pyz\Yves\CustomerPage;

use SprykerShop\Yves\CustomerPage\CustomerPageDependencyProvider as SprykerShopCustomerPageDependencyProvider;
use Spryker\Yves\MerchantShipment\Plugin\CustomerPage\MerchantShipmentCheckoutAddressStepPreGroupItemsByShipmentPlugin;

class CustomerPageDependencyProvider extends SprykerShopCustomerPageDependencyProvider
{
    /**
     * @return \SprykerShop\Yves\CustomerPageExtension\Dependency\Plugin\CheckoutAddressStepPreGroupItemsByShipmentPluginInterface[]
     */
    protected function getCheckoutAddressStepPreGroupItemsByShipmentPlugins(): array
    {
        return [
            new MerchantShipmentCheckoutAddressStepPreGroupItemsByShipmentPlugin(),
        ];
    }
}
Verification

Make sure that during the checkout steps, items and their shipments have the same merchant reference attached to them.