diff --git a/framework/CHANGELOG.md b/framework/CHANGELOG.md index e51bd79d09..c639d43ff3 100644 --- a/framework/CHANGELOG.md +++ b/framework/CHANGELOG.md @@ -49,6 +49,7 @@ Yii Framework 2 Change Log - Bug #10385: Fixed `yii\validators\CaptchaValidator` passed incorrect hashKey to JS validator when `captchaAction` begins with `/` (silverfire) - Bug #10467: Fixed `yii\di\Instance::ensure()` to work with minimum settings (LAV45) - Bug #10541: Fixed division by zero issue in `Console` helper progress bar (youmad) +- Bug #10580: Fixed `yii\grid\GridView::guessColumns()` to work with numeric column names (silverfire) - Bug: Fixed generation of canonical URLs for `ViewAction` pages (samdark) - Bug: Fixed `mb_*` functions calls to use `UTF-8` or `Yii::$app->charset` (silverfire) - Enh #3506: Added `yii\validators\IpValidator` to perform validation of IP addresses and subnets (SilverFire, samdark) diff --git a/framework/grid/GridView.php b/framework/grid/GridView.php index 4baf78c957..be770cc601 100644 --- a/framework/grid/GridView.php +++ b/framework/grid/GridView.php @@ -569,7 +569,7 @@ class GridView extends BaseListView $model = reset($models); if (is_array($model) || is_object($model)) { foreach ($model as $name => $value) { - $this->columns[] = $name; + $this->columns[] = (string) $name; } } }