Reputation: 1021
I've upgraded from Laravel 4 to Laravel 4.1 in a new branch on my repo, following the steps in
https://github.com/laravel/laravel/blob/develop/upgrade.md
The only step I wasn't able to fully follow was point 11 - add use Illuminate\Routing\Controller
in baseController. The instruction is to replace an existing use
statement. However in my version 4.0.9, it wasn't there.
Anyway, I am encountering a routing error when trying to hit a grouped route.
Symfony \ Component \ HttpKernel \ Exception \ NotFoundHttpException
Controller method [audience/uk] not found.
I could hit the route without problems in the 4.0 branch.
I believe my upgrade went ok otherwise as I could correctly see the 4.1 changes in `artisan changes'
My route looks like this:
Route::group(array('prefix' => 'admin', 'before' => 'auth.basic'), function()
{
Route::get('upload/audience/uk',array('as' => 'get-upload-uk-audience', 'uses' => 'CSVController@getUKAudience'));
});
Any ideas?
Thanks
Upvotes: 0
Views: 1106
Reputation: 23
I came across the same problem using Laravel 4.1 which I solved by adding the following line right at the very top of the BaseContoller.
use Illuminate\Routing\Controller;
I'm also using Codesleeve Asset Pipline and had to add the same line to the top of the AssetPipelineController to get that working too.
I did quite an extensive search on this topic and was surprised at the lack of information online.
Hope this helps
Upvotes: 2
Reputation: 1021
I'm just going to avoid using Route::controller.
Ref: https://github.com/laravel/framework/pull/2850
Thanks @Anultro from the github irc channel
Upvotes: 0