我是yii2的新手,我想查看学生数据,在这张图片中我想删除删除和编辑图标,如何消除此图标?This is my web view
这是此索引视图的源代码
GridView::widget([
'dataProvider' => $dataProvider,
'filterModel' => $searchModel,
'columns' => [
['class' => 'yii\grid\SerialColumn'],
'nis',
'nama_siswa',
'jenis_kelamin',
'telp',
[
...],
['class' => 'yii\grid\ActionColumn'],
],
]); ?>
答案 0 :(得分:1)
将ActionColumn的template
属性用作
<?= GridView::widget([
'dataProvider' => $dataProvider,
'filterModel' => $searchModel,
'columns' => [
['class' => 'yii\grid\SerialColumn'],
'nis',
'nama_siswa',
'jenis_kelamin',
'telp',
[
...],
[
'class' => 'yii\grid\ActionColumn',
'template' => '{view}'
],
],
]); ?>