• Модуль: rpa
  • Путь к файлу: ~/bitrix/modules/rpa/lib/integration/disk/connector.php
  • Класс: BitrixRpaIntegrationDiskConnector
  • Вызов: Connector::canRead
public function canRead($userId): bool
{
	$timeline = TimelineTable::getById((int) $this->entityId)->fetchObject();
	if($timeline)
	{
		$item = $timeline->getItem();
		if($item)
		{
			return Driver::getInstance()->getUserPermissions($userId)->canViewItem($item);
		}
		else
		{
			return ($timeline->getUserId() === (int) $userId);
		}
	}

	return false;
}