34 lines
707 B
PHP
Executable File
34 lines
707 B
PHP
Executable File
<?php
|
|
|
|
namespace App\Events;
|
|
|
|
use Illuminate\Queue\SerializesModels;
|
|
use Illuminate\Foundation\Events\Dispatchable;
|
|
use Illuminate\Broadcasting\InteractsWithSockets;
|
|
use Illuminate\Contracts\Broadcasting\ShouldBroadcast;
|
|
|
|
class PaymentNotify implements ShouldBroadcast
|
|
{
|
|
use Dispatchable, InteractsWithSockets, SerializesModels;
|
|
|
|
public $response;
|
|
public $userid;
|
|
public $paymentid;
|
|
|
|
public function __construct($response,$userid,$paymentid)
|
|
{
|
|
$this->response = $response;
|
|
$this->userid = $userid;
|
|
$this->paymentid = $paymentid;
|
|
}
|
|
|
|
public function broadcastOn()
|
|
{
|
|
return ['payment-notify'];
|
|
}
|
|
|
|
public function broadcastAs()
|
|
{
|
|
return 'trigger-payment';
|
|
}
|
|
} |