<div class="box box-primary">
<div class="box-body">
<?php Pjax::begin() ; echo GridView::widget([
'pjax' => true,
'dataProvider' => $objDataProvider,
'filterModel' => $objSearchModel ,
'応答性'=> true,
'hover'=> true,
'condensed'=> true,
/ /'floatHeader'=> false,
'columns' => [
[
'attribute' => 'id',
(这里让他不包含id99999)
'label' =&gt; '编号'、
'halign' =&gt; gridview :: align_center、
]、
## [ 'attribute' => 'agent_id', 'label' => '代理编号', 'hAlign'=> GridView::ALIGN_CENTER, ]、 [# '属性' =&gt; 'agent'、 'label' =&gt; '昵' '、' value ' => function($objModel) { return $objModel->agent->screen_name; }, 'width'=>'150px' , 'hAlign'=> GridView::ALIGN_CENTER, ], /*Summer2018-07-20 15:01:29
$newarray = $columns;
foreach($columns as $key => $vo){
if($vo['attribute']==99999){
unset($newarray [$key]) ;
}
}
print_r($newarray);//これは、99999 が削除された新しい配列です