diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 540ef06aac..ca0b5830e0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -45,7 +45,7 @@ jobs: uses: shivammathur/setup-php@v2 with: php-version: "${{ matrix.php }}" - extensions: intl + extensions: intl, mbstring tools: symfony coverage: none diff --git a/Dockerfile b/Dockerfile index 3d15dfd177..658eb34521 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,11 +1,11 @@ # the different stages of this Dockerfile are meant to be built into separate images # https://docs.docker.com/compose/compose-file/#target -ARG PHP_VERSION=8.0 +ARG PHP_VERSION=8.1 ARG NODE_VERSION=16 ARG NGINX_VERSION=1.21 ARG ALPINE_VERSION=3.15 -ARG COMPOSER_VERSION=2 +ARG COMPOSER_VERSION=2.4 ARG PHP_EXTENSION_INSTALLER_VERSION=latest FROM composer:${COMPOSER_VERSION} AS composer @@ -24,7 +24,10 @@ RUN apk add --no-cache \ COPY --from=php_extension_installer /usr/bin/install-php-extensions /usr/local/bin/ -RUN install-php-extensions apcu curl exif gd iconv intl mbstring pdo_mysql opcache xml zip +# default PHP image extensions +# ctype curl date dom fileinfo filter ftp hash iconv json libxml mbstring mysqlnd openssl pcre PDO pdo_sqlite Phar +# posix readline Reflection session SimpleXML sodium SPL sqlite3 standard tokenizer xml xmlreader xmlwriter zlib +RUN install-php-extensions apcu exif gd intl pdo_mysql opcache zip COPY --from=composer /usr/bin/composer /usr/bin/composer COPY docker/php/prod/php.ini $PHP_INI_DIR/php.ini @@ -51,7 +54,7 @@ RUN set -eux; \ composer clear-cache # copy only specifically what we need -COPY .env .env.prod .env.test .env.test_cached ./ +COPY .env .env.prod ./ COPY assets assets/ COPY bin bin/ COPY config config/ @@ -131,6 +134,8 @@ WORKDIR /srv/sylius ENV APP_ENV=dev +COPY .env.test .env.test_cached ./ + RUN set -eux; \ composer install --prefer-dist --no-autoloader --no-interaction --no-scripts --no-progress; \ composer clear-cache diff --git a/README.md b/README.md index 4810b31dab..7151acb272 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ ## About -Sylius is the first decoupled eCommerce platform based on [**Symfony**](http://symfony.com) and [**Doctrine**](http://doctrine-project.org). +Sylius is the first decoupled eCommerce framework based on [**Symfony**](http://symfony.com) and [**Doctrine**](http://doctrine-project.org). The highest quality of code, strong testing culture, built-in Agile (BDD) workflow and exceptional flexibility make it the best solution for application tailored to your business requirements. Enjoy being an eCommerce Developer again! @@ -77,7 +77,7 @@ $ tail -f var/log/dev.log ## Contributing -Would like to help us and build the most developer-friendly eCommerce platform? Start from reading our [Contribution Guide](https://docs.sylius.com/en/latest/contributing/)! +Would like to help us and build the most developer-friendly eCommerce framework? Start from reading our [Contribution Guide](https://docs.sylius.com/en/latest/contributing/)! ## Stay Updated diff --git a/bin/console b/bin/console index 52fd3989fb..313dc90809 100755 --- a/bin/console +++ b/bin/console @@ -3,36 +3,13 @@ use App\Kernel; use Symfony\Bundle\FrameworkBundle\Console\Application; -use Symfony\Component\Console\Input\ArgvInput; -use Symfony\Component\Debug\Debug; -set_time_limit(0); - -require dirname(__DIR__).'/vendor/autoload.php'; - -if (!class_exists(Application::class)) { - throw new RuntimeException('You need to add "symfony/framework-bundle" as a Composer dependency.'); +if (!is_file(dirname(__DIR__).'/vendor/autoload_runtime.php')) { + throw new LogicException('Symfony Runtime is missing. Try running "composer require symfony/runtime".'); } -$input = new ArgvInput(); -if (null !== $env = $input->getParameterOption(['--env', '-e'], null, true)) { - putenv('APP_ENV='.$_SERVER['APP_ENV'] = $_ENV['APP_ENV'] = $env); -} - -if ($input->hasParameterOption('--no-debug', true)) { - putenv('APP_DEBUG='.$_SERVER['APP_DEBUG'] = $_ENV['APP_DEBUG'] = '0'); -} - -require dirname(__DIR__).'/config/bootstrap.php'; - -if ($_SERVER['APP_DEBUG']) { - umask(0000); - - if (class_exists(Debug::class)) { - Debug::enable(); - } -} +require_once dirname(__DIR__).'/vendor/autoload_runtime.php'; -$kernel = new Kernel($_SERVER['APP_ENV'], (bool) $_SERVER['APP_DEBUG']); -$application = new Application($kernel); -$application->run($input); +return function (array $context) { + return new Application(new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG'])); +}; diff --git a/composer.json b/composer.json index 801d523262..5dc77a1584 100644 --- a/composer.json +++ b/composer.json @@ -25,9 +25,10 @@ ], "require": { "php": "^8.0", - "sylius/paypal-plugin": "^1.5.x-dev", - "sylius/sylius": "^1.12.x-dev", + "sylius/paypal-plugin": "^1.5", + "sylius/sylius": "^1.12", "symfony/dotenv": "^5.4 || ^6.0", + "symfony/runtime": "^5.4 || ^6.0", "symfony/flex": "^2.1" }, "require-dev": { @@ -68,7 +69,8 @@ "symfony/flex": true, "dealerdirect/phpcodesniffer-composer-installer": false, "phpstan/extension-installer": false, - "symfony/thanks": false + "symfony/thanks": false, + "symfony/runtime": true } }, "extra": { @@ -124,6 +126,7 @@ "symfony/polyfill-intl-icu": "*", "symfony/polyfill-intl-idn": "*", "symfony/polyfill-intl-normalizer": "*", + "symfony/polyfill-mbstring": "*", "symfony/polyfill-php54": "*", "symfony/polyfill-php55": "*", "symfony/polyfill-php56": "*", diff --git a/config/packages/_sylius.yaml b/config/packages/_sylius.yaml index 1da29b94d8..ce751d0acc 100644 --- a/config/packages/_sylius.yaml +++ b/config/packages/_sylius.yaml @@ -10,6 +10,10 @@ imports: parameters: sylius_core.public_dir: '%kernel.project_dir%/public' +when@dev: + sylius_api: + enabled: true + sylius_addressing: resources: address: diff --git a/config/packages/dev/_sylius.yaml b/config/packages/dev/_sylius.yaml deleted file mode 100644 index cd01aaf704..0000000000 --- a/config/packages/dev/_sylius.yaml +++ /dev/null @@ -1,2 +0,0 @@ -sylius_api: - enabled: true diff --git a/config/packages/dev/framework.yaml b/config/packages/dev/framework.yaml deleted file mode 100644 index 4b116defde..0000000000 --- a/config/packages/dev/framework.yaml +++ /dev/null @@ -1,2 +0,0 @@ -framework: - profiler: { only_exceptions: false } diff --git a/config/packages/dev/routing.yaml b/config/packages/dev/routing.yaml deleted file mode 100644 index 4116679a2e..0000000000 --- a/config/packages/dev/routing.yaml +++ /dev/null @@ -1,3 +0,0 @@ -framework: - router: - strict_requirements: true diff --git a/config/packages/dev/web_profiler.yaml b/config/packages/dev/web_profiler.yaml deleted file mode 100644 index 1f1cb2bb48..0000000000 --- a/config/packages/dev/web_profiler.yaml +++ /dev/null @@ -1,3 +0,0 @@ -web_profiler: - toolbar: true - intercept_redirects: false diff --git a/config/packages/doctrine.yaml b/config/packages/doctrine.yaml index 77ab2b1f25..3d869f9d12 100644 --- a/config/packages/doctrine.yaml +++ b/config/packages/doctrine.yaml @@ -20,7 +20,7 @@ doctrine: mappings: App: is_bundle: false - type: annotation + type: attribute dir: '%kernel.project_dir%/src/Entity' prefix: 'App\Entity' alias: App diff --git a/config/packages/framework.yaml b/config/packages/framework.yaml index 97695e6248..29047430bf 100644 --- a/config/packages/framework.yaml +++ b/config/packages/framework.yaml @@ -10,3 +10,15 @@ framework: serializer: mapping: paths: [ '%kernel.project_dir%/config/serialization' ] + +when@dev: + framework: + profiler: { only_exceptions: false } + +when@test: &framework_test + framework: + test: true + session: + storage_factory_id: session.storage.factory.mock_file + +when@test_cached: *framework_test diff --git a/config/packages/mailer.yaml b/config/packages/mailer.yaml index 56a650d89b..7acef5740a 100644 --- a/config/packages/mailer.yaml +++ b/config/packages/mailer.yaml @@ -1,3 +1,12 @@ framework: mailer: dsn: '%env(MAILER_DSN)%' + +when@test: &mailer_test + framework: + cache: + pools: + test.mailer_pool: + adapter: cache.adapter.filesystem + +when@test_cached: *mailer_test diff --git a/config/packages/routing.yaml b/config/packages/routing.yaml index 368bc7f491..4116679a2e 100644 --- a/config/packages/routing.yaml +++ b/config/packages/routing.yaml @@ -1,3 +1,3 @@ framework: router: - strict_requirements: ~ + strict_requirements: true diff --git a/config/packages/staging/monolog.yaml b/config/packages/staging/monolog.yaml deleted file mode 100644 index 646121143a..0000000000 --- a/config/packages/staging/monolog.yaml +++ /dev/null @@ -1,10 +0,0 @@ -monolog: - handlers: - main: - type: fingers_crossed - action_level: error - handler: nested - nested: - type: stream - path: "%kernel.logs_dir%/%kernel.environment%.log" - level: debug diff --git a/config/packages/test/framework.yaml b/config/packages/test/framework.yaml deleted file mode 100644 index fc1d3c13ca..0000000000 --- a/config/packages/test/framework.yaml +++ /dev/null @@ -1,4 +0,0 @@ -framework: - test: ~ - session: - storage_factory_id: session.storage.factory.mock_file diff --git a/config/packages/test/mailer.yaml b/config/packages/test/mailer.yaml deleted file mode 100644 index 52610d69b7..0000000000 --- a/config/packages/test/mailer.yaml +++ /dev/null @@ -1,5 +0,0 @@ -framework: - cache: - pools: - test.mailer_pool: - adapter: cache.adapter.filesystem diff --git a/config/packages/test/web_profiler.yaml b/config/packages/test/web_profiler.yaml deleted file mode 100644 index 03752de213..0000000000 --- a/config/packages/test/web_profiler.yaml +++ /dev/null @@ -1,6 +0,0 @@ -web_profiler: - toolbar: false - intercept_redirects: false - -framework: - profiler: { collect: false } diff --git a/config/packages/test_cached/framework.yaml b/config/packages/test_cached/framework.yaml deleted file mode 100644 index cf8f08807a..0000000000 --- a/config/packages/test_cached/framework.yaml +++ /dev/null @@ -1,2 +0,0 @@ -imports: - - { resource: '../test/framework.yaml' } diff --git a/config/packages/test_cached/mailer.yaml b/config/packages/test_cached/mailer.yaml deleted file mode 100644 index 16f3170aa2..0000000000 --- a/config/packages/test_cached/mailer.yaml +++ /dev/null @@ -1,2 +0,0 @@ -imports: - - { resource: "../test/mailer.yaml" } diff --git a/config/packages/test_cached/twig.yaml b/config/packages/test_cached/twig.yaml deleted file mode 100644 index 8c6e0b401d..0000000000 --- a/config/packages/test_cached/twig.yaml +++ /dev/null @@ -1,2 +0,0 @@ -twig: - strict_variables: true diff --git a/config/packages/test_cached/web_profiler.yaml b/config/packages/test_cached/web_profiler.yaml deleted file mode 100644 index 9052e3a612..0000000000 --- a/config/packages/test_cached/web_profiler.yaml +++ /dev/null @@ -1,2 +0,0 @@ -imports: - - { resource: "../test/web_profiler.yaml" } diff --git a/config/packages/twig.yaml b/config/packages/twig.yaml index 8545473ddd..18af2f439f 100644 --- a/config/packages/twig.yaml +++ b/config/packages/twig.yaml @@ -10,3 +10,7 @@ services: autoconfigure: true Twig\Extra\Intl\IntlExtension: ~ + +when@test_cached: + twig: + strict_variables: true diff --git a/config/packages/web_profiler.yaml b/config/packages/web_profiler.yaml new file mode 100644 index 0000000000..7732441ea2 --- /dev/null +++ b/config/packages/web_profiler.yaml @@ -0,0 +1,14 @@ +when@dev: + web_profiler: + toolbar: true + intercept_redirects: false + +when@test: &web_profiler_test + web_profiler: + toolbar: false + intercept_redirects: false + + framework: + profiler: { collect: false } + +when@test_cached: *web_profiler_test diff --git a/docker-compose.prod.yml b/docker-compose.prod.yml index c7d3df8830..5239bb29e4 100644 --- a/docker-compose.prod.yml +++ b/docker-compose.prod.yml @@ -7,12 +7,13 @@ services: depends_on: - mysql environment: + APP_DEBUG: 0 + APP_ENV: prod + APP_SECRET: EDITME DATABASE_URL: mysql://sylius:${MYSQL_PASSWORD}@mysql/sylius_prod MAILER_URL: smtp://localhost + MESSENGER_TRANSPORT_DSN: doctrine://default PHP_DATE_TIMEZONE: ${PHP_DATE_TIMEZONE:-UTC} - APP_ENV: prod - APP_DEBUG: 0 - APP_SECRET: EDITME volumes: # use a bind-mounted host directory, as we want to keep the sessions - ./var/sessions:/srv/sylius/var/sessions:rw @@ -29,11 +30,30 @@ services: depends_on: - mysql environment: + APP_ENV: prod + APP_DEBUG: 0 + APP_SECRET: EDITME DATABASE_URL: mysql://sylius:${MYSQL_PASSWORD}@mysql/sylius_prod PHP_DATE_TIMEZONE: ${PHP_DATE_TIMEZONE:-UTC} + networks: + - sylius + + worker: + container_name: worker + command: ["php", "bin/console", "messenger:consume", "main", "catalog_promotion_removal", "--limit=5", "--memory-limit=256M", "--time-limit=600"] + restart: always + build: + context: . + target: sylius_php_prod + depends_on: + - mysql + environment: APP_ENV: prod APP_DEBUG: 0 APP_SECRET: EDITME + DATABASE_URL: mysql://sylius:${MYSQL_PASSWORD}@mysql/sylius_prod + MESSENGER_TRANSPORT_DSN: doctrine://default + PHP_DATE_TIMEZONE: ${PHP_DATE_TIMEZONE:-UTC} networks: - sylius diff --git a/public/index.php b/public/index.php index f094a9b193..9982c218d6 100644 --- a/public/index.php +++ b/public/index.php @@ -1,27 +1,9 @@ handle($request); -$response->send(); -$kernel->terminate($request, $response); +return function (array $context) { + return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']); +}; diff --git a/src/Entity/Addressing/Address.php b/src/Entity/Addressing/Address.php index b6bd07d7ae..d9c5f7ccb5 100644 --- a/src/Entity/Addressing/Address.php +++ b/src/Entity/Addressing/Address.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\Address as BaseAddress; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_address") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_address')] class Address extends BaseAddress { } diff --git a/src/Entity/Addressing/Country.php b/src/Entity/Addressing/Country.php index 87dcb07ad5..0f6a276c1a 100644 --- a/src/Entity/Addressing/Country.php +++ b/src/Entity/Addressing/Country.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Addressing\Model\Country as BaseCountry; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_country") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_country')] class Country extends BaseCountry { } diff --git a/src/Entity/Addressing/Province.php b/src/Entity/Addressing/Province.php index 72974307fa..da9a9a4f0b 100644 --- a/src/Entity/Addressing/Province.php +++ b/src/Entity/Addressing/Province.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Addressing\Model\Province as BaseProvince; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_province") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_province')] class Province extends BaseProvince { } diff --git a/src/Entity/Addressing/Zone.php b/src/Entity/Addressing/Zone.php index 1d59932872..aeb84414c2 100644 --- a/src/Entity/Addressing/Zone.php +++ b/src/Entity/Addressing/Zone.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Addressing\Model\Zone as BaseZone; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_zone") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_zone')] class Zone extends BaseZone { } diff --git a/src/Entity/Addressing/ZoneMember.php b/src/Entity/Addressing/ZoneMember.php index 871c3587a0..d2525ad0df 100644 --- a/src/Entity/Addressing/ZoneMember.php +++ b/src/Entity/Addressing/ZoneMember.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Addressing\Model\ZoneMember as BaseZoneMember; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_zone_member") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_zone_member')] class ZoneMember extends BaseZoneMember { } diff --git a/src/Entity/Channel/Channel.php b/src/Entity/Channel/Channel.php index 41602728c0..f62db4219e 100644 --- a/src/Entity/Channel/Channel.php +++ b/src/Entity/Channel/Channel.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\Channel as BaseChannel; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_channel") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_channel')] class Channel extends BaseChannel { } diff --git a/src/Entity/Channel/ChannelPricing.php b/src/Entity/Channel/ChannelPricing.php index 8024ca3d63..855cab81f4 100644 --- a/src/Entity/Channel/ChannelPricing.php +++ b/src/Entity/Channel/ChannelPricing.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\ChannelPricing as BaseChannelPricing; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_channel_pricing") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_channel_pricing')] class ChannelPricing extends BaseChannelPricing { } diff --git a/src/Entity/Currency/Currency.php b/src/Entity/Currency/Currency.php index 9724e3d233..26729ddd78 100644 --- a/src/Entity/Currency/Currency.php +++ b/src/Entity/Currency/Currency.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Currency\Model\Currency as BaseCurrency; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_currency") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_currency')] class Currency extends BaseCurrency { } diff --git a/src/Entity/Currency/ExchangeRate.php b/src/Entity/Currency/ExchangeRate.php index 0a7ea1e6a4..da26b7c5ad 100644 --- a/src/Entity/Currency/ExchangeRate.php +++ b/src/Entity/Currency/ExchangeRate.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Currency\Model\ExchangeRate as BaseExchangeRate; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_exchange_rate") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_exchange_rate')] class ExchangeRate extends BaseExchangeRate { } diff --git a/src/Entity/Customer/Customer.php b/src/Entity/Customer/Customer.php index 5e87a3464d..d623002ac2 100644 --- a/src/Entity/Customer/Customer.php +++ b/src/Entity/Customer/Customer.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\Customer as BaseCustomer; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_customer") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_customer')] class Customer extends BaseCustomer { } diff --git a/src/Entity/Customer/CustomerGroup.php b/src/Entity/Customer/CustomerGroup.php index da3da760a0..a205f1654e 100644 --- a/src/Entity/Customer/CustomerGroup.php +++ b/src/Entity/Customer/CustomerGroup.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Customer\Model\CustomerGroup as BaseCustomerGroup; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_customer_group") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_customer_group')] class CustomerGroup extends BaseCustomerGroup { } diff --git a/src/Entity/Locale/Locale.php b/src/Entity/Locale/Locale.php index 827e91abe3..db909e5791 100644 --- a/src/Entity/Locale/Locale.php +++ b/src/Entity/Locale/Locale.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Locale\Model\Locale as BaseLocale; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_locale") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_locale')] class Locale extends BaseLocale { } diff --git a/src/Entity/Order/Adjustment.php b/src/Entity/Order/Adjustment.php index 6595ea6564..f90c8757b3 100644 --- a/src/Entity/Order/Adjustment.php +++ b/src/Entity/Order/Adjustment.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\Adjustment as BaseAdjustment; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_adjustment") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_adjustment')] class Adjustment extends BaseAdjustment { } diff --git a/src/Entity/Order/Order.php b/src/Entity/Order/Order.php index 67ef7f4d64..093242e0ba 100644 --- a/src/Entity/Order/Order.php +++ b/src/Entity/Order/Order.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\Order as BaseOrder; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_order") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_order')] class Order extends BaseOrder { } diff --git a/src/Entity/Order/OrderItem.php b/src/Entity/Order/OrderItem.php index 03b7edb9a0..05e4cbeb84 100644 --- a/src/Entity/Order/OrderItem.php +++ b/src/Entity/Order/OrderItem.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\OrderItem as BaseOrderItem; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_order_item") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_order_item')] class OrderItem extends BaseOrderItem { } diff --git a/src/Entity/Order/OrderItemUnit.php b/src/Entity/Order/OrderItemUnit.php index 3baba86eb5..73ef6cc498 100644 --- a/src/Entity/Order/OrderItemUnit.php +++ b/src/Entity/Order/OrderItemUnit.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\OrderItemUnit as BaseOrderItemUnit; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_order_item_unit") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_order_item_unit')] class OrderItemUnit extends BaseOrderItemUnit { } diff --git a/src/Entity/Order/OrderSequence.php b/src/Entity/Order/OrderSequence.php index 00a1a5d83f..f7475f5eaa 100644 --- a/src/Entity/Order/OrderSequence.php +++ b/src/Entity/Order/OrderSequence.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\OrderSequence as BaseOrderSequence; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_order_sequence") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_order_sequence')] class OrderSequence extends BaseOrderSequence { } diff --git a/src/Entity/Payment/GatewayConfig.php b/src/Entity/Payment/GatewayConfig.php index 55295264e9..ffed5a0f7a 100644 --- a/src/Entity/Payment/GatewayConfig.php +++ b/src/Entity/Payment/GatewayConfig.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Bundle\PayumBundle\Model\GatewayConfig as BaseGatewayConfig; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_gateway_config") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_gateway_config')] class GatewayConfig extends BaseGatewayConfig { } diff --git a/src/Entity/Payment/Payment.php b/src/Entity/Payment/Payment.php index 4ebeb27af0..d2cefd92e4 100644 --- a/src/Entity/Payment/Payment.php +++ b/src/Entity/Payment/Payment.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\Payment as BasePayment; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_payment") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_payment')] class Payment extends BasePayment { } diff --git a/src/Entity/Payment/PaymentMethod.php b/src/Entity/Payment/PaymentMethod.php index 0387e54ad2..83eb98b29e 100644 --- a/src/Entity/Payment/PaymentMethod.php +++ b/src/Entity/Payment/PaymentMethod.php @@ -8,10 +8,8 @@ use Sylius\Component\Core\Model\PaymentMethod as BasePaymentMethod; use Sylius\Component\Payment\Model\PaymentMethodTranslationInterface; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_payment_method") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_payment_method')] class PaymentMethod extends BasePaymentMethod { protected function createTranslation(): PaymentMethodTranslationInterface diff --git a/src/Entity/Payment/PaymentMethodTranslation.php b/src/Entity/Payment/PaymentMethodTranslation.php index e1696ad4ba..dcf090f4ac 100644 --- a/src/Entity/Payment/PaymentMethodTranslation.php +++ b/src/Entity/Payment/PaymentMethodTranslation.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Payment\Model\PaymentMethodTranslation as BasePaymentMethodTranslation; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_payment_method_translation") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_payment_method_translation')] class PaymentMethodTranslation extends BasePaymentMethodTranslation { } diff --git a/src/Entity/Payment/PaymentSecurityToken.php b/src/Entity/Payment/PaymentSecurityToken.php index b0ed7ea32f..77f7b18472 100644 --- a/src/Entity/Payment/PaymentSecurityToken.php +++ b/src/Entity/Payment/PaymentSecurityToken.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Bundle\PayumBundle\Model\PaymentSecurityToken as BasePaymentSecurityToken; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_payment_security_token") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_payment_security_token')] class PaymentSecurityToken extends BasePaymentSecurityToken { } diff --git a/src/Entity/Product/Product.php b/src/Entity/Product/Product.php index 79cb388987..c5462e02ed 100644 --- a/src/Entity/Product/Product.php +++ b/src/Entity/Product/Product.php @@ -8,10 +8,8 @@ use Sylius\Component\Core\Model\Product as BaseProduct; use Sylius\Component\Product\Model\ProductTranslationInterface; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product')] class Product extends BaseProduct { protected function createTranslation(): ProductTranslationInterface diff --git a/src/Entity/Product/ProductAssociation.php b/src/Entity/Product/ProductAssociation.php index ef56e42182..754e668076 100644 --- a/src/Entity/Product/ProductAssociation.php +++ b/src/Entity/Product/ProductAssociation.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Product\Model\ProductAssociation as BaseProductAssociation; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_association") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_association')] class ProductAssociation extends BaseProductAssociation { } diff --git a/src/Entity/Product/ProductAssociationType.php b/src/Entity/Product/ProductAssociationType.php index 9ec72bb92c..907f66b57e 100644 --- a/src/Entity/Product/ProductAssociationType.php +++ b/src/Entity/Product/ProductAssociationType.php @@ -8,10 +8,8 @@ use Sylius\Component\Product\Model\ProductAssociationType as BaseProductAssociationType; use Sylius\Component\Product\Model\ProductAssociationTypeTranslationInterface; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_association_type") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_association_type')] class ProductAssociationType extends BaseProductAssociationType { protected function createTranslation(): ProductAssociationTypeTranslationInterface diff --git a/src/Entity/Product/ProductAssociationTypeTranslation.php b/src/Entity/Product/ProductAssociationTypeTranslation.php index 26f1d9de27..0e0168c764 100644 --- a/src/Entity/Product/ProductAssociationTypeTranslation.php +++ b/src/Entity/Product/ProductAssociationTypeTranslation.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Product\Model\ProductAssociationTypeTranslation as BaseProductAssociationTypeTranslation; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_association_type_translation") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_association_type_translation')] class ProductAssociationTypeTranslation extends BaseProductAssociationTypeTranslation { } diff --git a/src/Entity/Product/ProductAttribute.php b/src/Entity/Product/ProductAttribute.php index 089b1ebc47..b64895af9d 100644 --- a/src/Entity/Product/ProductAttribute.php +++ b/src/Entity/Product/ProductAttribute.php @@ -8,10 +8,8 @@ use Sylius\Component\Attribute\Model\AttributeTranslationInterface; use Sylius\Component\Product\Model\ProductAttribute as BaseProductAttribute; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_attribute") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_attribute')] class ProductAttribute extends BaseProductAttribute { protected function createTranslation(): AttributeTranslationInterface diff --git a/src/Entity/Product/ProductAttributeTranslation.php b/src/Entity/Product/ProductAttributeTranslation.php index fb30aa9c0e..cfea8cd1b4 100644 --- a/src/Entity/Product/ProductAttributeTranslation.php +++ b/src/Entity/Product/ProductAttributeTranslation.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Product\Model\ProductAttributeTranslation as BaseProductAttributeTranslation; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_attribute_translation") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_attribute_translation')] class ProductAttributeTranslation extends BaseProductAttributeTranslation { } diff --git a/src/Entity/Product/ProductAttributeValue.php b/src/Entity/Product/ProductAttributeValue.php index 2b5c00033e..31cdfa0dab 100644 --- a/src/Entity/Product/ProductAttributeValue.php +++ b/src/Entity/Product/ProductAttributeValue.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Product\Model\ProductAttributeValue as BaseProductAttributeValue; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_attribute_value") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_attribute_value')] class ProductAttributeValue extends BaseProductAttributeValue { } diff --git a/src/Entity/Product/ProductImage.php b/src/Entity/Product/ProductImage.php index b34f9938e2..b2195e46a0 100644 --- a/src/Entity/Product/ProductImage.php +++ b/src/Entity/Product/ProductImage.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\ProductImage as BaseProductImage; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_image") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_image')] class ProductImage extends BaseProductImage { } diff --git a/src/Entity/Product/ProductOption.php b/src/Entity/Product/ProductOption.php index a8a4d045d5..152788b8ed 100644 --- a/src/Entity/Product/ProductOption.php +++ b/src/Entity/Product/ProductOption.php @@ -8,10 +8,8 @@ use Sylius\Component\Product\Model\ProductOption as BaseProductOption; use Sylius\Component\Product\Model\ProductOptionTranslationInterface; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_option") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_option')] class ProductOption extends BaseProductOption { protected function createTranslation(): ProductOptionTranslationInterface diff --git a/src/Entity/Product/ProductOptionTranslation.php b/src/Entity/Product/ProductOptionTranslation.php index a94204bdbd..484b91bf6a 100644 --- a/src/Entity/Product/ProductOptionTranslation.php +++ b/src/Entity/Product/ProductOptionTranslation.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Product\Model\ProductOptionTranslation as BaseProductOptionTranslation; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_option_translation") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_option_translation')] class ProductOptionTranslation extends BaseProductOptionTranslation { } diff --git a/src/Entity/Product/ProductOptionValue.php b/src/Entity/Product/ProductOptionValue.php index 1512cdbf3d..af1c291941 100644 --- a/src/Entity/Product/ProductOptionValue.php +++ b/src/Entity/Product/ProductOptionValue.php @@ -8,10 +8,8 @@ use Sylius\Component\Product\Model\ProductOptionValue as BaseProductOptionValue; use Sylius\Component\Product\Model\ProductOptionValueTranslationInterface; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_option_value") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_option_value')] class ProductOptionValue extends BaseProductOptionValue { protected function createTranslation(): ProductOptionValueTranslationInterface diff --git a/src/Entity/Product/ProductOptionValueTranslation.php b/src/Entity/Product/ProductOptionValueTranslation.php index 66252238d7..068b61635d 100644 --- a/src/Entity/Product/ProductOptionValueTranslation.php +++ b/src/Entity/Product/ProductOptionValueTranslation.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Product\Model\ProductOptionValueTranslation as BaseProductOptionValueTranslation; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_option_value_translation") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_option_value_translation')] class ProductOptionValueTranslation extends BaseProductOptionValueTranslation { } diff --git a/src/Entity/Product/ProductReview.php b/src/Entity/Product/ProductReview.php index e11f85a0a4..205d997d00 100644 --- a/src/Entity/Product/ProductReview.php +++ b/src/Entity/Product/ProductReview.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\ProductReview as BaseProductReview; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_review") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_review')] class ProductReview extends BaseProductReview { } diff --git a/src/Entity/Product/ProductTaxon.php b/src/Entity/Product/ProductTaxon.php index 57464a839c..2ad70f992e 100644 --- a/src/Entity/Product/ProductTaxon.php +++ b/src/Entity/Product/ProductTaxon.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\ProductTaxon as BaseProductTaxon; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_taxon") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_taxon')] class ProductTaxon extends BaseProductTaxon { } diff --git a/src/Entity/Product/ProductTranslation.php b/src/Entity/Product/ProductTranslation.php index 6c55667e74..031272d826 100644 --- a/src/Entity/Product/ProductTranslation.php +++ b/src/Entity/Product/ProductTranslation.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\ProductTranslation as BaseProductTranslation; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_translation") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_translation')] class ProductTranslation extends BaseProductTranslation { } diff --git a/src/Entity/Product/ProductVariant.php b/src/Entity/Product/ProductVariant.php index 7fa223af26..c151e1747e 100644 --- a/src/Entity/Product/ProductVariant.php +++ b/src/Entity/Product/ProductVariant.php @@ -8,10 +8,8 @@ use Sylius\Component\Core\Model\ProductVariant as BaseProductVariant; use Sylius\Component\Product\Model\ProductVariantTranslationInterface; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_variant") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_variant')] class ProductVariant extends BaseProductVariant { protected function createTranslation(): ProductVariantTranslationInterface diff --git a/src/Entity/Product/ProductVariantTranslation.php b/src/Entity/Product/ProductVariantTranslation.php index af08696350..d30f6d168e 100644 --- a/src/Entity/Product/ProductVariantTranslation.php +++ b/src/Entity/Product/ProductVariantTranslation.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Product\Model\ProductVariantTranslation as BaseProductVariantTranslation; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_product_variant_translation") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_product_variant_translation')] class ProductVariantTranslation extends BaseProductVariantTranslation { } diff --git a/src/Entity/Promotion/CatalogPromotion.php b/src/Entity/Promotion/CatalogPromotion.php index 7928a6c31e..e1c250a771 100644 --- a/src/Entity/Promotion/CatalogPromotion.php +++ b/src/Entity/Promotion/CatalogPromotion.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\CatalogPromotion as BaseCatalogPromotion; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_catalog_promotion") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_catalog_promotion')] class CatalogPromotion extends BaseCatalogPromotion { } diff --git a/src/Entity/Promotion/CatalogPromotionAction.php b/src/Entity/Promotion/CatalogPromotionAction.php index a90318a7f0..4257f6342e 100644 --- a/src/Entity/Promotion/CatalogPromotionAction.php +++ b/src/Entity/Promotion/CatalogPromotionAction.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Promotion\Model\CatalogPromotionAction as BaseCatalogPromotionAction; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_catalog_promotion_action") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_catalog_promotion_action')] class CatalogPromotionAction extends BaseCatalogPromotionAction { } diff --git a/src/Entity/Promotion/CatalogPromotionScope.php b/src/Entity/Promotion/CatalogPromotionScope.php index bc6307b4ef..e90bdf8adc 100644 --- a/src/Entity/Promotion/CatalogPromotionScope.php +++ b/src/Entity/Promotion/CatalogPromotionScope.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\CatalogPromotionScope as BaseCatalogPromotionScope; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_catalog_promotion_scope") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_catalog_promotion_scope')] class CatalogPromotionScope extends BaseCatalogPromotionScope { } diff --git a/src/Entity/Promotion/Promotion.php b/src/Entity/Promotion/Promotion.php index cdebdcb8ca..e7b9088e50 100644 --- a/src/Entity/Promotion/Promotion.php +++ b/src/Entity/Promotion/Promotion.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\Promotion as BasePromotion; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_promotion") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_promotion')] class Promotion extends BasePromotion { } diff --git a/src/Entity/Promotion/PromotionAction.php b/src/Entity/Promotion/PromotionAction.php index 68fe7f6347..e822947ab3 100644 --- a/src/Entity/Promotion/PromotionAction.php +++ b/src/Entity/Promotion/PromotionAction.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Promotion\Model\PromotionAction as BasePromotionAction; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_promotion_action") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_promotion_action')] class PromotionAction extends BasePromotionAction { } diff --git a/src/Entity/Promotion/PromotionCoupon.php b/src/Entity/Promotion/PromotionCoupon.php index f70ec126bb..ed79b2300b 100644 --- a/src/Entity/Promotion/PromotionCoupon.php +++ b/src/Entity/Promotion/PromotionCoupon.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\PromotionCoupon as BasePromotionCoupon; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_promotion_coupon") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_promotion_coupon')] class PromotionCoupon extends BasePromotionCoupon { } diff --git a/src/Entity/Promotion/PromotionRule.php b/src/Entity/Promotion/PromotionRule.php index 348c8475e0..9eceb06528 100644 --- a/src/Entity/Promotion/PromotionRule.php +++ b/src/Entity/Promotion/PromotionRule.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Promotion\Model\PromotionRule as BasePromotionRule; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_promotion_rule") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_promotion_rule')] class PromotionRule extends BasePromotionRule { } diff --git a/src/Entity/Shipping/Shipment.php b/src/Entity/Shipping/Shipment.php index 7c4ae5ae77..fe4ee6ce96 100644 --- a/src/Entity/Shipping/Shipment.php +++ b/src/Entity/Shipping/Shipment.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\Shipment as BaseShipment; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_shipment") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_shipment')] class Shipment extends BaseShipment { } diff --git a/src/Entity/Shipping/ShippingCategory.php b/src/Entity/Shipping/ShippingCategory.php index 3e95d3aa82..794236e63f 100644 --- a/src/Entity/Shipping/ShippingCategory.php +++ b/src/Entity/Shipping/ShippingCategory.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Shipping\Model\ShippingCategory as BaseShippingCategory; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_shipping_category") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_shipping_category')] class ShippingCategory extends BaseShippingCategory { } diff --git a/src/Entity/Shipping/ShippingMethod.php b/src/Entity/Shipping/ShippingMethod.php index 30cd0df0ed..21d489e880 100644 --- a/src/Entity/Shipping/ShippingMethod.php +++ b/src/Entity/Shipping/ShippingMethod.php @@ -8,10 +8,8 @@ use Sylius\Component\Core\Model\ShippingMethod as BaseShippingMethod; use Sylius\Component\Shipping\Model\ShippingMethodTranslationInterface; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_shipping_method") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_shipping_method')] class ShippingMethod extends BaseShippingMethod { protected function createTranslation(): ShippingMethodTranslationInterface diff --git a/src/Entity/Shipping/ShippingMethodTranslation.php b/src/Entity/Shipping/ShippingMethodTranslation.php index abdb684e0a..4ebb903731 100644 --- a/src/Entity/Shipping/ShippingMethodTranslation.php +++ b/src/Entity/Shipping/ShippingMethodTranslation.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Shipping\Model\ShippingMethodTranslation as BaseShippingMethodTranslation; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_shipping_method_translation") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_shipping_method_translation')] class ShippingMethodTranslation extends BaseShippingMethodTranslation { } diff --git a/src/Entity/Taxation/TaxCategory.php b/src/Entity/Taxation/TaxCategory.php index 7ceecf9a1e..29cf19a0f0 100644 --- a/src/Entity/Taxation/TaxCategory.php +++ b/src/Entity/Taxation/TaxCategory.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Taxation\Model\TaxCategory as BaseTaxCategory; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_tax_category") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_tax_category')] class TaxCategory extends BaseTaxCategory { } diff --git a/src/Entity/Taxation/TaxRate.php b/src/Entity/Taxation/TaxRate.php index 545cea21d8..0b681a964a 100644 --- a/src/Entity/Taxation/TaxRate.php +++ b/src/Entity/Taxation/TaxRate.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\TaxRate as BaseTaxRate; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_tax_rate") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_tax_rate')] class TaxRate extends BaseTaxRate { } diff --git a/src/Entity/Taxonomy/Taxon.php b/src/Entity/Taxonomy/Taxon.php index a8151b6b16..fe85db5337 100644 --- a/src/Entity/Taxonomy/Taxon.php +++ b/src/Entity/Taxonomy/Taxon.php @@ -8,10 +8,8 @@ use Sylius\Component\Core\Model\Taxon as BaseTaxon; use Sylius\Component\Taxonomy\Model\TaxonTranslationInterface; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_taxon") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_taxon')] class Taxon extends BaseTaxon { protected function createTranslation(): TaxonTranslationInterface diff --git a/src/Entity/Taxonomy/TaxonImage.php b/src/Entity/Taxonomy/TaxonImage.php index 192414ffd2..458f2db781 100644 --- a/src/Entity/Taxonomy/TaxonImage.php +++ b/src/Entity/Taxonomy/TaxonImage.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\TaxonImage as BaseTaxonImage; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_taxon_image") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_taxon_image')] class TaxonImage extends BaseTaxonImage { } diff --git a/src/Entity/Taxonomy/TaxonTranslation.php b/src/Entity/Taxonomy/TaxonTranslation.php index 525be716c4..fddde85831 100644 --- a/src/Entity/Taxonomy/TaxonTranslation.php +++ b/src/Entity/Taxonomy/TaxonTranslation.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Taxonomy\Model\TaxonTranslation as BaseTaxonTranslation; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_taxon_translation") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_taxon_translation')] class TaxonTranslation extends BaseTaxonTranslation { } diff --git a/src/Entity/User/AdminUser.php b/src/Entity/User/AdminUser.php index 61c00a6bfe..49ccb011e6 100644 --- a/src/Entity/User/AdminUser.php +++ b/src/Entity/User/AdminUser.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\AdminUser as BaseAdminUser; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_admin_user") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_admin_user')] class AdminUser extends BaseAdminUser { } diff --git a/src/Entity/User/ShopUser.php b/src/Entity/User/ShopUser.php index c573d8d893..9e114e6d5a 100644 --- a/src/Entity/User/ShopUser.php +++ b/src/Entity/User/ShopUser.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\Core\Model\ShopUser as BaseShopUser; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_shop_user") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_shop_user')] class ShopUser extends BaseShopUser { } diff --git a/src/Entity/User/UserOAuth.php b/src/Entity/User/UserOAuth.php index ad59566b2f..9645086f0a 100644 --- a/src/Entity/User/UserOAuth.php +++ b/src/Entity/User/UserOAuth.php @@ -7,10 +7,8 @@ use Doctrine\ORM\Mapping as ORM; use Sylius\Component\User\Model\UserOAuth as BaseUserOAuth; -/** - * @ORM\Entity - * @ORM\Table(name="sylius_user_oauth") - */ +#[ORM\Entity] +#[ORM\Table(name: 'sylius_user_oauth')] class UserOAuth extends BaseUserOAuth { }