Files
eatvio-infra/app/Events/DietSelected.php
2023-12-18 14:51:58 +03:00

40 lines
792 B
PHP

<?php
namespace App\Events;
use App\Models\Diet;
use App\Models\User;
use Illuminate\Broadcasting\InteractsWithSockets;
use Illuminate\Foundation\Events\Dispatchable;
use Illuminate\Queue\SerializesModels;
class DietSelected
{
use Dispatchable, InteractsWithSockets, SerializesModels;
public $diet;
public $user;
/**
* Create a new event instance.
*
* @return void
*/
public function __construct(Diet $diet, User $user)
{
$this->diet = $diet;
$this->user = $user;
}
/**
* Get the channels the event should broadcast on.
*
* @return \Illuminate\Broadcasting\Channel|array
*/
/* public function broadcastOn() */
/* { */
/* return new PrivateChannel('channel-name'); */
/* } */
}