loadViewsFrom(__DIR__.'/../../../../resources/views', 'laundry'); // Load translation $this->loadTranslationsFrom(__DIR__.'/../../../../resources/lang', 'laundry'); // Call pblish redources function $this->publishResources(); include __DIR__.'/../Http/routes.php'; } /** * Register the service provider. * * @return void */ public function register() { // Bind facade $this->app->bind('laundry', function ($app) { return $this->app->make('Bek\Laundry\Laundry'); }); // Repository binds // Bind Items to repository $this->app->bind( \Bek\Laundry\Interfaces\ItemsRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\ItemsRepository::class ); // Bind ItemTypes to repository $this->app->bind( \Bek\Laundry\Interfaces\ItemTypesRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\ItemTypesRepository::class ); // Bind ItemItems to repository $this->app->bind( \Bek\Laundry\Interfaces\ItemItemsRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\ItemItemsRepository::class ); // Bind Payments to repository $this->app->bind( \Bek\Laundry\Interfaces\PaymentsRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\PaymentsRepository::class ); // Bind PaymentMethods to repository $this->app->bind( \Bek\Laundry\Interfaces\PaymentMethodsRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\PaymentMethodsRepository::class ); // Bind Orders to repository $this->app->bind( \Bek\Laundry\Interfaces\OrdersRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\OrdersRepository::class ); // Bind Orders to repository $this->app->bind( \Bek\Laundry\Interfaces\OrdersRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\OrdersRepository::class ); // Bind Injurs to repository $this->app->bind( \Bek\Laundry\Interfaces\InjursRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\InjursRepository::class ); // Bind Area to repository $this->app->bind( \Bek\Laundry\Interfaces\AreaRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\AreaRepository::class ); // Bind UserDiscounts to repository $this->app->bind( \Bek\Laundry\Interfaces\UserDiscountsRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\UserDiscountsRepository::class ); // Bind Discounts to repository $this->app->bind( \Bek\Laundry\Interfaces\DiscountsRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\DiscountsRepository::class ); // Bind Blocks to repository $this->app->bind( \Bek\Laundry\Interfaces\BlocksRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\BlocksRepository::class ); // Bind Options to repository $this->app->bind( \Bek\Laundry\Interfaces\OptionsRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\OptionsRepository::class ); // Bind BlockCategories to repository $this->app->bind( \Bek\Laundry\Interfaces\BlockCategoriesRepositoryInterface::class, \Bek\Laundry\Repositories\Eloquent\BlockCategoriesRepository::class ); } /** * Get the services provided by the provider. * * @return array */ public function provides() { return ['laundry']; } /** * Publish resources. * * @return void */ private function publishResources() { // Publish configuration file $this->publishes([__DIR__.'/../../../../config/config.php' => config_path('package/laundry.php')], 'config'); // Publish public view $this->publishes([__DIR__.'/../../../../resources/views/public' => base_path('resources/views/vendor/laundry/public')], 'view-public'); // Publish admin view $this->publishes([__DIR__.'/../../../../resources/views/admin' => base_path('resources/views/vendor/laundry/admin')], 'view-admin'); // Publish language files $this->publishes([__DIR__.'/../../../../resources/lang' => base_path('resources/lang/vendor/courier')], 'lang'); // Publish migrations $this->publishes([__DIR__.'/../../../../database/migrations/' => base_path('database/migrations')], 'migrations'); // Publish seeds $this->publishes([__DIR__.'/../../../../database/seeds/' => base_path('database/seeds')], 'seeds'); } }