2022-08-12 07:56:56 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Providers;
|
|
|
|
|
2022-12-27 16:25:22 +00:00
|
|
|
use App\Models\Balance;
|
|
|
|
use App\Models\WorkOrder\Reply;
|
|
|
|
use App\Models\WorkOrder\WorkOrder;
|
|
|
|
use App\Observers\BalanceObserve;
|
|
|
|
use App\Observers\WorkOrder\ReplyObserver;
|
|
|
|
use App\Observers\WorkOrder\WorkOrderObserver;
|
2022-11-06 11:28:22 +00:00
|
|
|
use Illuminate\Auth\Events\Registered;
|
|
|
|
use Illuminate\Auth\Listeners\SendEmailVerificationNotification;
|
|
|
|
use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider;
|
2022-08-12 07:56:56 +00:00
|
|
|
|
|
|
|
class EventServiceProvider extends ServiceProvider
|
|
|
|
{
|
|
|
|
/**
|
2022-11-06 11:28:22 +00:00
|
|
|
* The event to listener mappings for the application.
|
2022-08-12 07:56:56 +00:00
|
|
|
*
|
2022-11-06 11:28:22 +00:00
|
|
|
* @var array<class-string, array<int, class-string>>
|
2022-08-12 07:56:56 +00:00
|
|
|
*/
|
|
|
|
protected $listen = [
|
2022-11-06 11:28:22 +00:00
|
|
|
Registered::class => [
|
|
|
|
SendEmailVerificationNotification::class,
|
|
|
|
],
|
2022-08-12 07:56:56 +00:00
|
|
|
];
|
|
|
|
|
2022-11-06 11:28:22 +00:00
|
|
|
/**
|
|
|
|
* Register any events for your application.
|
|
|
|
*
|
|
|
|
* @return void
|
|
|
|
*/
|
|
|
|
public function boot()
|
|
|
|
{
|
|
|
|
//
|
2022-11-06 15:18:46 +00:00
|
|
|
|
2022-12-27 16:25:22 +00:00
|
|
|
WorkOrder::observe(WorkOrderObserver::class);
|
|
|
|
Reply::observe(ReplyObserver::class);
|
|
|
|
Balance::observe(BalanceObserve::class);
|
2022-11-06 11:28:22 +00:00
|
|
|
}
|
|
|
|
|
2022-08-12 07:56:56 +00:00
|
|
|
/**
|
|
|
|
* Determine if events and listeners should be automatically discovered.
|
|
|
|
*
|
|
|
|
* @return bool
|
|
|
|
*/
|
|
|
|
public function shouldDiscoverEvents()
|
|
|
|
{
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|