mardi 20 mars 2018

Multiple implicit model binding with one controller in Laravel

I am trying to attach multiple models with one controller using implicit model binding but I am getting the following error if I try to attach more than one model with methods.

index() must be an instance of App\\Http\\Models\\Modelname, string given

Here is my code:

public function index(Model1 $model1,Model2 $model2,Model3 $model3)
{
    print_r($application_endpoint);
}



from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/2HKFUnJ
via IFTTT

Aucun commentaire:

Enregistrer un commentaire