dimanche 27 mars 2016

Call a controller Action when using route group

I want to call an action of a controller in laravel blade , when using router group ..

route

  $router->group([
      'namespace' => 'Admin',
      'middleware' => 'auth',
    ], function () {
        resource('admin/adsense', 'AdsenseController');
        resource('admin/post', 'PostController');
    });

So , i want call an action of adsenseController in the blade template

{!! Form::model($var, ['method' => 'PATCH','route' => ['what should i write to call an action ']]) !!}

Example (without router groupe)

route

Route::resource('subject','SubjectController');

blade template

{!! Form::model($var, ['method' => 'PATCH','route' => ['subject.actionName']]) !!}

thanks



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire