PaginationServiceProvider.php 740 B

12345678910111213141516171819202122232425262728293031323334
  1. <?php
  2. namespace Illuminate\Pagination;
  3. use Illuminate\Support\ServiceProvider;
  4. class PaginationServiceProvider extends ServiceProvider
  5. {
  6. /**
  7. * Bootstrap any application services.
  8. *
  9. * @return void
  10. */
  11. public function boot()
  12. {
  13. $this->loadViewsFrom(__DIR__.'/resources/views', 'pagination');
  14. if ($this->app->runningInConsole()) {
  15. $this->publishes([
  16. __DIR__.'/resources/views' => $this->app->resourcePath('views/vendor/pagination'),
  17. ], 'laravel-pagination');
  18. }
  19. }
  20. /**
  21. * Register the service provider.
  22. *
  23. * @return void
  24. */
  25. public function register()
  26. {
  27. PaginationState::resolveUsing($this->app);
  28. }
  29. }