Passed variable from view to other view?

Hello, i have controller

return $this->render('index', [



In view i have gridView widget

'columns' => [





                    return GridView::ROW_COLLAPSED;




                    $searchModel=new \backend\models\roomSearch();



                    return Yii::$app->controller->renderPartial('_items',[

                        'value'=>$value, // here i have problem





I need passed variable $value to next view, but compilator doesn’t see them in array columns.


'detail'=>function($model,$key,$index,$column) use ($value) { //...

Thank you:) I tried using closuer function, but I used it in bad place (‘value’=>$value) and not worked