Closed phrakon closed 3 years ago
Create configuration like that:
<?= GridView::widget([ 'dataProvider' => $dataProvider, 'columns' => [ [ '__class' => ActionColumn::class, 'template' => '{update} {delete}{restore}', 'headerOptions' => ['class' => 'min'], 'contentOptions' => ['class' => 'min'], ], ], ]) ?>
No inspection warnings.
Field '__class' not exists in referenced class \yii\grid\DataColumn
There is no warning when use 'class'. 'class' works similar '_class'.
https://github.com/yiisoft/yii2/pull/17607
Looks like missing an additional condition:
https://github.com/nvlad/yii2support/blob/2766730b832c3a2b383cb4d624613c2d4762629a/src/com/nvlad/yii2support/objectfactory/ObjectFactoryMissedFieldInspection.java#L40
Support for __class added at version 0.10.58.37. Please update plugin.
__class
What steps will reproduce the problem?
Create configuration like that:
What is the expected result?
No inspection warnings.
What do you get instead?
Field '__class' not exists in referenced class \yii\grid\DataColumn
Additional info
There is no warning when use 'class'. 'class' works similar '_class'.
https://github.com/yiisoft/yii2/pull/17607
Looks like missing an additional condition:
https://github.com/nvlad/yii2support/blob/2766730b832c3a2b383cb4d624613c2d4762629a/src/com/nvlad/yii2support/objectfactory/ObjectFactoryMissedFieldInspection.java#L40