title = 'Інтенсивність руху та склад транспортного потоку'; $this->params['breadcrumbs'][] = $this->title; ?>
= Html::a('Додати', ['create'], ['class' => 'btn btn-success']) ?>
= GridView::widget([ 'dataProvider' => $dataProvider, 'filterModel' => null, 'columns' => [ ['class' => 'yii\grid\SerialColumn'], [ 'attribute' => 'road_id', 'value' => function($model) { /** * @var FlowIntensity $model */ return $model->road->name; } ], [ 'attribute' => 'region_id', 'value' => function($model) { /** * @var FlowIntensity $model */ return $model->region->name; } ], [ 'attribute' => 'location', 'value' => function($model) { /** * @var FlowIntensity $model */ return $model->getLocationString(); } ], [ 'attribute' => 'road_direction_id', 'value' => function($model) { /** * @var FlowIntensity $model */ return $model->roadDirection->direction_name; } ], [ 'attribute' => 'settlement_id', 'value' => function($model) { /** * @var FlowIntensity $model */ return $model->settlement->sign; } ], [ 'attribute' => 'date_add', 'value' => function($model) { /** * @var FlowIntensity $model */ return date('d.m.Y', $model->date_add); } ], ['class' => 'yii\grid\ActionColumn'], ], ]); ?>