title = 'Ответы на вопросы'; $this->params['breadcrumbs'][] = $this->title; ?>
render('_search', ['model' => $searchModel]); ?>

'btn btn-success']) ?>

$dataProvider, 'filterModel' => $searchModel, 'columns' => [ ['class' => 'yii\grid\SerialColumn'], // 'id', [ 'attribute' => 'question_id', 'value' => function($model){ return $model->getQuestionBody(); } ], 'answer_body', [ 'attribute' => 'answer_flag', 'format' => 'raw', 'value' => function ($model) { return \yii\helpers\Html::tag( 'span', $model->answer_flag ? 'Correct' : 'Wrong', [ 'class' => 'label label-' . ($model->answer_flag ? 'success' : 'danger'), ] ); }, ], [ 'attribute' => 'status', 'format' => 'raw', 'value' => function ($model) { return \yii\helpers\Html::tag( 'span', $model->status ? 'Active' : 'Not Active', [ 'class' => 'label label-' . ($model->status ? 'success' : 'danger'), ] ); }, ], //'created_at', //'updated_at', ['class' => 'yii\grid\ActionColumn'], ], ]); ?>