diff --git a/Admin/AbstractAdmin.php b/Admin/AbstractAdmin.php index e3701a8847..1ec7d4b7dc 100644 --- a/Admin/AbstractAdmin.php +++ b/Admin/AbstractAdmin.php @@ -1645,7 +1645,7 @@ public function setSubject($subject) $message = <<<'EOT' You are trying to set entity an instance of "%s", which is not the one registered with this admin class ("%s"). -This is deprecated since 3.x and will no longer be supported in 4.0. +This is deprecated since 3.5 and will no longer be supported in 4.0. EOT; trigger_error( diff --git a/CHANGELOG.md b/CHANGELOG.md index 29e57a61cd..16efe28512 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,54 @@ All notable changes to this project will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/). +## [3.5.0](https://github.com/sonata-project/SonataAdminBundle/compare/3.4.0...3.5.0) - 2016-08-29 +### Added +- Export fields names are now translated +- Added PL translations +- Configuration to change the default route used to generate the link to the parent object inside a breadcrumb, when in a child admin +- Docs for this configuration +- Twig blocks to simplify the template override. +- Added test for `AdminBundle\Menu\Matcher\Voter\ChildrenVoter` +- Added class name support for `AbstractAdmin::configureDatagridFilters` +- Added `ShowMapper::removeGroup` method + +### Changed +- Changed css `margin-left: -20px` of checkbox. +- Updated spanish batch confirmation message translation. +- Changed injection of `$container` to `$adminPool` in `Twig/GlobalVariables` +- use `RuntimeException` instead of non existing `RunTimeException` +- `AbstractAdmin::setSubject` in order to check that given `$subject` matches registered admin class entity. +- Added the action name to title_batch_confirmation translation. +- Added the object name to message_delete_confirmation translation. +- Added the action name to title_batch_confirmation translation. +- Move actions buttons display logic from templates to `AbstractAdmin::configureActionButtons` +- Moved translation of breadcrumbs to twig template +- Moved translation of batch action_label to twig template +- Move actions buttons display logic from templates to `AbstractAdmin::configureActionButtons` +- Widget tests should extend `AbstractWidgetTestCase` + +### Deprecated +- The `$container` property in `Twig/GlobalVariables` + +### Fixed +- The "batch" checkbox at the top of the list would not work when iCheck is disabled. +- Not working `read_only` option on Twig with Symfony 3 +- Fixed PT-BR translations +- XSS Vulnerability in breadcrumbs +- Handle Symfony BC for Datagrid hidden types +- Fixed duplicate translation for list filters +- Fixed visibility of block `sonata_top_nav_menu` contents +- Fix how metadata information are retrieved when admin information are dumped +- Symfony 3 support in `AclMatrixType` +- Symfony 3 type support in `AclMatrixType` +- Fixed translation in browser titles breadcrumb +- Fixed translation of entities in breadcrumb +- Standardize the global form error + +### Removed +- Internal test classes are now excluded from the autoloader +- Removed unnecessary security checks in `standard_layout.html.twig` + ## [3.4.0](https://github.com/sonata-project/SonataAdminBundle/compare/3.3.2...3.4.0) - 2016-07-05 ### Added - Support for select2 v4 (`select2.full.js` file is needed) diff --git a/Form/Type/Filter/ChoiceType.php b/Form/Type/Filter/ChoiceType.php index 5134569c94..473cc3d42b 100644 --- a/Form/Type/Filter/ChoiceType.php +++ b/Form/Type/Filter/ChoiceType.php @@ -31,7 +31,7 @@ class ChoiceType extends AbstractType const TYPE_EQUAL = 3; /** - * @deprecated since 3.x, to be removed with 4.0 + * @deprecated since 3.5, to be removed with 4.0 * * @var TranslatorInterface */ diff --git a/Form/Type/Filter/DateRangeType.php b/Form/Type/Filter/DateRangeType.php index 3a7dba1c4c..d6fa81f9c8 100644 --- a/Form/Type/Filter/DateRangeType.php +++ b/Form/Type/Filter/DateRangeType.php @@ -28,7 +28,7 @@ class DateRangeType extends AbstractType const TYPE_NOT_BETWEEN = 2; /** - * @deprecated since 3.x, to be removed with 4.0 + * @deprecated since 3.5, to be removed with 4.0 * * @var TranslatorInterface */ diff --git a/Form/Type/Filter/DateTimeRangeType.php b/Form/Type/Filter/DateTimeRangeType.php index f770dbe8f5..2affdb313d 100644 --- a/Form/Type/Filter/DateTimeRangeType.php +++ b/Form/Type/Filter/DateTimeRangeType.php @@ -28,7 +28,7 @@ class DateTimeRangeType extends AbstractType const TYPE_NOT_BETWEEN = 2; /** - * @deprecated since 3.x, to be removed with 4.0 + * @deprecated since 3.5, to be removed with 4.0 * * @var TranslatorInterface */ diff --git a/Form/Type/Filter/DateTimeType.php b/Form/Type/Filter/DateTimeType.php index 6017dbc241..5a7a226c44 100644 --- a/Form/Type/Filter/DateTimeType.php +++ b/Form/Type/Filter/DateTimeType.php @@ -39,7 +39,7 @@ class DateTimeType extends AbstractType const TYPE_NOT_NULL = 7; /** - * @deprecated since 3.x, to be removed with 4.0 + * @deprecated since 3.5, to be removed with 4.0 * * @var TranslatorInterface */ diff --git a/Form/Type/Filter/DateType.php b/Form/Type/Filter/DateType.php index f52eace497..65a9598f1b 100644 --- a/Form/Type/Filter/DateType.php +++ b/Form/Type/Filter/DateType.php @@ -39,7 +39,7 @@ class DateType extends AbstractType const TYPE_NOT_NULL = 7; /** - * @deprecated since 3.x, to be removed with 4.0 + * @deprecated since 3.5, to be removed with 4.0 * * @var TranslatorInterface */ diff --git a/Form/Type/Filter/NumberType.php b/Form/Type/Filter/NumberType.php index ed735e1264..6800c7eb75 100644 --- a/Form/Type/Filter/NumberType.php +++ b/Form/Type/Filter/NumberType.php @@ -35,7 +35,7 @@ class NumberType extends AbstractType const TYPE_LESS_THAN = 5; /** - * @deprecated since 3.x, to be removed with 4.0 + * @deprecated since 3.5, to be removed with 4.0 * * @var TranslatorInterface */ diff --git a/Form/Type/ModelTypeList.php b/Form/Type/ModelTypeList.php index 90ca4b2aa1..4cc7028b68 100644 --- a/Form/Type/ModelTypeList.php +++ b/Form/Type/ModelTypeList.php @@ -12,7 +12,7 @@ namespace Sonata\AdminBundle\Form\Type; @trigger_error( - 'The '.__NAMESPACE__.'\ModelTypeList class is deprecated since version 3.x and will be removed in 4.0.' + 'The '.__NAMESPACE__.'\ModelTypeList class is deprecated since version 3.5 and will be removed in 4.0.' .' Use '.__NAMESPACE__.'\ModelListType instead.', E_USER_DEPRECATED ); @@ -23,7 +23,7 @@ * - a list modal to select the targeted entities * - a clear selection link. * - * @deprecated since version 3.x, to be removed in 4.0. Use ModelListType instead + * @deprecated since version 3.5, to be removed in 4.0. Use ModelListType instead */ class ModelTypeList extends ModelListType { diff --git a/Twig/GlobalVariables.php b/Twig/GlobalVariables.php index 1c654956bf..29616b9965 100644 --- a/Twig/GlobalVariables.php +++ b/Twig/GlobalVariables.php @@ -22,7 +22,7 @@ class GlobalVariables /** * @var ContainerInterface * - * @deprecated Since version 3.x, will be removed in 4.0. + * @deprecated Since version 3.5, will be removed in 4.0. * NEXT_MAJOR : remove this property */ protected $container; @@ -41,7 +41,7 @@ public function __construct($adminPool) if ($adminPool instanceof ContainerInterface) { @trigger_error( 'Using an instance of Symfony\Component\DependencyInjection\ContainerInterface is deprecated since - version 3.x and will be removed in 4.0. Use Sonata\AdminBundle\Admin\Pool instead.', + version 3.5 and will be removed in 4.0. Use Sonata\AdminBundle\Admin\Pool instead.', E_USER_DEPRECATED ); diff --git a/UPGRADE-3.x.md b/UPGRADE-3.x.md index 41ad65f384..c325b05b4d 100644 --- a/UPGRADE-3.x.md +++ b/UPGRADE-3.x.md @@ -1,6 +1,9 @@ UPGRADE 3.x =========== +UPGRADE FROM 3.4 to 3.5 +======================= + ## Deprecated injection of container to GlobalVariables The `$container` property in `Twig/GlobalVariables` is deprecated.