3namespace Bitrix\Im\V2\Recent;
6use Bitrix\Im\V2\Common\ContextCustomer;
7use Bitrix\Im\V2\Entity\User\UserPopupItem;
8use Bitrix\Im\V2\Message;
9use Bitrix\Im\V2\Message\MessagePopupItem;
10use Bitrix\Im\V2\MessageCollection;
11use Bitrix\Im\V2\Registry;
12use Bitrix\Im\V2\Rest\PopupData;
13use Bitrix\Im\V2\Rest\PopupDataAggregatable;
14use Bitrix\Im\V2\Rest\PopupDataItem;
15use Bitrix\Im\V2\Settings\UserConfiguration;
31 foreach ($this as $item)
33 $messageIds[] = $item->getMessageId();
35 $chatIds[] = $item->getChatId();
37 if ($item->getType() === RecentType::User)
39 $userIds[] = $item->getId();
64 foreach ($this as $item)
66 $rest[] = $item->toRestFormat();
81 if (isset($userSettings[
'pinnedChatSort']) && $userSettings[
'pinnedChatSort'] ===
'byCost')
86 'DATE_LAST_ACTIVITY' =>
'DESC',
92 'DATE_LAST_ACTIVITY' =>
'DESC',
if(!is_object($USER)||! $USER->IsAuthorized()) $userId
static getRestEntityName()
toRestFormat(array $option=[])
static getOrder(int $userId)
getPopupData(array $excludedList=[])
getMessagesForPopupData(array $messageIds)
merge(PopupDataItem $item)
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)