2015-08-17 01:59:23 +08:00
|
|
|
<?php
|
|
|
|
|
2015-09-11 02:31:09 +08:00
|
|
|
namespace BookStack\Providers;
|
2015-08-17 01:59:23 +08:00
|
|
|
|
2018-09-25 23:58:03 +08:00
|
|
|
use BookStack\Actions\ActivityService;
|
2018-09-25 19:30:50 +08:00
|
|
|
use BookStack\Actions\ViewService;
|
2018-09-25 23:58:03 +08:00
|
|
|
use BookStack\Settings\SettingService;
|
|
|
|
use BookStack\Uploads\ImageService;
|
2015-08-17 01:59:23 +08:00
|
|
|
use Illuminate\Support\ServiceProvider;
|
|
|
|
|
|
|
|
class CustomFacadeProvider extends ServiceProvider
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* Bootstrap the application services.
|
|
|
|
*
|
|
|
|
* @return void
|
|
|
|
*/
|
|
|
|
public function boot()
|
|
|
|
{
|
|
|
|
//
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Register the application services.
|
|
|
|
*
|
|
|
|
* @return void
|
|
|
|
*/
|
|
|
|
public function register()
|
|
|
|
{
|
2018-01-29 00:58:52 +08:00
|
|
|
$this->app->bind('activity', function () {
|
2019-03-31 00:54:15 +08:00
|
|
|
return $this->app->make(ActivityService::class);
|
2015-08-17 01:59:23 +08:00
|
|
|
});
|
2015-08-30 22:31:16 +08:00
|
|
|
|
2018-01-29 00:58:52 +08:00
|
|
|
$this->app->bind('views', function () {
|
2019-03-31 00:54:15 +08:00
|
|
|
return $this->app->make(ViewService::class);
|
2015-11-22 01:22:14 +08:00
|
|
|
});
|
|
|
|
|
2018-01-29 00:58:52 +08:00
|
|
|
$this->app->bind('setting', function () {
|
2019-03-31 00:54:15 +08:00
|
|
|
return $this->app->make(SettingService::class);
|
2015-08-30 22:31:16 +08:00
|
|
|
});
|
2016-02-29 03:03:04 +08:00
|
|
|
|
2018-01-29 00:58:52 +08:00
|
|
|
$this->app->bind('images', function () {
|
2019-03-31 00:54:15 +08:00
|
|
|
return $this->app->make(ImageService::class);
|
2015-12-10 03:50:17 +08:00
|
|
|
});
|
2015-08-17 01:59:23 +08:00
|
|
|
}
|
|
|
|
}
|