Skip to content

Commit

Permalink
Merge pull request #256 from akeneo/PIM-5376
Browse files Browse the repository at this point in the history
PIM-5376: Move config to standard
  • Loading branch information
grena committed Jan 26, 2016
2 parents 09d5839 + aaf1ffb commit 940962d
Show file tree
Hide file tree
Showing 7 changed files with 141 additions and 18 deletions.
97 changes: 97 additions & 0 deletions CHANGELOG-1.5.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
# 1.5.x

# 1.5.0-ALPHA1 (2016-01-26)

## Technical improvements

- PIM-4964: Use enable / disable import parameter only to create the product
- Family is not hardcoded anymore
- PIM-4743: Added the possibility to use optgroup in Oro ChoiceFilter
- PIM-4347: `Pim\Bundle\CatalogBundle\Repository\ProductRepositoryInterface` now extends `Doctrine\Common\Persistence\ObjectRepository`
- PIM-5067: Change the JUnit formatter of behats logs
- PIM-5217: Create a Buffer component and new file writer implementations that use it
- PIM-4646: TinyMCE wysiwyg editor is replaced by Summernote in the mass-edit and variant group
- PIM-4999: jQuery UI datepicker is replaced by bootstrap datepicker in the mass-edit and variant group
- A new twig extension (StyleExtension) in UIBundle now provides a "highlight" string filter
- PIM-5450: MongoDb ODM bundle in dev requirements
- PIM-5380: It is now possible to group grid actions in dropdown by specifying it in the grid configuration (see quick export in the product grid for an example)

## Bug fixes

## BC breaks
- Change constructor of `Pim\Bundle\EnrichBundle\Connector\Processor\QuickExport\ProductToFlatArrayProcessor` to add `Akeneo\Component\StorageUtils\Detacher\ObjectDetacherInterface` and `Pim\Component\Catalog\Builder\ProductBuilderInterface`.
- Service `oro_filter.form.type.date_range` is removed and replaced by `pim_filter.form.type.date_range`
- Service `oro_filter.form.type.datetime_range` is removed and replaced by `pim_filter.form.type.datetime_range`
- Delete class `Pim\Bundle\CatalogBundle\Manager\ProductMassActionManager` its service `pim_catalog.manager.product_mass_action`
- Change constructor of `Pim\Bundle\EnrichBundle\Form\Type\MassEditAction\EditCommonAttributesType` to keep only $dataclass
- Change constructor of `Pim\Bundle\EnrichBundle\MassEditAction\Operation\EditCommonAttributes`. Removed arguments `Pim\Bundle\CatalogBundle\Context\CatalogContext`, `Symfony\Component\Serializer\Normalizer\NormalizerInterface`, `Akeneo\Component\FileStorage\File\FileStorerInterface`, `Pim\Bundle\CatalogBundle\Manager\ProductMassActionManager`. Added arguments `Pim\Component\Localization\Localizer\LocalizerRegistry` and `Pim\Component\Localization\Localizer\LocalizedAttributeConverterInterface`.
- Service `oro_form.type.date` is removed and replaced by `pim_form.type.date` (alias `oro_date` is replaced by `pim_date`)
- Change constructor of `Pim\Bundle\CatalogBundle\Builder\ProductTemplateBuilder`. Add `Pim\Component\Localization\LocaleResolver` as the fourth argument.
- Change constructor of `Pim\Bundle\EnrichBundle\Controller\Rest\ProductController`. Add argument `Pim\Component\Localization\Localizer\LocalizedAttributeConverterInterface`.
- Change constructor of `Pim\Bundle\EnrichBundle\Form\Handler\GroupHandler`. Add argument `Pim\Component\Localization\Localizer\LocalizedAttributeConverterInterface`.
- Change constructor of `Pim\Bundle\EnrichBundle\Form\Subscriber\TransformProductTemplateValuesSubscriber`. Add argument `Pim\Component\Localization\LocaleResolver`.
- Change constructor of `Pim\Bundle\UIBundle\Form\Type\NumberType`. Add arguments `Pim\Component\Localization\LocaleResolver` and `Pim\Component\Localization\Localizer\LocalizerInterface`.
- Add `Pim\Component\Localization\Localizer\LocalizedAttributeConverter` to `Pim\Component\Connector\Processor\Denormalization\ProductProcessor`
- Add an array `$decimalSeparators` to `Pim\Component\Connector\Reader\File\CsvProductReader`
- Column 'comment' has been added on the `pim_notification_notification` table.
- Remove OroEntityBundle
- Remove OroEntityConfigBundle
- Remove PimEntityBundle
- Move DoctrineOrmMappingsPass from Oro/EntityBundle to Akeneo/StorageUtilsBundle
- Remove OroDistributionBundle (explicitely define oro bundles routing, means oro/rounting.yml are not automaticaly loaded anymore, and remove useless twig config)
- Change constructor of `Pim\Bundle\TranslationBundle\Twig\TranslationsExtension`. Replace `Oro\Bundle\LocaleBundle\Model\LocaleSettings` by `Symfony\Component\HttpFoundation\RequestStack`.
- Removed `Pim\Bundle\UserBundle\EventListener\LocalListener` (use `Pim\Bundle\UserBundle\EventListener\LocaleListener` instead).
- Change constructor of `Pim\Bundle\UserBundle\Form\Subscriber\UserPreferencesSubscriber`. Add `Pim\Component\Localization\Provider\LocaleProviderInterface` as the first argument.
- Move `LocaleType` from `Oro\Bundle\LocalBundle\Form\Type` to `Pim\Bundle\LocalizationBundle\Form\Type`
- Move `UserType` from `Oro\Bundle\UserBundle\Form\Type` to `Pim\Bundle\UserBundle\Form\Type`
- Added Pim\Bundle\CatalogBundle\Repository\AttributeRepositoryInterface to the constructor of Pim\Component\Catalog\Updater\Remover\RemoverRegistry, Pim\Component\Catalog\Updater\Adder\AdderRegistry, Pim\Component\Catalog\Updater\Setter\SetterRegistry and Pim\Component\Catalog\Updater\Copier\CopierRegistry
- Added Pim\Bundle\CatalogBundle\Repository\AttributeRequirementRepositoryInterface to the constructor of Pim\Component\Catalog\Updater\FamilyUpdater
- Change constructor of `Pim\Bundle\BaseConnectorBundle\Processor\CsvSerializer\Processor`. Removed argument `Pim\Bundle\CatalogBundle\Manager\LocaleManager` and add `Pim\Bundle\CatalogBundle\Repository\LocaleRepositoryInterface`
- Change constructor of `Pim\Bundle\BaseConnectorBundle\Processor\CsvSerializer\ProductProcessor`. Removed argument `Pim\Bundle\CatalogBundle\Manager\LocaleManager` and add `Pim\Bundle\CatalogBundle\Repository\LocaleRepositoryInterface`
- Change constructor of `Pim\Bundle\BaseConnectorBundle\Processor\CsvSerializer\HeterogeneousProcessor`. Removed argument `Pim\Bundle\CatalogBundle\Manager\LocaleManager` and add `Pim\Bundle\CatalogBundle\Repository\LocaleRepositoryInterface`
- Change constructor of `Pim\Bundle\BaseConnectorBundle\Processor\CsvSerializer\HomogeneousProcessor`. Removed argument `Pim\Bundle\CatalogBundle\Manager\LocaleManager` and add `Pim\Bundle\CatalogBundle\Repository\LocaleRepositoryInterface`
- Change constructor of `Pim\Bundle\BaseConnectorBundle\Processor\Normalization\FamilyProcessor`. Removed argument `Pim\Bundle\CatalogBundle\Manager\LocaleManager` and add `Pim\Bundle\CatalogBundle\Repository\LocaleRepositoryInterface`
- Change constructor of `Pim\Bundle\CatalogBundle\Helper\LocaleHelper`. Removed argument `Pim\Bundle\CatalogBundle\Manager\LocaleManager` and add `Pim\Bundle\CatalogBundle\Repository\LocaleRepositoryInterface`.
- Change constructor of `Pim\Bundle\EnrichBundle\Controller\AttributeController`. Removed argument `Pim\Bundle\CatalogBundle\Manager\LocaleManager` and add `Pim\Bundle\CatalogBundle\Repository\LocaleRepositoryInterface`.
- Change constructor of `Pim\Bundle\EnrichBundle\Form\Type\ChannelType`. Removed argument `Pim\Bundle\CatalogBundle\Manager\LocaleManager` and add `Pim\Bundle\CatalogBundle\Repository\LocaleRepositoryInterface`.
- Change constructor of `Pim\Bundle\EnrichBundle\Normalizer\AttributeOptionNormalizer`. Removed argument `Pim\Bundle\CatalogBundle\Manager\LocaleManager` and add `Pim\Bundle\CatalogBundle\Repository\LocaleRepositoryInterface`.
- Change constructor of `Pim\Bundle\EnrichBundle\Normalizer\ProductNormalizer`. Removed argument `Pim\Bundle\CatalogBundle\Manager\LocaleManager` and add `Pim\Bundle\CatalogBundle\Repository\LocaleRepositoryInterface`.
- Deleted class `Pim\Bundle\CatalogBundle\Manager\LocaleManager` we should now use the `Pim\Bundle\CatalogBundle\Repository\LocaleRepositoryInterface`.
- Change constructor of `Pim\Bundle\DataGridBundle\Extension\Formatter\Property\ProductValue\PriceProperty`. Add `Pim\Component\Localization\Presenter\PresenterInterface`.
- Change constructor of `Pim\Bundle\DataGridBundle\Extension\Formatter\Property\ProductValue\MetricProperty`. Add `Pim\Component\Localization\Presenter\PresenterInterface`.
- Change constructor of `Pim\Bundle\DataGridBundle\Extension\Formatter\Property\ProductValue\NumberProperty`. Add `Pim\Component\Localization\Presenter\PresenterInterface`.
- Change constructor of `Pim\Bundle\BaseConnectorBundle\Processor\ProductToFlatArrayProcessor`. Add `array` of available decimal separators and `array` of available date formats.
- Change constructor of `Pim\Component\Localization\Normalizer\ProductValueNormalizer`. Add `Pim\Component\Localization\Localizer\LocalizerRegistryInterface`.
- Change constructor of `Pim\Bundle\BaseConnectorBundle\Processor\Normalization\VariantGroupProcessor`. Add `array` of available decimal separators and `array` of available date formats as third and fourth parameter.
- Change constructor of `Pim\Bundle\EnrichBundle\Connector\Processor\QuickExport\ProductToFlatArrayProcessor`. Add `Pim\Component\Localization\Provider\DateFormatProviderInterface` as third parameter.
- Change constructor of `Pim\Bundle\CatalogBundle\Factory\FamilyFactory`. Add family classname as last parameter.
- Change constructor of `Pim\Bundle\EnrichBundle\Controller\FamilyController`. Add family classname as last parameter.
- Change `Pim\Bundle\EnrichBundle\Controller\FamilyController` methods parameters for `editAction`, `removeAction`, `historyAction` and `addAttributesAction` changing Family by integer (id).
- Change parameters of `renderStatefulGrid` of `Pim\Bundle\DataGridBundle\Resources\views\macros.html.twig` array `defaultView` has been added.
- Change constructor of `Pim\Bundle\DataGridBundle\Datagrid\Configuration\Product\ContextConfigurator`. Unused datagrid view repository has been removed.
- Change constructor of `Pim\Bundle\UserBundle\Form\Type\UserType`. Added EventDispatcher as last parameter.
- Remove class `Pim\Bundle\CatalogBundle\Manager\AssociationTypeManager`
- Remove class `Pim\Bundle\CatalogBundle\Manager\AssociationManager`
- Remove deprecated method valueExists from `Pim\Bundle\CatalogBundle\Manager\ProductManager`
- Change constructor of `Pim\Bundle\DataGridBundle\Extension\MassAction\Util\ProductFieldsBuilder` to inject ProductRepositoryInterface and AttributeRepositoryInterface
- Added method `getAttributeCodesByGroup` to the `Pim\Bundle\CatalogBundle\Repository\AttributeRepositoryInterface`
- Changed constructor of `Pim\Bundle\TransformBundle\Normalizer\Structured\AttributeGroupNormalizer`, made AttributeRepository mandatory
- Remove deprecated method scheduleForChannel from `Pim\Bundle\CatalogBundle\Manager\CompletenessManager`
- Move `Pim\Bundle\BaseConnectorBundle\Writer\File\ArchivableWriterInterface` to `Pim\Component\Connector\Writer\File\ArchivableWriterInterface`
- `Pim\Component\Connector\Writer\File\YamlWriter` now inherits from `Pim\Component\Connector\Writer\File\AbstractFileWriter` therefore needs an instance of `Pim\Component\Connector\Writer\File\FilePathResolverInterface` as first parameter of the constructor
- Remove deprecated methods findAllWithTranslations, getIdToLabelOrderedBySortOrder, getAttributeGroupChoices from `Pim\Bundle\CatalogBundle\Repository\AttributeRepositoryInterface`
- Remove deprecated methods findAllWithTranslations, getIdToLabelOrderedBySortOrder, getAttributeGroupChoices from `Pim\Bundle\CatalogBundle\Repository\AttributeGroupRepositoryInterface`
- Remove deprecated methods getAvailableAttributesAsLabelChoice, getAttributeIds from `Pim\Bundle\CatalogBundle\Repository\AttributeRepositoryInterface`
- Remove deprecated methods getAvailableAxis, getRepository, getGroupTypeRepository, getProductList, getAttributeRepository from `Pim\Bundle\CatalogBundle\Manager\GroupManager`
- Change constructor of `Pim\Bundle\CatalogBundle\Manager\GroupManager` to pass `Pim\Bundle\CatalogBundle\Repository\GroupTypeRepositoryInterface` and `Pim\Bundle\CatalogBundle\Repository\AttributeRepositoryInterface`
- Remove deprecated method getAttributeOptionValueClass from `Pim\Bundle\CatalogBundle\Manager\AttributeOptionManager`
- Remove deprecated methods getActiveCurrencies, getCurrencies from `Pim\Bundle\CatalogBundle\Manager\CurrencyManager`
- Change constructor of `Pim\Bundle\EnrichBundle\Controller\AttributeGroupController` to inject `Pim\Bundle\CatalogBundle\Repository\AttributeGroupRepositoryInterface` and `Pim\Bundle\CatalogBundle\Repository\AttributeRepositoryInterface`
- Change constructor of `Pim\Bundle\EnrichBundle\Controller\AttributeController` to inject `Pim\Bundle\CatalogBundle\Repository\GroupRepositoryInterface` and `Pim\Bundle\CatalogBundle\Repository\AttributeRepositoryInterface`
- Change constructor of `Pim\Bundle\EnrichBundle\MassEditAction\Operation\OperationRegistry` to inject `Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInterface` and `Oro\Bundle\SecurityBundle\SecurityFacade`
- Update schema of `Pim\Component\Catalog\Model\Metric`. Increase precision of data and baseData.
- Change constructor of `Pim\Component\Connector\Processor\Denormalization\ProductAssociationProcessor` to add `Akeneo\Component\StorageUtils\Detacher\ObjectDetacherInterface`
- Rename `Pim\Bundle\CatalogBundle\Validator\Constraints\Numeric` to `Pim\Bundle\CatalogBundle\Validator\Constraints\IsNumeric` to fix PHP7 compatibility
- Rename `Pim\Bundle\CatalogBundle\Validator\Constraints\NumericValidator` to `Pim\Bundle\CatalogBundle\Validator\Constraints\IsNumericValidator` to fix PHP7 compatibility
- Rename `Pim\Bundle\CatalogBundle\Validator\Constraints\String` to `Pim\Bundle\CatalogBundle\Validator\Constraints\IsString` to fix PHP7 compatibility
- Rename `Pim\Bundle\CatalogBundle\Validator\Constraints\StringValidator` to `Pim\Bundle\CatalogBundle\Validator\Constraints\IsStringValidator` to fix PHP7 compatibility
11 changes: 3 additions & 8 deletions app/AppKernel.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,6 @@ protected function getPimBundles()
new Pim\Bundle\FilterBundle\PimFilterBundle(),
new Pim\Bundle\UserBundle\PimUserBundle(),
new Pim\Bundle\JsFormValidationBundle\PimJsFormValidationBundle(),
new Pim\Bundle\EntityBundle\PimEntityBundle(),

// PIM bundles
new Pim\Bundle\AnalyticsBundle\PimAnalyticsBundle(),
Expand All @@ -80,7 +79,6 @@ protected function getPimBundles()
new Pim\Bundle\NotificationBundle\PimNotificationBundle(),
new Pim\Bundle\CatalogBundle\PimCatalogBundle(),
new Pim\Bundle\DataGridBundle\PimDataGridBundle(),
new Pim\Bundle\TranslationBundle\PimTranslationBundle(),
new Pim\Bundle\ImportExportBundle\PimImportExportBundle(),
new Pim\Bundle\VersioningBundle\PimVersioningBundle(),
new Pim\Bundle\WebServiceBundle\PimWebServiceBundle(),
Expand All @@ -91,6 +89,8 @@ protected function getPimBundles()
new Pim\Bundle\PdfGeneratorBundle\PimPdfGeneratorBundle(),
new Pim\Bundle\ReferenceDataBundle\PimReferenceDataBundle(),
new Pim\Bundle\ConnectorBundle\PimConnectorBundle(),
new Pim\Bundle\LocalizationBundle\PimLocalizationBundle(),
new Akeneo\Bundle\ClassificationBundle\AkeneoClassificationBundle(),
];
}

Expand All @@ -102,14 +102,13 @@ protected function getPimBundles()
protected function getPimDependenciesBundles()
{
return [
new Knp\Bundle\GaufretteBundle\KnpGaufretteBundle(),
new APY\JsFormValidationBundle\APYJsFormValidationBundle(),
new Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle(),
new Oneup\FlysystemBundle\OneupFlysystemBundle(),
new Akeneo\Bundle\MeasureBundle\AkeneoMeasureBundle(),
new Akeneo\Bundle\BatchBundle\AkeneoBatchBundle(),
new Akeneo\Bundle\BufferBundle\AkeneoBufferBundle(),
new Akeneo\Bundle\StorageUtilsBundle\AkeneoStorageUtilsBundle(),
new Akeneo\Bundle\ClassificationBundle\AkeneoClassificationBundle(),
new Akeneo\Bundle\FileStorageBundle\AkeneoFileStorageBundle(),
];
}
Expand Down Expand Up @@ -166,12 +165,8 @@ protected function getOroBundles()
new Oro\Bundle\AsseticBundle\OroAsseticBundle(),
new Oro\Bundle\ConfigBundle\OroConfigBundle(),
new Oro\Bundle\DataGridBundle\OroDataGridBundle(),
new Oro\Bundle\DistributionBundle\OroDistributionBundle(),
new Oro\Bundle\EntityBundle\OroEntityBundle(),
new Oro\Bundle\EntityConfigBundle\OroEntityConfigBundle(),
new Oro\Bundle\FilterBundle\OroFilterBundle(),
new Oro\Bundle\FormBundle\OroFormBundle(),
new Oro\Bundle\LocaleBundle\OroLocaleBundle(),
new Oro\Bundle\NavigationBundle\OroNavigationBundle(),
new Oro\Bundle\RequireJSBundle\OroRequireJSBundle(),
new Oro\Bundle\SecurityBundle\OroSecurityBundle(),
Expand Down
12 changes: 9 additions & 3 deletions app/SymfonyRequirements.php
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,7 @@ public function __construct()
is_dir(__DIR__.'/../vendor/composer'),
'Vendor libraries must be installed',
'Vendor libraries are missing. Install composer following instructions from <a href="http://getcomposer.org/">http://getcomposer.org/</a>. '.
'Then run "<strong>php composer.phar install</strong>" to install them.'
'Then run "<strong>php composer.phar install</strong>" to install them.'
);

$cacheDir = is_dir(__DIR__.'/../var/cache') ? __DIR__.'/../var/cache' : __DIR__.'/cache';
Expand Down Expand Up @@ -446,6 +446,12 @@ public function __construct()
);
}

$this->addRequirement(
function_exists('iconv'),
'iconv() must be available',
'Install and enable the <strong>iconv</strong> extension.'
);

$this->addRequirement(
function_exists('json_encode'),
'json_encode() must be available',
Expand Down Expand Up @@ -546,10 +552,10 @@ function_exists('simplexml_import_dom'),
require_once __DIR__.'/../vendor/autoload.php';

try {
$r = new \ReflectionClass('Sensio\Bundle\DistributionBundle\SensioDistributionBundle');
$r = new ReflectionClass('Sensio\Bundle\DistributionBundle\SensioDistributionBundle');

$contents = file_get_contents(dirname($r->getFileName()).'/Resources/skeleton/app/SymfonyRequirements.php');
} catch (\ReflectionException $e) {
} catch (ReflectionException $e) {
$contents = '';
}
$this->addRecommendation(
Expand Down
13 changes: 12 additions & 1 deletion app/config/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ doctrine:
password: "%database_password%"
charset: UTF8
types:
datetime: Oro\Bundle\LocaleBundle\DoctrineExtensions\DBAL\Types\UTCDateTimeType
datetime: Akeneo\Bundle\StorageUtilsBundle\Doctrine\DBAL\Types\UTCDateTimeType
orm:
auto_generate_proxy_classes: "%kernel.debug%"
auto_mapping: true
Expand All @@ -85,3 +85,14 @@ swiftmailer:
pim_reference_data: ~

akeneo_storage_utils: ~

pim_localization:
decimal_separators:
- { value: '.', label: 'dot (.)' }
- { value: ',', label: 'comma (,)' }
date_formats:
- { value: 'yyyy-MM-dd', label: 'yyyy-mm-dd' }
- { value: 'yyyy/MM/dd', label: 'yyyy/mm/dd' }
- { value: 'MM/dd/yyyy', label: 'mm/dd/yyyy' }
- { value: 'dd/MM/yyyy', label: 'dd/mm/yyyy' }
- { value: 'dd.MM.yyyy', label: 'dd.mm.yyyy' }
4 changes: 2 additions & 2 deletions app/config/config_prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ monolog:
handlers:
main:
type: fingers_crossed
action_level: critical
action_level: warning
handler: nested
nested:
type: stream
path: %kernel.logs_dir%/%kernel.environment%.log
level: debug
level: info
console:
type: console

Expand Down
Loading

0 comments on commit 940962d

Please sign in to comment.