• Модуль: im
  • Путь к файлу: ~/bitrix/modules/im/lib/V2/Link/Reminder/ReminderCollection.php
  • Класс: BitrixImV2LinkReminderReminderCollection
  • Вызов: ReminderCollection::getByMessageIdsAndAuthorId
static function getByMessageIdsAndAuthorId(array $messageIds, int $userId): self
{
	if (empty($messageIds))
	{
		return new static();
	}

	$entities = LinkReminderTable::query()
		->setSelect(['ID', 'CHAT_ID', 'AUTHOR_ID', 'DATE_CREATE', 'MESSAGE_ID', 'DATE_REMIND', 'IS_REMINDED'])
		->whereIn('MESSAGE_ID', $messageIds)
		->where('AUTHOR_ID', $userId)
		->fetchCollection()
	;

	if ($entities === null)
	{
		return new static();
	}

	return static::initByEntityCollection($entities);
}