- Модуль: timeman
- Путь к файлу: ~/bitrix/modules/timeman/classes/general/timeman_report_daily.php
- Класс: CAllTimeManReportDaily
- Вызов: CAllTimeManReportDaily::Add
static function Add($arFields)
{
global $DB;
$e = GetModuleEvents('timeman', 'OnBeforeTMReportDailyAdd');
while ($a = $e->Fetch())
{
if (false === ExecuteModuleEventEx($a, array(&$arFields)))
return false;
}
if (!self::CheckFields('ADD', $arFields))
return false;
CTimeZone::Disable();
$ID = $DB->Add('b_timeman_report_daily', $arFields, array('REPORT', 'TASKS', 'EVENTS'));
CTimeZone::Enable();
if ($ID > 0)
{
$arFields['ID'] = $ID;
$e = GetModuleEvents('timeman', 'OnAfterTMReportDailyAdd');
while ($a = $e->Fetch())
ExecuteModuleEventEx($a, array($arFields));
}
return $ID;
}