-
-
Notifications
You must be signed in to change notification settings - Fork 662
[SyliusResourceBundle] Update routing configuration #1831
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
loic425
commented
Jul 9, 2025
Q | A |
---|---|
License | MIT |
Packagist | https://packagist.org/packages/sylius/resource-bundle |
Thanks for the PR 😍 How to test these changes in your application
Diff between recipe versionsIn order to help with the review stage, I'm in charge of computing the diff between the various versions of patched recipes. sylius/resource-bundle1.6 vs 1.9diff --git a/sylius/resource-bundle/1.6/config/packages/sylius_resource.yaml b/sylius/resource-bundle/1.9/config/packages/sylius_resource.yaml
index df27a441..6b42a484 100644
--- a/sylius/resource-bundle/1.6/config/packages/sylius_resource.yaml
+++ b/sylius/resource-bundle/1.9/config/packages/sylius_resource.yaml
@@ -3,6 +3,11 @@ sylius_resource:
# Override default settings
#settings:
+ # Configure the mapping for your resources
+ mapping:
+ paths:
+ - '%kernel.project_dir%/src/Entity'
+
# Configure your resources
resources:
#app.book:
diff --git a/sylius/resource-bundle/1.9/config/routes/sylius_resource.yaml b/sylius/resource-bundle/1.9/config/routes/sylius_resource.yaml
new file mode 100644
index 00000000..0c8ade2c
--- /dev/null
+++ b/sylius/resource-bundle/1.9/config/routes/sylius_resource.yaml
@@ -0,0 +1,7 @@
+sylius_crud_routes:
+ resource: 'sylius.routing.loader.crud_routes_attributes'
+ type: service
+
+sylius_routes:
+ resource: 'sylius.routing.loader.routes_attributes'
+ type: service 1.9 vs 1.12diff --git a/sylius/resource-bundle/1.9/manifest.json b/sylius/resource-bundle/1.12/manifest.json
index a26e89c8..a38eab72 100644
--- a/sylius/resource-bundle/1.9/manifest.json
+++ b/sylius/resource-bundle/1.12/manifest.json
@@ -6,6 +6,7 @@
"Sylius\\Bundle\\ResourceBundle\\SyliusResourceBundle": ["all"]
},
"copy-from-recipe": {
- "config/": "%CONFIG_DIR%/"
+ "config/": "%CONFIG_DIR%/",
+ "src/": "%SRC_DIR%/"
}
}
diff --git a/sylius/resource-bundle/1.12/src/Entity/.gitignore b/sylius/resource-bundle/1.12/src/Entity/.gitignore
new file mode 100644
index 00000000..e69de29b 1.12 vs 1.13diff --git a/sylius/resource-bundle/1.12/config/routes/sylius_resource.yaml b/sylius/resource-bundle/1.13/config/routes/sylius_resource.yaml
index 0c8ade2c..6744c22b 100644
--- a/sylius/resource-bundle/1.12/config/routes/sylius_resource.yaml
+++ b/sylius/resource-bundle/1.13/config/routes/sylius_resource.yaml
@@ -1,7 +1,3 @@
-sylius_crud_routes:
- resource: 'sylius.routing.loader.crud_routes_attributes'
- type: service
-
-sylius_routes:
- resource: 'sylius.routing.loader.routes_attributes'
+sylius_resource_loader:
+ resource: 'sylius.symfony.routing.loader.resource'
type: service |
@@ -0,0 +1,15 @@ | |||
# @see https://github.com/Sylius/SyliusResourceBundle/blob/master/docs/index.md |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -0,0 +1,12 @@ | |||
{ | |||
"container": { | |||
"locale": "en" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checking just in case, is locale
necessary for resource standalone usage?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have removed that dependency on 1.14 branch. So we will be able to remove that when it will be stable