vendredi 5 juin 2015

Laravel Package's Controller does not exsist

I have a Laravel 4.2 application.In this I have my workbench folder with two packages. One package is vehicle package.I have attached the structure of the package with this. In the package routes.php I have a route :

Route::get('/vehicles', array(
    'as' => 'vehicles', 'uses' => 'VehicleController@index'
    )
);

For this route I have a index() method in VehicleController.php

Note : In the config/app.php I have added the VehicleServiceProvider.php

When I run the application with localhost/Application_Root/public/vehicles it redirects to the root properly , but gives a Reflection Exception "VehicleController does not exsist."

Can anyone please help me on this? Thank you in advance!

Vehicle package structure:

Vehicle
     -public
     - src
          -config
          -controllers
          -Vendor
                 -Vehicle
                         -Controllers
                         -Models
                         -Repositories
                          VehicleServiceProvider.php
          -migrations
          -views
     -test
     -vendor
          -routes.php





Aucun commentaire:

Enregistrer un commentaire