main
This commit is contained in:
+26
@@ -0,0 +1,26 @@
|
||||
<?php
|
||||
namespace App\Http\Controllers\Site;
|
||||
|
||||
use App\Http\Controllers\Controller;
|
||||
use App\Services\NotificationService;
|
||||
use Illuminate\Http\Request;
|
||||
|
||||
class myNotificationController extends Controller
|
||||
|
||||
{
|
||||
protected $notificationService;
|
||||
|
||||
public function __construct(NotificationService $notificationService)
|
||||
{
|
||||
$this->notificationService = $notificationService;
|
||||
}
|
||||
|
||||
public function mySendNotification(Request $request)
|
||||
{
|
||||
return 1;
|
||||
$message = $request->input('message');
|
||||
$response = $this->notificationService->sendNotification($message);
|
||||
|
||||
return response()->json($response);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user