Попробуйте следующее
class InvoiceService implements IInvoiceService
{
protected $app;
protected $repo;
public function _construct($app, $repo) {
$this->app = $app;
$this->repo = $repo;
}
public function Create() {
}
}
App \ Providers \ AppServiceProvider
public function register() {
$this->app->singleton(
'App\Models\Subscription\Interfaces\IInvoiceService',
'App\Models\Subscription\Impl\InvoiceService'
);
$this->app->when('App\Models\Subscription\Impl\InvoiceService')
->needs('$app')
->give($this->app->getFacadeRoot());
$this->app->when('App\Models\Subscription\Impl\InvoiceService')
->needs('$repo')
->give($this->app['repo']);
}
public function boot(ResponseFactory $response) {
//uncomment this line to debug InvoiceService Resolving event
//$this->app->resolving(App\Models\Subscription\Impl\InvoiceService::class, function ($invoiceService, $app) {
//dump('resolves InvoiceService', $invoiceService);
//});
}
Затем выполните
php artisan clear-compiled
php artisan config:clear