18 lines
412 B
PHP
18 lines
412 B
PHP
<?php
|
|
|
|
namespace App\Http\Controllers;
|
|
|
|
use App\Models\Notification;
|
|
use Illuminate\Foundation\Auth\Access\AuthorizesRequests;
|
|
use Illuminate\Http\Request;
|
|
|
|
class NotificationController extends Controller
|
|
{
|
|
use AuthorizesRequests;
|
|
public function markRead(Request $request, Notification $notification)
|
|
{
|
|
$this->authorize('update', $notification);
|
|
$notification->markAsRead();
|
|
}
|
|
}
|