sample event listener and scaffolding for a module

This commit is contained in:
Nabeel Shahzad
2017-12-02 09:19:58 -06:00
parent b14f4355da
commit df2b092d60
15 changed files with 143 additions and 38 deletions

23
app/Events/TestEvent.php Normal file
View File

@@ -0,0 +1,23 @@
<?php
namespace App\Events;
use App\Models\User;
use Illuminate\Queue\SerializesModels;
use Illuminate\Foundation\Events\Dispatchable;
use Illuminate\Broadcasting\InteractsWithSockets;
class TestEvent
{
use Dispatchable, InteractsWithSockets, SerializesModels;
public $user;
/**
* Create a new event instance.
*/
public function __construct(User $user)
{
$this->user = $user;
}
}