Example #1
0
 /**
  * mark a notification record as read
  * @param  array $p containing "id" (returned client side id) and "ids"
  * @return json  response
  */
 public function markAsRead($p)
 {
     $rez = array('success' => false);
     if (!empty($p['ids'])) {
         DM\Notifications::markAsRead($p['ids'], User::getId());
         $rez = array('success' => true, 'data' => $p);
     }
     return $rez;
 }