Commit 85df7814 by sanchezby

Update data-grid.md

DataColumn doesn't have "name" & "type" fields, and should have fully qualified name if not omitted
parent cd7e51df
......@@ -50,12 +50,10 @@ echo GridView::widget([
'username',
// More complex one.
[
'class' => 'DataColumn', // can be omitted, default
'name' => 'column1',
'class' => 'yii\grid\DataColumn', // can be omitted, default
'value' => function ($data) {
return $data->name;
},
'type'=>'raw',
],
],
]);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment