未找到Laravel 5 Class'Prettus \ Repository \ Providers \ Repository ServiceProvider'
I'm studing about Repository Design Pattern in Laravel and I'm using https://github.com/andersao/l5-repository to do it.
But after I copy/paste folder prettus in my project and add in my config/app.php Prettus\Repository\Providers\RepositoryServiceProvider::class to the end of the providers array I find a problem:
Class 'Prettus\Repository\Providers\Repository ServiceProvider' not found
After that, the project can't run. Please help me.
Thanks
我正在研究Laravel中的存储库设计模式 strong>,我正在使用 https://github.com/andersao/l5-repository 来做这件事。 p>
但是在我的项目中复制/粘贴文件夹prettus并添加到 config / app.php strong> Prettus \ Repository \ Providers \ RepositoryServiceProvider :: class strong>之后 提供者数组的结尾我发现了一个问题: p>
之后,项目无法运行。 请帮帮我。 p>
谢谢 p>
div>
Class'Prettus \ Repository \ Providers \ Repository ServiceProvider'not found
code> pre>
Don't copy/paste the source folder in your project.
Try following the instructions as stated in the Github documentation:
composer require prettus/l5-repository
After the installation finishes you can include the Class in the ServiceProvider array and then you have to publish the configuration:
php artisan vendor:publish