<?php declare(strict_types=1);
namespace Bioraum\Benefits;
use Shopware\Core\Framework\Plugin;
use Shopware\Core\Framework\Plugin\Context\ActivateContext;
use Shopware\Core\Framework\Plugin\Context\DeactivateContext;
use Shopware\Core\Framework\Plugin\Context\InstallContext;
use Shopware\Core\Framework\Plugin\Context\UninstallContext;
use Shopware\Core\Framework\Plugin\Context\UpdateContext;
use Bioraum\Benefits\Installer\CustomFieldInstaller;
class BioraumBenefits extends Plugin
{
public function install(InstallContext $installContext): void
{
(new CustomFieldInstaller($this->container))->install($installContext);
}
public function update(UpdateContext $updateContext): void
{
(new CustomFieldInstaller($this->container))->update($updateContext);
}
public function activate(ActivateContext $activateContext): void
{
(new CustomFieldInstaller($this->container))->activate($activateContext);
}
public function deactivate(DeactivateContext $deactivateContext): void
{
(new CustomFieldInstaller($this->container))->deactivate($deactivateContext);
}
public function uninstall(UninstallContext $uninstallContext): void
{
(new CustomFieldInstaller($this->container))->uninstall($uninstallContext);
if ($uninstallContext->keepUserData()) {
parent::uninstall($uninstallContext);
return;
}
}
}