From ee92cfa7ba618bf4acc19ab540eaa674b828a092 Mon Sep 17 00:00:00 2001 From: Carsten Brandt Date: Mon, 11 Jul 2016 15:36:42 +0200 Subject: [PATCH] release version 2.0.9 --- framework/BaseYii.php | 2 +- framework/CHANGELOG.md | 76 ++++++++++++------------ framework/classes.php | 2 + framework/console/Application.php | 4 ++ framework/db/ColumnSchemaBuilder.php | 3 +- framework/db/pgsql/Schema.php | 3 + framework/grid/CheckboxColumn.php | 1 + framework/rbac/CheckAccessInterface.php | 6 ++ framework/validators/UniqueValidator.php | 2 +- framework/web/Application.php | 3 + 10 files changed, 61 insertions(+), 41 deletions(-) diff --git a/framework/BaseYii.php b/framework/BaseYii.php index 0f995970d89..b5d29920006 100644 --- a/framework/BaseYii.php +++ b/framework/BaseYii.php @@ -93,7 +93,7 @@ class BaseYii */ public static function getVersion() { - return '2.0.9-dev'; + return '2.0.9'; } /** diff --git a/framework/CHANGELOG.md b/framework/CHANGELOG.md index eb54dd41b2f..27c88842bd4 100644 --- a/framework/CHANGELOG.md +++ b/framework/CHANGELOG.md @@ -2,65 +2,65 @@ Yii Framework 2 Change Log ========================== -2.0.9 under development ------------------------ +2.0.9 July 11, 2016 +------------------- -- Bug #11896: Fix for DROP TRIGGER in migrations from RBAC. (barradas-alberto) -- Enh #11725: Added indexes on message tables (OndrejVasicek) -- Enh #10422: Added `null` method on `yii\db\ColumnSchemaBuilder` to explicitly set column nullability (nevermnd) -- Enh #9574: Implicit run `ColumnSchemaBuilder::null()` when default value is set to `null`. (rob006) -- Enh #8795: Refactored `yii\web\User::loginByCookie()` in order to make it easier to override (maine-mike, silverfire) -- Enh #9948: `yii\rbac\PhpManager` now invalidates script file cache performed by 'OPCache' or 'APC' on file saving (klimov-paul) -- Enh #11195: Added ability to append custom string to schema builder column definition (df2, samdark) -- Enh #11490: Added `yii\data\ArrayDataProvider::$modelClass` property to specify a model used to provide column labels even when data array is empty (PowerGamer1) -- Enh #11591: Added support for wildcards for `only` and `except` at `yii\base\ActionFilter` (klimov-paul) +- Bug #6347: `inverseOf()` not working for dynamic relational queries (laszlovl) +- Bug #8644: Fixed trying to ENABLE/DISABLE TRIGGER ALL on a view in PostgreSQL (ricpelo) - Bug #9950: Updated `yii\grid\DataColumn::getHeaderCellLabel()` to extract attribute label from the `filterModel` of Grid (silverfire) +- Bug #10613: Fixed PostgreSQL Schema to return correct column names for unique indexes that have mixed case column names (cebe) +- Bug #10681: Fixed active form `beforeValidate` wasn't triggered in some cases (lynicidn) +- Bug #11252: Use strict comparison on ActiveRecord::hasAttribute() to avoid cases where it returns true when a number is passed to it (Faryshta) +- Bug #11322: Fixed incorrect error message in `yii\validators\UniqueValidator` for composite `targetAttribute` (PowerGamer1, silverfire, cebe) - Bug #11429: Fixed `yii\i18n\PhpMessageSource::loadFallbackMessages()` not to log error when source and language is same, but locales are different (silverfire) -- Enh #11484: Speed up `yii\db\oci\Schema::loadTableSchema()` for Oracle DBMS (SSiwek) -- Enh #11428: Speedup SQL query in `yii\db\oci\Schema::findColumns()` (SSiwek) -- Enh #11414: Files specified as `null` in `yii\web\AssetBundle` won't be registered (Razzwan) -- Enh #11432: Added HTTP status 421 "Misdirected Request" to list of statuses in `yii\web\Response` (dasmfm) -- Enh #11438: Configurable `yii\helpers\Markdown` default flavor (mdmunir) -- Enh #11729: Added `yii\grid\CheckboxColumn::$cssClass` property to specify a class added to checkbox input (thiagotalma) - Bug #11459: Fixed flash messages not destroyed when `session.auto_start = 1` set in php.ini (cartmanchen) -- Enh #11462: Added support of filtering rules to `yii\log\Target::$logVar` (HaruAtari) -- Enh #11462: Added `\yii\helpers\BaseArrayHelper::filter()` method (HaruAtari) - Bug #11498: Fixed inability to save serialized object into PostgreSQL binary column (klimov-paul) - Bug #11507: Fixed `yii\validators\EachValidator::validateAttribute()` does not respect `skipOnEmpty` rule parameter (webdevsega) - Bug #11523: Fixed `yii\web\User::checkRedirectAcceptable()` to treat acceptable content type `*/*` as `*` (silverfire) +- Bug #11527: Fixed `bigPrimaryKey()` for SQLite (dynasource) +- Bug #11528: Fixed MessageFormatter construction exception caught for PHP 7 compatibility (subdee, cebe) - Bug #11532: Fixed casting of empty char value to `null` resulting in integrity constraint violation for not null columns (samdark) +- Bug #11536: Fixed regression introduced in 2.0.8, where scalar value was not allowed in QueryBuilder `IN` condition anymore (cebe) +- Bug #11549: Fixed `ArrayHelper::getValue()` to work properly with float keys (zsounder, AnikanovD) +- Bug #11561: Fixed DI container throwing exceptions for optional dependencies (SamMousa) - Bug #11571: Fixed `yii\db\ColumnSchemaBuilder` to work with custom column types (andrey-mokhov, silverfire) - Bug #11662: Fixed `schema-oci.sql` for RBAC (jonny7) -- Bug #11527: Fixed `bigPrimaryKey()` for SQLite (dynasource) +- Bug #11672: Fixed `yii\validators\NumberValidator` erroring when value is an object without `__toString()` method (SamMousa) - Bug #11686: `BaseArrayHelper::isIn()` comparison did not work in strict mode (taobig) -- Enh #11679: Extracted `CheckAccessInterface` from `ManagerInterface` (SamMousa, samdark, mdomba) +- Bug #11693: Handle `QueryBuilder::batchInsert()` calls with no data to insert (rob006) - Bug #11723: Fixed PHP 7 + XDebug error handling displaying "Expected array for frame 0" (tanakahisateru) - Bug #11735: Fixed `yii\web\UploadedFile` to return `null` when there's no file uploaded (brummm) -- Bug #11774: Fixed incorrect recusuive symlinks check in FileHelper (AnikanovD) - Bug #11739: Fixed `ArrayHelper::index()` losing precision for float keys (AnikanovD) -- Bug #11549: Fixed `ArrayHelper::getValue()` to work properly with float keys (zsounder, AnikanovD) -- Bug #8644: Fixed trying to ENABLE/DISABLE TRIGGER ALL on a view in PostgreSQL (ricpelo) -- Bug #11536: Fixed regression introduced in 2.0.8, where scalar value was not allowed in QueryBuilder `IN` condition anymore (cebe) -- Bug #11693: Handle `QueryBuilder::batchInsert()` calls with no data to insert (rob006) -- Bug #11672: Fixed `yii\validators\NumberValidator` erroring when value is an object without `__toString()` method (SamMousa) -- Bug #11561: Fixed DI container throwing exceptions for optional dependencies (SamMousa) -- Enh #11168: `yii\helpers\BaseHtml` now uses abstracted `booleanInput()` and `activeBooleanInput()` methods to render `radio()`, `checkbox()`, `activeRadio()` and `activeCheckbox()` (cesarnicola) -- Enh #11808: `_table` and `_column` suffixes are now required when generating migration (rob006) +- Bug #11774: Fixed incorrect recusuive symlinks check in FileHelper (AnikanovD) - Bug #11822: Fixed exception on non-string value provided as CSRF token (cebe) -- Enh #11850: Introduced `yii\widgets\Pjax::$submitEvent` to be able to customize event triggering PJAX form submit (Bvanleeuwen) - Bug #11847: Fixed `yii\widgets\Pjax` to properly respond with partials when custom selector is used for container (pigochu, samdark) -- Bug #10681: Fixed active form `beforeValidate` wasn't triggered in some cases (lynicidn) -- Enh #11857: `yii\filters\AccessRule::$verbs` can now be configured in upper and lowercase (DrDeath72, samdark) - Bug #11863: Fixed usage of `mb_substr` with PHP < 5.4.8 where length of NULL was treated the same as 0 (samdark) - Bug #11865: Fixed setting `selected` for dropdown list using options (samdark) -- Bug #11528: Fixed MessageFormatter construction exception caught for PHP 7 compatibility (subdee, cebe) - Bug #11878: Fixed i18n gettext fallback language message loading (stevekr) +- Bug #11896: Fix for DROP TRIGGER in migrations from RBAC. (barradas-alberto) +- Enh #8795: Refactored `yii\web\User::loginByCookie()` in order to make it easier to override (maine-mike, silverfire) +- Enh #9574: Implicit run `ColumnSchemaBuilder::null()` when default value is set to `null`. (rob006) +- Enh #9948: `yii\rbac\PhpManager` now invalidates script file cache performed by 'OPCache' or 'APC' on file saving (klimov-paul) +- Enh #10422: Added `null` method on `yii\db\ColumnSchemaBuilder` to explicitly set column nullability (nevermnd) +- Enh #11168: `yii\helpers\BaseHtml` now uses abstracted `booleanInput()` and `activeBooleanInput()` methods to render `radio()`, `checkbox()`, `activeRadio()` and `activeCheckbox()` (cesarnicola) +- Enh #11195: Added ability to append custom string to schema builder column definition (df2, samdark) - Enh #11212: Added headers to PO file in `yii\i18n\GettextPoFile::save()` (stevekr) -- Bug #6347: `inverseOf()` not working for dynamic relational queries (laszlovl) -- Bug #10613: Fixed PostgreSQL Schema to return correct column names for unique indexes that have mixed case column names (cebe) -- Bug #11322: Fixed incorrect error message in `yii\validators\UniqueValidator` for composite `targetAttribute` (PowerGamer1, silverfire, cebe) +- Enh #11414: Files specified as `null` in `yii\web\AssetBundle` won't be registered (Razzwan) +- Enh #11428: Speedup SQL query in `yii\db\oci\Schema::findColumns()` (SSiwek) +- Enh #11432: Added HTTP status 421 "Misdirected Request" to list of statuses in `yii\web\Response` (dasmfm) +- Enh #11438: Configurable `yii\helpers\Markdown` default flavor (mdmunir) +- Enh #11462: Added support of filtering rules to `yii\log\Target::$logVar` (HaruAtari) +- Enh #11462: Added `\yii\helpers\BaseArrayHelper::filter()` method (HaruAtari) +- Enh #11484: Speed up `yii\db\oci\Schema::loadTableSchema()` for Oracle DBMS (SSiwek) +- Enh #11490: Added `yii\data\ArrayDataProvider::$modelClass` property to specify a model used to provide column labels even when data array is empty (PowerGamer1) +- Enh #11591: Added support for wildcards for `only` and `except` at `yii\base\ActionFilter` (klimov-paul) +- Enh #11679: Extracted `CheckAccessInterface` from `ManagerInterface` (SamMousa, samdark, mdomba) +- Enh #11725: Added indexes on message tables (OndrejVasicek) +- Enh #11729: Added `yii\grid\CheckboxColumn::$cssClass` property to specify a class added to checkbox input (thiagotalma) +- Enh #11808: `_table` and `_column` suffixes are now required when generating migration (rob006) +- Enh #11850: Introduced `yii\widgets\Pjax::$submitEvent` to be able to customize event triggering PJAX form submit (Bvanleeuwen) +- Enh #11857: `yii\filters\AccessRule::$verbs` can now be configured in upper and lowercase (DrDeath72, samdark) - Chg #11364: Updated jQuery dependency to include versions `1.12.*` (cebe) -- Bug #11252: Use strict comparison on ActiveRecord::hasAttribute() to avoid cases where it returns true when a number is passed to it (Faryshta) - Chg #11683: Fixed fixture command to work with short syntax. `yii fixture "*, -User"` should be used instead of `yii fixture "*" -User` (Faryshta, samdark) diff --git a/framework/classes.php b/framework/classes.php index af49488447b..40f6f9c9278 100644 --- a/framework/classes.php +++ b/framework/classes.php @@ -134,6 +134,7 @@ 'yii\db\sqlite\Schema' => YII2_PATH . '/db/sqlite/Schema.php', 'yii\di\Container' => YII2_PATH . '/di/Container.php', 'yii\di\Instance' => YII2_PATH . '/di/Instance.php', + 'yii\di\NotInstantiableException' => YII2_PATH . '/di/NotInstantiableException.php', 'yii\di\ServiceLocator' => YII2_PATH . '/di/ServiceLocator.php', 'yii\filters\AccessControl' => YII2_PATH . '/filters/AccessControl.php', 'yii\filters\AccessRule' => YII2_PATH . '/filters/AccessRule.php', @@ -211,6 +212,7 @@ 'yii\mutex\PgsqlMutex' => YII2_PATH . '/mutex/PgsqlMutex.php', 'yii\rbac\Assignment' => YII2_PATH . '/rbac/Assignment.php', 'yii\rbac\BaseManager' => YII2_PATH . '/rbac/BaseManager.php', + 'yii\rbac\CheckAccessInterface' => YII2_PATH . '/rbac/CheckAccessInterface.php', 'yii\rbac\DbManager' => YII2_PATH . '/rbac/DbManager.php', 'yii\rbac\Item' => YII2_PATH . '/rbac/Item.php', 'yii\rbac\ManagerInterface' => YII2_PATH . '/rbac/ManagerInterface.php', diff --git a/framework/console/Application.php b/framework/console/Application.php index acb2c82a2ec..7a086625edc 100644 --- a/framework/console/Application.php +++ b/framework/console/Application.php @@ -50,6 +50,10 @@ * yii help * ``` * + * @property ErrorHandler $errorHandler The error handler application component. This property is read-only. + * @property Request $request The request component. This property is read-only. + * @property Response $response The response component. This property is read-only. + * * @author Qiang Xue * @since 2.0 */ diff --git a/framework/db/ColumnSchemaBuilder.php b/framework/db/ColumnSchemaBuilder.php index b381b5891a3..f19dee20434 100644 --- a/framework/db/ColumnSchemaBuilder.php +++ b/framework/db/ColumnSchemaBuilder.php @@ -77,6 +77,7 @@ class ColumnSchemaBuilder extends Object */ protected $isFirst; + /** * @var array mapping of abstract column types (keys) to type categories (values). * @since 2.0.8 @@ -301,7 +302,7 @@ protected function buildLengthString() /** * Builds the not null constraint for the column. - * @return string returns 'NOT NULL' if [[isNotNull]] is true, + * @return string returns 'NOT NULL' if [[isNotNull]] is true, * 'NULL' if [[isNotNull]] is false or an empty string otherwise. */ protected function buildNotNullString() diff --git a/framework/db/pgsql/Schema.php b/framework/db/pgsql/Schema.php index d99eb559d0e..96b44380252 100644 --- a/framework/db/pgsql/Schema.php +++ b/framework/db/pgsql/Schema.php @@ -15,6 +15,8 @@ * Schema is the class for retrieving metadata from a PostgreSQL database * (version 9.x and above). * + * @property string[] $viewNames All view names in the database. This property is read-only. + * * @author Gevik Babakhani * @since 2.0 */ @@ -107,6 +109,7 @@ class Schema extends \yii\db\Schema 'jsonb' => self::TYPE_STRING, 'xml' => self::TYPE_STRING, ]; + /** * @var array list of ALL view names in the database */ diff --git a/framework/grid/CheckboxColumn.php b/framework/grid/CheckboxColumn.php index 79a658cdf81..aa34f4e56b0 100644 --- a/framework/grid/CheckboxColumn.php +++ b/framework/grid/CheckboxColumn.php @@ -73,6 +73,7 @@ class CheckboxColumn extends Column */ public $cssClass; + /** * @inheritdoc * @throws \yii\base\InvalidConfigException if [[name]] is not set. diff --git a/framework/rbac/CheckAccessInterface.php b/framework/rbac/CheckAccessInterface.php index d67c89e90cd..1b1cb8375d8 100644 --- a/framework/rbac/CheckAccessInterface.php +++ b/framework/rbac/CheckAccessInterface.php @@ -1,4 +1,10 @@