2020-05-14 21:04:39 +03:00

82 lines
1.4 KiB
PHP

<?php
namespace Modules\PaypalStandard\Providers;
use Illuminate\Support\ServiceProvider as Provider;
class Main extends Provider
{
/**
* Boot the application events.
*
* @return void
*/
public function boot()
{
$this->loadTranslations();
$this->loadViews();
}
/**
* Register the service provider.
*
* @return void
*/
public function register()
{
$this->loadRoutes();
}
/**
* Load views.
*
* @return void
*/
public function loadViews()
{
$this->loadViewsFrom(__DIR__ . '/../Resources/views', 'paypal-standard');
}
/**
* Load translations.
*
* @return void
*/
public function loadTranslations()
{
$this->loadTranslationsFrom(__DIR__ . '/../Resources/lang', 'paypal-standard');
}
/**
* Load routes.
*
* @return void
*/
public function loadRoutes()
{
if (app()->routesAreCached()) {
return;
}
$routes = [
'guest.php',
'portal.php',
'signed.php',
];
foreach ($routes as $route) {
$this->loadRoutesFrom(__DIR__ . '/../Routes/' . $route);
}
}
/**
* Get the services provided by the provider.
*
* @return array
*/
public function provides()
{
return [];
}
}