• Модуль: crm
  • Путь к файлу: ~/bitrix/modules/crm/lib/volume/tmpeventindexfix.php
  • Класс: Bitrix\Crm\Volume\TmpEventIndexFix
  • Вызов: TmpEventIndexFix::hasJobDone
static function hasJobDone()
{
	$connection = \Bitrix\Main\Application::getConnection();

	$result = $connection->query("SELECT count(*) AS CNT FROM b_crm_event WHERE FILES IS NOT NULL AND (FILES = '' OR FILES = 'a:0:{}')");
	if ($row = $result->fetch())
	{
		return ($row['CNT'] == 0);
	}

	return true;
}