I'm trying to integrate Sylius Product Bundle into my existing Symfony project. It already has doctrine configured.
This is the error I am getting:
[Symfony\Component\Config\Definition\Exception\InvalidConfigurationException]
The child node "driver" at path "sylius_attribute" must be configured.
Any idea what's causing this? I followed the instruction right off the bat without doing any other installations of sylius.
http://docs.sylius.org/en/latest/bundles/SyliusProductBundle/installation.html
I had to change the doctrine-bundle version in my composer.json file to allow the
composer require "sylius/product-bundle"
to run successfully without errors. I changed the version from 1.2.* to
"doctrine/doctrine-bundle": "1.3.*"
Also after composer installed these guys, i added the following to my config.yml file
sylius_product:
driver: doctrine/orm
classes:
product:
model: Sylius\Bundle\CoreBundle\Model\Product
controller: Sylius\Bundle\CoreBundle\Controller\ProductController
repository: Sylius\Bundle\CoreBundle\Repository\ProductRepository
stof_doctrine_extensions:
default_locale: es_us
translation_fallback: true
orm:
default:
tree: true
Initially I was getting the following error:
[Exception]
Missing parameter sylius.translation.default.mapping. Default translation mapping must be defined!
After a little searching around I added the piece below to the config.yml file
sylius_translation:
default_mapping:
translatable:
field: translations
currentLocale: currentLocale
fallbackLocale: fallbackLocale
translation:
field: translatable
locale: locale
Already existing earlier in my config.yml file was:
doctrine:
dbal:
driver: "%database_driver%"
host: "%database_host%"
port: "%database_port%"
dbname: "%database_name%"
user: "%database_user%"
password: "%database_password%"
charset: UTF8
orm:
auto_generate_proxy_classes: "%kernel.debug%"
auto_mapping: true
I didn't change anything in these settings.
What am i doing wrong here or missing? ANy help will be greatly appreciated.
Thanks!
EDIT
I tried adding all the below items:
sylius_attribute:
driver: doctrine/orm
sylius_variation:
driver: doctrine/orm
sylius_archetype:
driver: doctrine/orm
Now I get the following error:
[InvalidArgumentException]
The class sylius.model.product_archetype.class does not exist.
I added the corresponding file to the AppKernel with still no luck!
new Sylius\Bundle\AttributeBundle\SyliusArchetypeBundle(),
and then changed it to:
new Sylius\Bundle\ArchetypeBundle\SyliusArchetypeBundle(),
Setting up Sylius has been quiet stressful so far :(