mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-03 13:58:55 +08:00
Merge branch 'master' of https://github.com/yiisoft/yii2 into schema-cache-fixes
This commit is contained in:
@ -276,9 +276,8 @@ class QueryBuilder extends \yii\db\QueryBuilder
|
||||
if (!$modelClass) {
|
||||
return null;
|
||||
}
|
||||
/* @var $model \yii\db\ActiveRecord */
|
||||
$model = new $modelClass;
|
||||
$schema = $model->getTableSchema();
|
||||
/* @var $modelClass \yii\db\ActiveRecord */
|
||||
$schema = $modelClass::getTableSchema();
|
||||
return array_keys($schema->columns);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user