Notifications page : mark all as read working
This commit is contained in:
parent
cdf663d4ca
commit
5c9f450539
7 changed files with 76 additions and 19 deletions
10
public/site/plugins/notifications/routes/readAll.php
Normal file
10
public/site/plugins/notifications/routes/readAll.php
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
<?php
|
||||
|
||||
return [
|
||||
'pattern' => '(:all)read-all-notifications.json',
|
||||
'method' => 'GET',
|
||||
'action' => function () {
|
||||
$newNotifications = kirby()->user()->readAllNotifications();
|
||||
return $newNotifications;
|
||||
}
|
||||
];
|
||||
Loading…
Add table
Add a link
Reference in a new issue