Added method getCountUnreadMessages

This commit is contained in:
bison-paolo
2016-12-20 11:28:51 +01:00
parent b3476f93c1
commit b99123efc6
3 changed files with 57 additions and 0 deletions
+16
View File
@@ -153,6 +153,22 @@ class MessageLib
return $result;
}
/**
* getCountUnreadMessages
*
* @param bigint $person_id REQUIRED
* @return array
*/
public function getCountUnreadMessages($person_id)
{
if (!is_numeric($person_id))
return $this->_error('', MSG_ERR_INVALID_RECIPIENTS);
$msg = $this->ci->RecipientModel->getCountUnreadMessages($person_id);
return $msg;
}
/**
* updateMessageStatus() - will change status on message for particular user