[ 'class' => 'yii\web\ErrorAction', ], ]; } public function actionIndex() { $etablissement = Etablissement::findOne(['slug' => Yii::$app->getRequest()->getQueryParam('slug_producer')]) ; $points_vente = [] ; if($etablissement) { $points_vente = PointVente::find() ->where([ 'id_etablissement' => $etablissement->id, ]) ->all() ; } return $this->render('index',[ 'points_vente' => $points_vente ]) ; } } ?>