[AdminBundle] Add base form type for ShopUserType and PromotionCouponGeneratorInstructionType (#17337)

| Q               | A
|-----------------|-----
| Branch?         | 1.14
| Bug fix?        | no
| New feature?    | no
| BC breaks?      | no
| Deprecations?   | no
| Related tickets | #17336
| License         | MIT
This commit is contained in:
Grzegorz Sadowski 2024-10-28 11:08:55 +01:00 committed by GitHub
commit 146b1026fd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 68 additions and 0 deletions

View file

@ -0,0 +1,30 @@
<?php
/*
* This file is part of the Sylius package.
*
* (c) Sylius Sp. z o.o.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);
namespace Sylius\Bundle\AdminBundle\Form\Type;
use Sylius\Bundle\PromotionBundle\Form\Type\PromotionCouponGeneratorInstructionType as BasePromotionCouponGeneratorInstructionType;
use Symfony\Component\Form\AbstractType;
final class PromotionCouponGeneratorInstructionType extends AbstractType
{
public function getBlockPrefix(): string
{
return 'sylius_admin_promotion_coupon_generator_instruction';
}
public function getParent(): string
{
return BasePromotionCouponGeneratorInstructionType::class;
}
}

View file

@ -0,0 +1,30 @@
<?php
/*
* This file is part of the Sylius package.
*
* (c) Sylius Sp. z o.o.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);
namespace Sylius\Bundle\AdminBundle\Form\Type;
use Sylius\Bundle\CoreBundle\Form\Type\User\ShopUserType as BaseShopUserType;
use Symfony\Component\Form\AbstractType;
final class ShopUserType extends AbstractType
{
public function getBlockPrefix(): string
{
return 'sylius_admin_shop_user';
}
public function getParent(): string
{
return BaseShopUserType::class;
}
}

View file

@ -150,6 +150,10 @@
<tag name="form.type" />
</service>
<service id="sylius_admin.form.type.promotion_coupon_generator_instruction" class="Sylius\Bundle\AdminBundle\Form\Type\PromotionCouponGeneratorInstructionType" >
<tag name="form.type" />
</service>
<service id="sylius_admin.form.type.shipping_category" class="Sylius\Bundle\AdminBundle\Form\Type\ShippingCategoryType" >
<tag name="form.type" />
</service>
@ -162,6 +166,10 @@
<tag name="form.type" />
</service>
<service id="sylius_admin.form.type.shop_user" class="Sylius\Bundle\AdminBundle\Form\Type\ShopUserType" >
<tag name="form.type" />
</service>
<service id="sylius_admin.form.type.tax_category" class="Sylius\Bundle\AdminBundle\Form\Type\TaxCategoryType" >
<tag name="form.type" />
</service>