Skip to content
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

Oro/5.0.0 rc2 #21

Open
wants to merge 15 commits into
base: feature/update-5.0
Choose a base branch
from
Prev Previous commit
Next Next commit
AKM-33: OroCommerce 5 LTS compatibility
dxops committed Mar 8, 2022
commit a411656b3a4e55c06956305134b6fba96aec53c3
6 changes: 3 additions & 3 deletions Client/AkeneoClientFactory.php
Original file line number Diff line number Diff line change
@@ -2,8 +2,8 @@

namespace Oro\Bundle\AkeneoBundle\Client;

use Akeneo\Pim\ApiClient\AkeneoPimClientBuilder;
use Akeneo\Pim\ApiClient\AkeneoPimClientInterface;
use Akeneo\PimEnterprise\ApiClient\AkeneoPimEnterpriseClientBuilder;
use Oro\Bundle\AkeneoBundle\Encoder\Crypter;
use Oro\Bundle\AkeneoBundle\Entity\AkeneoSettings;
use Oro\Bundle\EntityBundle\ORM\DoctrineHelper;
@@ -117,9 +117,9 @@ private function createClientByToken(): AkeneoPimClientInterface
return $this->client;
}

private function getClientBuilder(): AkeneoPimEnterpriseClientBuilder
private function getClientBuilder(): AkeneoPimClientBuilder
{
$clientBuilder = new AkeneoPimEnterpriseClientBuilder($this->akeneoUrl);
$clientBuilder = new AkeneoPimClientBuilder($this->akeneoUrl);
$clientBuilder->setHttpClient($this->httpClient);
$clientBuilder->setRequestFactory($this->requestFactory);
$clientBuilder->setStreamFactory($this->streamFactory);
28 changes: 28 additions & 0 deletions EntityConfig/ImportexportFieldConfiguration.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<?php

namespace Oro\Bundle\AkeneoBundle\EntityConfig;

use Oro\Bundle\EntityConfigBundle\EntityConfig\FieldConfigInterface;
use Symfony\Component\Config\Definition\Builder\NodeBuilder;

/**
* Provides validations field config for importexport scope.
*/
class ImportexportFieldConfiguration implements FieldConfigInterface
{
public function getSectionName(): string
{
return 'importexport';
}

public function configure(NodeBuilder $nodeBuilder): void
{
$nodeBuilder
->scalarNode('source')
->info('`string` source of field.')
->end()
->scalarNode('source_name')
->info('`string` source name of field.')
->end();
}
}
1 change: 0 additions & 1 deletion Migrations/Schema/OroAkeneoBundleInstaller.php
Original file line number Diff line number Diff line change
@@ -21,7 +21,6 @@ class OroAkeneoBundleInstaller implements Installation, ExtendExtensionAwareInte
*/
protected $options = [
'extend' => [
'origin' => ExtendScope::OWNER_CUSTOM,
'owner' => ExtendScope::OWNER_CUSTOM,
'state' => ExtendScope::STATE_NEW,
'is_serialized' => false,
1 change: 0 additions & 1 deletion Migrations/Schema/v1_12/OroAkeneoMigration.php
Original file line number Diff line number Diff line change
@@ -43,7 +43,6 @@ public function up(Schema $schema, QueryBag $queries)
'notnull' => false,
'oro_options' => [
'extend' => [
'origin' => ExtendScope::OWNER_CUSTOM,
'owner' => ExtendScope::OWNER_CUSTOM,
'state' => ExtendScope::STATE_NEW,
'is_serialized' => false,
20 changes: 8 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
@@ -16,13 +16,13 @@ With this extension, you will be able to sync the following data from Akeneo to

## Compatibility

| Connector | Status | OroCommerce | Akeneo | Build |
|-----------|--------|-------------|----------------|-------|
| 1.6 | EOL | 1.6 | 2.3, 3.2, 4.0* | |
| 3.1 | EOL | 3.1 | 2.3, 3.2, 4.0* | |
| 4.1 | 2021 | 4.1 | 2.3, 3.2, 4.0* | [![Build Status](https://travis-ci.org/oroinc/OroAkeneoBundle.svg?branch=4.1)](https://travis-ci.org/oroinc/OroAkeneoBundle) |
| 4.2 | 2022 | 4.2 | 3.2, 4.0, 5.0 | [![Build Status](https://travis-ci.org/oroinc/OroAkeneoBundle.svg?branch=4.2)](https://travis-ci.org/oroinc/OroAkeneoBundle) |
| 5.0 | WIP | 5.0 | 4.0, 5.0 | |
| Connector | Status | OroCommerce | Akeneo |
|-----------|--------|-------------|----------------|
| 1.6 | EOL | 1.6 | 2.3, 3.2, 4.0* |
| 3.1 | EOL | 3.1 | 2.3, 3.2, 4.0* |
| 4.1 | EOL | 4.1 | 2.3, 3.2, 4.0* |
| 4.2 | 2022 | 4.2 | 3.2, 4.0, 5.0 |
| 5.0 | 2023 | 5.0 | 5.0+ |

** Akeneo supported using older client versions, new features are not available.**

@@ -31,11 +31,7 @@ With this extension, you will be able to sync the following data from Akeneo to
1. Add composer package

```
# Akeneo 4.0
composer require "oro/commerce-akeneo:4.2.*" "akeneo/api-php-client-ee:5.*"
# Akeneo 5.0
composer require "oro/commerce-akeneo:4.2.*" "akeneo/api-php-client-ee:6.*"
composer require "oro/commerce-akeneo:5.0.*"
```

2. Follow [Setup Guide](https://doc.oroinc.com/backend/setup/upgrade-to-new-version)
3 changes: 2 additions & 1 deletion Resources/config/importexport.yml
Original file line number Diff line number Diff line change
@@ -319,7 +319,8 @@ services:
- [ setCacheProvider, [ '@oro_akeneo.importexport.cache' ] ]

oro_akeneo.importexport.cache:
class: Doctrine\Common\Cache\ArrayCache
parent: oro_cache.array_cache
public: false
calls:
- [ setNamespace, [ 'oro_akeneo' ] ]

5 changes: 5 additions & 0 deletions Resources/config/services.yml
Original file line number Diff line number Diff line change
@@ -400,3 +400,8 @@ services:
class: 'Oro\Bundle\AkeneoBundle\EventListener\DeletedAttributeRelationListener'
decorates: oro_serialized_fields.event_listener.deleted_attribute_relation_serialized
parent: oro_serialized_fields.event_listener.deleted_attribute_relation_serialized

oro_akeneo.entity_config.importexport_field_configuration:
class: Oro\Bundle\AkeneoBundle\EntityConfig\ImportexportFieldConfiguration
tags:
- oro_entity_config.validation.entity_config
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -19,6 +19,6 @@
},
"require": {
"oro/commerce": "5.0.*",
"akeneo/api-php-client-ee": "5.* || 6.*"
"akeneo/api-php-client": "8.*"
}
}