Skip to content

Commit

Permalink
Merge pull request #14 from Peteck/sylius-v1.3
Browse files Browse the repository at this point in the history
Upgrade to Sylius v1.3
  • Loading branch information
loevgaard authored Nov 5, 2018
2 parents 563c225 + 905f8ed commit 0359785
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 21 deletions.
27 changes: 8 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,48 +25,37 @@ This command requires you to have Composer installed globally, as explained in t
### Step 2: Enable the plugin

Then, enable the plugin by adding it to the list of registered plugins/bundles
in the `app/AppKernel.php` file of your project:
in `config/bundles.php` file of your project:

```php
<?php
// app/AppKernel.php

use Sylius\Bundle\CoreBundle\Application\Kernel;

final class AppKernel extends Kernel
{
public function registerBundles(): array
{
return array_merge(parent::registerBundles(), [
// ...
new \Loevgaard\SyliusBrandPlugin\LoevgaardSyliusBrandPlugin(),
// ...
]);
}

return [
// ...
Loevgaard\SyliusBrandPlugin\LoevgaardSyliusBrandPlugin::class => ['all' => true],
// ...
}
```

### Step 3: Configure the plugin

```yaml
# app/config/config.yml
# config/services.yml

imports:
# ...
- { resource: "@LoevgaardSyliusBrandPlugin/Resources/config/config.yml" }
```
```yaml
# app/config/routing.yml
# config/routing.yml

loevgaard_sylius_brand:
resource: "@LoevgaardSyliusBrandPlugin/Resources/config/routing.yml"
```
```yaml
# src/AppBundle/Resources/config/doctrine/Product.orm.yml
# config/doctrine/Product.orm.yml

AppBundle\Entity\Product:
type: entity
Expand All @@ -83,7 +72,7 @@ AppBundle\Entity\Product:
```php
<?php
// src/AppBundle/Entity/Product.php
// src/Entity/Product.php

declare(strict_types=1);

Expand Down
3 changes: 1 addition & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@
"license": "MIT",
"require": {
"php": "^7.1",
"sylius/sylius": "~1.2.0",
"symfony/symfony": "^3.4|^4.1"
"sylius/sylius": "~1.3.0"
},
"require-dev": {
"behat/behat": "^3.4",
Expand Down

0 comments on commit 0359785

Please sign in to comment.