spryker-demo/product-archiving-feature

Product archiving [feature]

1.0.0 2025-04-09 16:09 UTC

This package is auto-updated.

Last update: 2025-05-22 16:59:21 UTC


README

Minimum PHP Version

Installation

Install feature

composer require spryker-demo/product-archiving-feature

Add SprykerDemo namespace to configuration

$config[KernelConstants::CORE_NAMESPACES] = [
    'SprykerDemo',
     ...
];

Wire the table action expander plugin

# src/Pyz/Zed/ProductManagement/ProductManagementDependencyProvider.php

use SprykerDemo\Zed\ProductArchivingGui\Communication\Plugin\ProductManagement\ProductArchivingProductVariantTableActionExpanderPlugin;
use SprykerDemo\Zed\ProductManagement\ProductManagementDependencyProvider as SprykerDemoProductManagementDependencyProvider;

class ProductManagementDependencyProvider extends SprykerDemoProductManagementDependencyProvider
{
    ...

    /**
     * @return array<\SprykerDemo\Zed\ProductManagement\Dependency\Plugin\ProductVariantTableActionExpanderPluginInterface>
     */
    protected function getProductVariantTableActionExpanderPlugins(): array
    {
        return [
            new ProductArchivingProductVariantTableActionExpanderPlugin(),
        ];
    }
}

Inherit project class ProductManagementCommunicationFactory from the corresponding Spryker Demo one

# src/Pyz/Zed/ProductManagement/Communication/ProductManagementCommunicationFactory.php

use SprykerDemo\Zed\ProductManagement\Communication\ProductManagementCommunicationFactory as SprykerDemoProductManagementCommunicationFactory;

class ProductManagementCommunicationFactory extends SprykerDemoProductManagementCommunicationFactory
{
    ...
}

Build Propel classes

console propel:install

Generate Backoffice translations

console translator:generate-cache