<?php declare(strict_types=1);
namespace Maxia\MaxiaVariantsTable6;
use Maxia\MaxiaVariantsTable6\Setup\Installer;
use Maxia\MaxiaVariantsTable6\Setup\Uninstaller;
use Maxia\MaxiaVariantsTable6\Setup\Updater;
use Shopware\Core\Framework\Plugin;
use Shopware\Core\Framework\Plugin\Context\InstallContext;
use Shopware\Core\Framework\Plugin\Context\UninstallContext;
use Shopware\Core\Framework\Plugin\Context\UpdateContext;
use Symfony\Component\DependencyInjection\ContainerBuilder;
class MaxiaVariantsTable6 extends Plugin
{
public const CUSTOM_FIELD_PREFIX = 'maxia_variants_table';
public function build(ContainerBuilder $container): void
{
$container->setParameter('maxia.maxia_variants_table_6.plugin_name', 'MaxiaVariantsTable6');
parent::build($container);
}
/**
* {@inheritdoc}
*/
public function update(UpdateContext $updateContext): void
{
parent::update($updateContext);
$updater = new Updater($this->container);
$updater->update($updateContext);
}
/**
* {@inheritdoc}
*/
public function postUpdate(UpdateContext $updateContext): void
{
parent::postUpdate($updateContext);
$updater = new Updater($this->container);
$updater->postUpdate($updateContext);
}
/**
* {@inheritdoc}
*/
public function install(InstallContext $installContext): void
{
parent::install($installContext);
$installer = new Installer($this->container);
$installer->install($installContext);
}
/**
* {@inheritdoc}
*/
public function uninstall(UninstallContext $uninstallContext): void
{
parent::uninstall($uninstallContext);
$uninstaller = new Uninstaller($this->container);
$uninstaller->uninstall($uninstallContext);
}
}