From 6713b09b93a63403b2a7f043d630ce0d1841e376 Mon Sep 17 00:00:00 2001 From: janpalen Date: Fri, 10 Jan 2025 12:36:08 +0100 Subject: [PATCH] OP-550 - Change structures of the directories to current Symfony recommendations --- .github/workflows/build.yml | 7 ++++--- {src/Resources/assets => assets}/admin/entry.js | 0 {src/Resources/assets => assets}/admin/js/index.js | 0 {src/Resources/assets => assets}/admin/scss/main.scss | 0 {src/Resources/assets => assets}/shop/entry.js | 0 {src/Resources/assets => assets}/shop/js/index.js | 0 {src/Resources/assets => assets}/shop/scss/main.scss | 0 .../api_resources/admin/ProductBundle.xml | 0 .../config => config}/api_resources/shop/Order.xml | 0 .../config => config}/api_resources/shop/Product.xml | 0 .../api_resources/shop/ProductBundle.xml | 0 .../api_resources/shop/ProductBundleItem.xml | 0 config/config.yml | 9 +++++++++ .../config => config}/doctrine/ProductBundle.orm.xml | 0 .../doctrine/ProductBundleItem.orm.xml | 0 .../doctrine/ProductBundleOrderItem.orm.xml | 0 config/resources.yml | 4 ++++ .../config => config}/resources/product_bundle.yml | 0 .../resources/product_bundle_item.yml | 0 .../resources/product_bundle_order_item.yml | 0 config/routes.yml | 10 ++++++++++ .../config/routing => config/routes}/admin.yml | 0 .../config/routing => config/routes}/shop.yml | 0 .../serialization/AddProductBundleToCartCommand.xml | 0 .../serialization/AddProductBundleToCartDto.xml | 0 .../config => config}/serialization/OrderItem.xml | 0 .../config => config}/serialization/Product.xml | 0 .../config => config}/serialization/ProductBundle.xml | 0 .../serialization/ProductBundleItem.xml | 0 .../serialization/ProductBundleOrderItem.xml | 0 .../config => config}/serialization/ProductVariant.xml | 0 .../serialization/ProductVariantTranslation.xml | 0 {src/Resources/config => config}/services.xml | 0 .../config => config}/services/controller.xml | 0 .../config => config}/services/event_listener.xml | 0 {src/Resources/config => config}/services/factory.xml | 0 {src/Resources/config => config}/services/form.xml | 0 {src/Resources/config => config}/services/handler.xml | 0 {src/Resources/config => config}/services/menu.xml | 0 .../Resources/config => config}/services/processor.xml | 0 {src/Resources/config => config}/services/product.xml | 0 .../config => config}/services/transformer.xml | 0 {src/Resources/config => config}/services/twig.xml | 0 .../Resources/config => config}/services/validator.xml | 0 .../config => config}/twig_hooks/order/show.yaml | 0 .../twig_hooks/product/admin/create.yaml | 0 .../twig_hooks/product/admin/update.yaml | 0 .../twig_hooks/product/shop/show.yaml | 0 config/twig_hooks/twig_hooks.yaml | 3 +++ .../validation/AddProductBundleToCartCommand.xml | 0 .../validation/AddProductBundleToCartDto.xml | 0 .../config => config}/validation/ProductBundle.xml | 0 .../config => config}/validation/ProductBundleItem.xml | 0 etc/build/.gitignore | 0 src/BitBagSyliusProductBundlePlugin.php | 5 +++++ src/Resources/config/config.yml | 9 --------- src/Resources/config/resources.yml | 4 ---- src/Resources/config/routing.yml | 7 ------- src/Resources/config/twig_hooks/twig_hooks.yaml | 3 --- .../Order/Show/_productBundleOrderItems.html.twig | 0 .../Admin/product/form/sections/bundle.html.twig | 0 .../form/sections/bundle/productBundleItem.html.twig | 0 .../product/form/side_navigation/bundle.html.twig | 0 .../add_to_cart/addProductBundleToCart.html.twig | 0 .../packages/bitbag_sylius_product_bundle_plugin.yml | 2 +- tests/Application/config/routes.yaml | 2 +- .../translations => translations}/messages.en.yml | 0 .../translations => translations}/messages.fr.yml | 0 .../translations => translations}/messages.nl.yml | 0 .../translations => translations}/validators.en.yml | 0 .../translations => translations}/validators.fr.yml | 0 .../translations => translations}/validators.nl.yml | 0 webpack.config.js | 6 +++--- 73 files changed, 40 insertions(+), 31 deletions(-) rename {src/Resources/assets => assets}/admin/entry.js (100%) rename {src/Resources/assets => assets}/admin/js/index.js (100%) rename {src/Resources/assets => assets}/admin/scss/main.scss (100%) rename {src/Resources/assets => assets}/shop/entry.js (100%) rename {src/Resources/assets => assets}/shop/js/index.js (100%) rename {src/Resources/assets => assets}/shop/scss/main.scss (100%) rename {src/Resources/config => config}/api_resources/admin/ProductBundle.xml (100%) rename {src/Resources/config => config}/api_resources/shop/Order.xml (100%) rename {src/Resources/config => config}/api_resources/shop/Product.xml (100%) rename {src/Resources/config => config}/api_resources/shop/ProductBundle.xml (100%) rename {src/Resources/config => config}/api_resources/shop/ProductBundleItem.xml (100%) create mode 100644 config/config.yml rename {src/Resources/config => config}/doctrine/ProductBundle.orm.xml (100%) rename {src/Resources/config => config}/doctrine/ProductBundleItem.orm.xml (100%) rename {src/Resources/config => config}/doctrine/ProductBundleOrderItem.orm.xml (100%) create mode 100644 config/resources.yml rename {src/Resources/config => config}/resources/product_bundle.yml (100%) rename {src/Resources/config => config}/resources/product_bundle_item.yml (100%) rename {src/Resources/config => config}/resources/product_bundle_order_item.yml (100%) create mode 100644 config/routes.yml rename {src/Resources/config/routing => config/routes}/admin.yml (100%) rename {src/Resources/config/routing => config/routes}/shop.yml (100%) rename {src/Resources/config => config}/serialization/AddProductBundleToCartCommand.xml (100%) rename {src/Resources/config => config}/serialization/AddProductBundleToCartDto.xml (100%) rename {src/Resources/config => config}/serialization/OrderItem.xml (100%) rename {src/Resources/config => config}/serialization/Product.xml (100%) rename {src/Resources/config => config}/serialization/ProductBundle.xml (100%) rename {src/Resources/config => config}/serialization/ProductBundleItem.xml (100%) rename {src/Resources/config => config}/serialization/ProductBundleOrderItem.xml (100%) rename {src/Resources/config => config}/serialization/ProductVariant.xml (100%) rename {src/Resources/config => config}/serialization/ProductVariantTranslation.xml (100%) rename {src/Resources/config => config}/services.xml (100%) rename {src/Resources/config => config}/services/controller.xml (100%) rename {src/Resources/config => config}/services/event_listener.xml (100%) rename {src/Resources/config => config}/services/factory.xml (100%) rename {src/Resources/config => config}/services/form.xml (100%) rename {src/Resources/config => config}/services/handler.xml (100%) rename {src/Resources/config => config}/services/menu.xml (100%) rename {src/Resources/config => config}/services/processor.xml (100%) rename {src/Resources/config => config}/services/product.xml (100%) rename {src/Resources/config => config}/services/transformer.xml (100%) rename {src/Resources/config => config}/services/twig.xml (100%) rename {src/Resources/config => config}/services/validator.xml (100%) rename {src/Resources/config => config}/twig_hooks/order/show.yaml (100%) rename {src/Resources/config => config}/twig_hooks/product/admin/create.yaml (100%) rename {src/Resources/config => config}/twig_hooks/product/admin/update.yaml (100%) rename {src/Resources/config => config}/twig_hooks/product/shop/show.yaml (100%) create mode 100644 config/twig_hooks/twig_hooks.yaml rename {src/Resources/config => config}/validation/AddProductBundleToCartCommand.xml (100%) rename {src/Resources/config => config}/validation/AddProductBundleToCartDto.xml (100%) rename {src/Resources/config => config}/validation/ProductBundle.xml (100%) rename {src/Resources/config => config}/validation/ProductBundleItem.xml (100%) delete mode 100644 etc/build/.gitignore delete mode 100644 src/Resources/config/config.yml delete mode 100644 src/Resources/config/resources.yml delete mode 100644 src/Resources/config/routing.yml delete mode 100644 src/Resources/config/twig_hooks/twig_hooks.yaml rename {src/Resources/views => templates}/Admin/Order/Show/_productBundleOrderItems.html.twig (100%) rename {src/Resources/views => templates}/Admin/product/form/sections/bundle.html.twig (100%) rename {src/Resources/views => templates}/Admin/product/form/sections/bundle/productBundleItem.html.twig (100%) rename {src/Resources/views => templates}/Admin/product/form/side_navigation/bundle.html.twig (100%) rename {src/Resources/views/Shop/Product => templates/Shop/product}/show/page/info/summary/add_to_cart/addProductBundleToCart.html.twig (100%) rename {src/Resources/translations => translations}/messages.en.yml (100%) rename {src/Resources/translations => translations}/messages.fr.yml (100%) rename {src/Resources/translations => translations}/messages.nl.yml (100%) rename {src/Resources/translations => translations}/validators.en.yml (100%) rename {src/Resources/translations => translations}/validators.fr.yml (100%) rename {src/Resources/translations => translations}/validators.nl.yml (100%) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d6641eb2..c3098f44 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -160,8 +160,8 @@ jobs: run: vendor/bin/phpunit --colors=always - - name: Cache clear - run: (cd tests/Application && rm -rf var/cache) + name: Create behat logs directory + run: (mkdir -p etc/build && chmod a+rw etc/build ) - name: Run Behat @@ -169,12 +169,13 @@ jobs: - name: Upload Behat logs - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 if: failure() with: name: Behat logs path: etc/build/ if-no-files-found: ignore + overwrite: true - name: Failed build Slack notification diff --git a/src/Resources/assets/admin/entry.js b/assets/admin/entry.js similarity index 100% rename from src/Resources/assets/admin/entry.js rename to assets/admin/entry.js diff --git a/src/Resources/assets/admin/js/index.js b/assets/admin/js/index.js similarity index 100% rename from src/Resources/assets/admin/js/index.js rename to assets/admin/js/index.js diff --git a/src/Resources/assets/admin/scss/main.scss b/assets/admin/scss/main.scss similarity index 100% rename from src/Resources/assets/admin/scss/main.scss rename to assets/admin/scss/main.scss diff --git a/src/Resources/assets/shop/entry.js b/assets/shop/entry.js similarity index 100% rename from src/Resources/assets/shop/entry.js rename to assets/shop/entry.js diff --git a/src/Resources/assets/shop/js/index.js b/assets/shop/js/index.js similarity index 100% rename from src/Resources/assets/shop/js/index.js rename to assets/shop/js/index.js diff --git a/src/Resources/assets/shop/scss/main.scss b/assets/shop/scss/main.scss similarity index 100% rename from src/Resources/assets/shop/scss/main.scss rename to assets/shop/scss/main.scss diff --git a/src/Resources/config/api_resources/admin/ProductBundle.xml b/config/api_resources/admin/ProductBundle.xml similarity index 100% rename from src/Resources/config/api_resources/admin/ProductBundle.xml rename to config/api_resources/admin/ProductBundle.xml diff --git a/src/Resources/config/api_resources/shop/Order.xml b/config/api_resources/shop/Order.xml similarity index 100% rename from src/Resources/config/api_resources/shop/Order.xml rename to config/api_resources/shop/Order.xml diff --git a/src/Resources/config/api_resources/shop/Product.xml b/config/api_resources/shop/Product.xml similarity index 100% rename from src/Resources/config/api_resources/shop/Product.xml rename to config/api_resources/shop/Product.xml diff --git a/src/Resources/config/api_resources/shop/ProductBundle.xml b/config/api_resources/shop/ProductBundle.xml similarity index 100% rename from src/Resources/config/api_resources/shop/ProductBundle.xml rename to config/api_resources/shop/ProductBundle.xml diff --git a/src/Resources/config/api_resources/shop/ProductBundleItem.xml b/config/api_resources/shop/ProductBundleItem.xml similarity index 100% rename from src/Resources/config/api_resources/shop/ProductBundleItem.xml rename to config/api_resources/shop/ProductBundleItem.xml diff --git a/config/config.yml b/config/config.yml new file mode 100644 index 00000000..5027b3b3 --- /dev/null +++ b/config/config.yml @@ -0,0 +1,9 @@ +imports: + - { resource: resources.yml } + - { resource: services.xml } + - { resource: "@BitBagSyliusProductBundlePlugin/config/twig_hooks/twig_hooks.yaml" } + +framework: + messenger: + buses: + bitbag_sylius_product_bundle.command_bus: ~ diff --git a/src/Resources/config/doctrine/ProductBundle.orm.xml b/config/doctrine/ProductBundle.orm.xml similarity index 100% rename from src/Resources/config/doctrine/ProductBundle.orm.xml rename to config/doctrine/ProductBundle.orm.xml diff --git a/src/Resources/config/doctrine/ProductBundleItem.orm.xml b/config/doctrine/ProductBundleItem.orm.xml similarity index 100% rename from src/Resources/config/doctrine/ProductBundleItem.orm.xml rename to config/doctrine/ProductBundleItem.orm.xml diff --git a/src/Resources/config/doctrine/ProductBundleOrderItem.orm.xml b/config/doctrine/ProductBundleOrderItem.orm.xml similarity index 100% rename from src/Resources/config/doctrine/ProductBundleOrderItem.orm.xml rename to config/doctrine/ProductBundleOrderItem.orm.xml diff --git a/config/resources.yml b/config/resources.yml new file mode 100644 index 00000000..f9720b2f --- /dev/null +++ b/config/resources.yml @@ -0,0 +1,4 @@ +imports: + - { resource: resources/product_bundle.yml } + - { resource: resources/product_bundle_item.yml } + - { resource: resources/product_bundle_order_item.yml } diff --git a/src/Resources/config/resources/product_bundle.yml b/config/resources/product_bundle.yml similarity index 100% rename from src/Resources/config/resources/product_bundle.yml rename to config/resources/product_bundle.yml diff --git a/src/Resources/config/resources/product_bundle_item.yml b/config/resources/product_bundle_item.yml similarity index 100% rename from src/Resources/config/resources/product_bundle_item.yml rename to config/resources/product_bundle_item.yml diff --git a/src/Resources/config/resources/product_bundle_order_item.yml b/config/resources/product_bundle_order_item.yml similarity index 100% rename from src/Resources/config/resources/product_bundle_order_item.yml rename to config/resources/product_bundle_order_item.yml diff --git a/config/routes.yml b/config/routes.yml new file mode 100644 index 00000000..4b892704 --- /dev/null +++ b/config/routes.yml @@ -0,0 +1,10 @@ +bitbag_sylius_product_bundle_admin: + resource: routes/admin.yml + prefix: '/%sylius_admin.path_name%' + +bitbag_sylius_product_bundle_shop: + resource: routes/shop.yml + prefix: /{_locale} + requirements: + _locale: ^[a-z]{2}(?:_[A-Z]{2})?$ + diff --git a/src/Resources/config/routing/admin.yml b/config/routes/admin.yml similarity index 100% rename from src/Resources/config/routing/admin.yml rename to config/routes/admin.yml diff --git a/src/Resources/config/routing/shop.yml b/config/routes/shop.yml similarity index 100% rename from src/Resources/config/routing/shop.yml rename to config/routes/shop.yml diff --git a/src/Resources/config/serialization/AddProductBundleToCartCommand.xml b/config/serialization/AddProductBundleToCartCommand.xml similarity index 100% rename from src/Resources/config/serialization/AddProductBundleToCartCommand.xml rename to config/serialization/AddProductBundleToCartCommand.xml diff --git a/src/Resources/config/serialization/AddProductBundleToCartDto.xml b/config/serialization/AddProductBundleToCartDto.xml similarity index 100% rename from src/Resources/config/serialization/AddProductBundleToCartDto.xml rename to config/serialization/AddProductBundleToCartDto.xml diff --git a/src/Resources/config/serialization/OrderItem.xml b/config/serialization/OrderItem.xml similarity index 100% rename from src/Resources/config/serialization/OrderItem.xml rename to config/serialization/OrderItem.xml diff --git a/src/Resources/config/serialization/Product.xml b/config/serialization/Product.xml similarity index 100% rename from src/Resources/config/serialization/Product.xml rename to config/serialization/Product.xml diff --git a/src/Resources/config/serialization/ProductBundle.xml b/config/serialization/ProductBundle.xml similarity index 100% rename from src/Resources/config/serialization/ProductBundle.xml rename to config/serialization/ProductBundle.xml diff --git a/src/Resources/config/serialization/ProductBundleItem.xml b/config/serialization/ProductBundleItem.xml similarity index 100% rename from src/Resources/config/serialization/ProductBundleItem.xml rename to config/serialization/ProductBundleItem.xml diff --git a/src/Resources/config/serialization/ProductBundleOrderItem.xml b/config/serialization/ProductBundleOrderItem.xml similarity index 100% rename from src/Resources/config/serialization/ProductBundleOrderItem.xml rename to config/serialization/ProductBundleOrderItem.xml diff --git a/src/Resources/config/serialization/ProductVariant.xml b/config/serialization/ProductVariant.xml similarity index 100% rename from src/Resources/config/serialization/ProductVariant.xml rename to config/serialization/ProductVariant.xml diff --git a/src/Resources/config/serialization/ProductVariantTranslation.xml b/config/serialization/ProductVariantTranslation.xml similarity index 100% rename from src/Resources/config/serialization/ProductVariantTranslation.xml rename to config/serialization/ProductVariantTranslation.xml diff --git a/src/Resources/config/services.xml b/config/services.xml similarity index 100% rename from src/Resources/config/services.xml rename to config/services.xml diff --git a/src/Resources/config/services/controller.xml b/config/services/controller.xml similarity index 100% rename from src/Resources/config/services/controller.xml rename to config/services/controller.xml diff --git a/src/Resources/config/services/event_listener.xml b/config/services/event_listener.xml similarity index 100% rename from src/Resources/config/services/event_listener.xml rename to config/services/event_listener.xml diff --git a/src/Resources/config/services/factory.xml b/config/services/factory.xml similarity index 100% rename from src/Resources/config/services/factory.xml rename to config/services/factory.xml diff --git a/src/Resources/config/services/form.xml b/config/services/form.xml similarity index 100% rename from src/Resources/config/services/form.xml rename to config/services/form.xml diff --git a/src/Resources/config/services/handler.xml b/config/services/handler.xml similarity index 100% rename from src/Resources/config/services/handler.xml rename to config/services/handler.xml diff --git a/src/Resources/config/services/menu.xml b/config/services/menu.xml similarity index 100% rename from src/Resources/config/services/menu.xml rename to config/services/menu.xml diff --git a/src/Resources/config/services/processor.xml b/config/services/processor.xml similarity index 100% rename from src/Resources/config/services/processor.xml rename to config/services/processor.xml diff --git a/src/Resources/config/services/product.xml b/config/services/product.xml similarity index 100% rename from src/Resources/config/services/product.xml rename to config/services/product.xml diff --git a/src/Resources/config/services/transformer.xml b/config/services/transformer.xml similarity index 100% rename from src/Resources/config/services/transformer.xml rename to config/services/transformer.xml diff --git a/src/Resources/config/services/twig.xml b/config/services/twig.xml similarity index 100% rename from src/Resources/config/services/twig.xml rename to config/services/twig.xml diff --git a/src/Resources/config/services/validator.xml b/config/services/validator.xml similarity index 100% rename from src/Resources/config/services/validator.xml rename to config/services/validator.xml diff --git a/src/Resources/config/twig_hooks/order/show.yaml b/config/twig_hooks/order/show.yaml similarity index 100% rename from src/Resources/config/twig_hooks/order/show.yaml rename to config/twig_hooks/order/show.yaml diff --git a/src/Resources/config/twig_hooks/product/admin/create.yaml b/config/twig_hooks/product/admin/create.yaml similarity index 100% rename from src/Resources/config/twig_hooks/product/admin/create.yaml rename to config/twig_hooks/product/admin/create.yaml diff --git a/src/Resources/config/twig_hooks/product/admin/update.yaml b/config/twig_hooks/product/admin/update.yaml similarity index 100% rename from src/Resources/config/twig_hooks/product/admin/update.yaml rename to config/twig_hooks/product/admin/update.yaml diff --git a/src/Resources/config/twig_hooks/product/shop/show.yaml b/config/twig_hooks/product/shop/show.yaml similarity index 100% rename from src/Resources/config/twig_hooks/product/shop/show.yaml rename to config/twig_hooks/product/shop/show.yaml diff --git a/config/twig_hooks/twig_hooks.yaml b/config/twig_hooks/twig_hooks.yaml new file mode 100644 index 00000000..266693c8 --- /dev/null +++ b/config/twig_hooks/twig_hooks.yaml @@ -0,0 +1,3 @@ +imports: + - { resource: "@BitBagSyliusProductBundlePlugin/config/twig_hooks/product/**/*.yaml" } + - { resource: "@BitBagSyliusProductBundlePlugin/config/twig_hooks/order/*.yaml" } diff --git a/src/Resources/config/validation/AddProductBundleToCartCommand.xml b/config/validation/AddProductBundleToCartCommand.xml similarity index 100% rename from src/Resources/config/validation/AddProductBundleToCartCommand.xml rename to config/validation/AddProductBundleToCartCommand.xml diff --git a/src/Resources/config/validation/AddProductBundleToCartDto.xml b/config/validation/AddProductBundleToCartDto.xml similarity index 100% rename from src/Resources/config/validation/AddProductBundleToCartDto.xml rename to config/validation/AddProductBundleToCartDto.xml diff --git a/src/Resources/config/validation/ProductBundle.xml b/config/validation/ProductBundle.xml similarity index 100% rename from src/Resources/config/validation/ProductBundle.xml rename to config/validation/ProductBundle.xml diff --git a/src/Resources/config/validation/ProductBundleItem.xml b/config/validation/ProductBundleItem.xml similarity index 100% rename from src/Resources/config/validation/ProductBundleItem.xml rename to config/validation/ProductBundleItem.xml diff --git a/etc/build/.gitignore b/etc/build/.gitignore deleted file mode 100644 index e69de29b..00000000 diff --git a/src/BitBagSyliusProductBundlePlugin.php b/src/BitBagSyliusProductBundlePlugin.php index add4e915..c89787a1 100644 --- a/src/BitBagSyliusProductBundlePlugin.php +++ b/src/BitBagSyliusProductBundlePlugin.php @@ -20,6 +20,11 @@ final class BitBagSyliusProductBundlePlugin extends Bundle { use SyliusPluginTrait; + public function getPath(): string + { + return \dirname(__DIR__); + } + public function build(ContainerBuilder $container): void { $container->addCompilerPass(new AuthenticationManagerPolyfillPass()); diff --git a/src/Resources/config/config.yml b/src/Resources/config/config.yml deleted file mode 100644 index 153da42b..00000000 --- a/src/Resources/config/config.yml +++ /dev/null @@ -1,9 +0,0 @@ -imports: - - { resource: resources.yml } - - { resource: services.xml } - - { resource: "@BitBagSyliusProductBundlePlugin/Resources/config/twig_hooks/twig_hooks.yaml" } - -framework: - messenger: - buses: - bitbag_sylius_product_bundle.command_bus: ~ diff --git a/src/Resources/config/resources.yml b/src/Resources/config/resources.yml deleted file mode 100644 index 564c562c..00000000 --- a/src/Resources/config/resources.yml +++ /dev/null @@ -1,4 +0,0 @@ -imports: - - { resource: resources/product_bundle.yml } - - { resource: resources/product_bundle_item.yml } - - { resource: resources/product_bundle_order_item.yml } diff --git a/src/Resources/config/routing.yml b/src/Resources/config/routing.yml deleted file mode 100644 index 1a87e161..00000000 --- a/src/Resources/config/routing.yml +++ /dev/null @@ -1,7 +0,0 @@ -bitbag_sylius_product_bundle_admin: - resource: routing/admin.yml - prefix: /admin - -bitbag_sylius_product_bundle_shop: - resource: routing/shop.yml - prefix: /{_locale} diff --git a/src/Resources/config/twig_hooks/twig_hooks.yaml b/src/Resources/config/twig_hooks/twig_hooks.yaml deleted file mode 100644 index 3d585086..00000000 --- a/src/Resources/config/twig_hooks/twig_hooks.yaml +++ /dev/null @@ -1,3 +0,0 @@ -imports: - - { resource: "@BitBagSyliusProductBundlePlugin/Resources/config/twig_hooks/product/**/*.yaml" } - - { resource: "@BitBagSyliusProductBundlePlugin/Resources/config/twig_hooks/order/*.yaml" } diff --git a/src/Resources/views/Admin/Order/Show/_productBundleOrderItems.html.twig b/templates/Admin/Order/Show/_productBundleOrderItems.html.twig similarity index 100% rename from src/Resources/views/Admin/Order/Show/_productBundleOrderItems.html.twig rename to templates/Admin/Order/Show/_productBundleOrderItems.html.twig diff --git a/src/Resources/views/Admin/product/form/sections/bundle.html.twig b/templates/Admin/product/form/sections/bundle.html.twig similarity index 100% rename from src/Resources/views/Admin/product/form/sections/bundle.html.twig rename to templates/Admin/product/form/sections/bundle.html.twig diff --git a/src/Resources/views/Admin/product/form/sections/bundle/productBundleItem.html.twig b/templates/Admin/product/form/sections/bundle/productBundleItem.html.twig similarity index 100% rename from src/Resources/views/Admin/product/form/sections/bundle/productBundleItem.html.twig rename to templates/Admin/product/form/sections/bundle/productBundleItem.html.twig diff --git a/src/Resources/views/Admin/product/form/side_navigation/bundle.html.twig b/templates/Admin/product/form/side_navigation/bundle.html.twig similarity index 100% rename from src/Resources/views/Admin/product/form/side_navigation/bundle.html.twig rename to templates/Admin/product/form/side_navigation/bundle.html.twig diff --git a/src/Resources/views/Shop/Product/show/page/info/summary/add_to_cart/addProductBundleToCart.html.twig b/templates/Shop/product/show/page/info/summary/add_to_cart/addProductBundleToCart.html.twig similarity index 100% rename from src/Resources/views/Shop/Product/show/page/info/summary/add_to_cart/addProductBundleToCart.html.twig rename to templates/Shop/product/show/page/info/summary/add_to_cart/addProductBundleToCart.html.twig diff --git a/tests/Application/config/packages/bitbag_sylius_product_bundle_plugin.yml b/tests/Application/config/packages/bitbag_sylius_product_bundle_plugin.yml index bd17eb83..31f6cb60 100644 --- a/tests/Application/config/packages/bitbag_sylius_product_bundle_plugin.yml +++ b/tests/Application/config/packages/bitbag_sylius_product_bundle_plugin.yml @@ -1,2 +1,2 @@ imports: - - { resource: "@BitBagSyliusProductBundlePlugin/Resources/config/config.yml" } + - { resource: "@BitBagSyliusProductBundlePlugin/config/config.yml" } diff --git a/tests/Application/config/routes.yaml b/tests/Application/config/routes.yaml index 7b7ee8bd..c77f4c4d 100644 --- a/tests/Application/config/routes.yaml +++ b/tests/Application/config/routes.yaml @@ -1,2 +1,2 @@ bitbag_sylius_product_bundle_plugin: - resource: "@BitBagSyliusProductBundlePlugin/Resources/config/routing.yml" + resource: "@BitBagSyliusProductBundlePlugin/config/routes.yml" diff --git a/src/Resources/translations/messages.en.yml b/translations/messages.en.yml similarity index 100% rename from src/Resources/translations/messages.en.yml rename to translations/messages.en.yml diff --git a/src/Resources/translations/messages.fr.yml b/translations/messages.fr.yml similarity index 100% rename from src/Resources/translations/messages.fr.yml rename to translations/messages.fr.yml diff --git a/src/Resources/translations/messages.nl.yml b/translations/messages.nl.yml similarity index 100% rename from src/Resources/translations/messages.nl.yml rename to translations/messages.nl.yml diff --git a/src/Resources/translations/validators.en.yml b/translations/validators.en.yml similarity index 100% rename from src/Resources/translations/validators.en.yml rename to translations/validators.en.yml diff --git a/src/Resources/translations/validators.fr.yml b/translations/validators.fr.yml similarity index 100% rename from src/Resources/translations/validators.fr.yml rename to translations/validators.fr.yml diff --git a/src/Resources/translations/validators.nl.yml b/translations/validators.nl.yml similarity index 100% rename from src/Resources/translations/validators.nl.yml rename to translations/validators.nl.yml diff --git a/webpack.config.js b/webpack.config.js index 82afaa70..8246a8b9 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -8,7 +8,7 @@ const getConfig = (pluginName, type) => { Encore .setOutputPath(`public/build/bitbag/${pluginName}/${type}/`) .setPublicPath(`/build/bitbag/${pluginName}/${type}/`) - .addEntry(`bitbag-${pluginName}-${type}`, path.resolve(__dirname, `./src/Resources/assets/${type}/entry.js`)) + .addEntry(`bitbag-${pluginName}-${type}`, path.resolve(__dirname, `./assets/${type}/entry.js`)) .disableSingleRuntimeChunk() .cleanupOutputBeforeBuild() .enableSourceMaps(!Encore.isProduction()) @@ -23,8 +23,8 @@ const getConfig = (pluginName, type) => { Encore .setOutputPath(`src/Resources/public/`) .setPublicPath(`/public/`) - .addEntry(`bitbag-${pluginName}-shop`, path.resolve(__dirname, `./src/Resources/assets/shop/entry.js`)) - .addEntry(`bitbag-${pluginName}-admin`, path.resolve(__dirname, `./src/Resources/assets/admin/entry.js`)) + .addEntry(`bitbag-${pluginName}-shop`, path.resolve(__dirname, `./assets/shop/entry.js`)) + .addEntry(`bitbag-${pluginName}-admin`, path.resolve(__dirname, `./assets/admin/entry.js`)) .cleanupOutputBeforeBuild() .disableSingleRuntimeChunk() .enableSassLoader();