I have added a check box column in my yii2 grid and created a button that can delete all selected values. However in my action col i have made it possible that the delete icon only shows dependant as follows.
'delete' => function ($model, $key, $index) {
/* add public function in model i,e GetstopDelete*/
if(empty($model->stopDelete))
return true;
else
return $model->stopDelete == 1 ? false : true;
}
},
BUT, how to i hide the cell of the check box based on same parameters as I do not want the check box available if you cannot delete the row?
I am using http://ift.tt/2nx3nyz and http://ift.tt/1PkHvzC
Aucun commentaire:
Enregistrer un commentaire