ConversationModel::updateParticipantCount PHP Метод

updateParticipantCount() публичный Метод

Update the count of participants.
public updateParticipantCount ( integer $ConversationID )
$ConversationID integer
    public function updateParticipantCount($ConversationID)
    {
        if (!$ConversationID) {
            return;
        }
        $Count = $this->SQL->select('uc.UserID', 'count', 'CountParticipants')->from('UserConversation uc')->where('uc.ConversationID', $ConversationID)->where('uc.Deleted', 0)->get()->value('CountParticipants', 0);
        $this->setField($ConversationID, 'CountParticipants', $Count);
    }