break; } } } } if (!is_array($result["FILE"])) { require $_SERVER["DOCUMENT_ROOT"] . BX_ROOT . "/modules/main/include/prolog_after.php"; ShowError("File not found"); require $_SERVER["DOCUMENT_ROOT"] . BX_ROOT . "/modules/main/include/epilog.php"; die; } set_time_limit(0); CFile::ViewByUser($result["FILE"]); } else { $bAdminAction = substr($action, 0, 6) == 'admin_' || $action == 'calendar_show' || $action == 'add_comment_entry' || $action == 'add_comment_full_report' || $action == 'user_report_edit'; if (!CTimeMan::CanUse($bAdminAction)) { echo "{error: 'access denied', type: 'fatal'}"; } else { CUtil::JSPostUnescape(); $error = false; $bReturnRes = false; $bGetFullInfo = $_REQUEST['full'] == 'Y'; $obUser = CTimeManUser::instance(); $obUser->SITE_ID = $_REQUEST['site_id']; switch ($action) { case "report_full_setting": $bReturnRes = true; if ($_POST["id"]) { $ID = intval($_POST["id"]); } if ($_POST["object"] == 'user') {
<?php if (!defined("B_PROLOG_INCLUDED") || B_PROLOG_INCLUDED !== true) { die; } if (CBXFeatures::IsFeatureEnabled('timeman') && CModule::IncludeModule('timeman') && CTimeMan::CanUse()) { if (abs(CTimeZone::GetOffset()) > BX_TIMEMAN_WRONG_DATE_CHECK) { $arResult['ERROR'] = 'WRONG_DATE'; $this->IncludeComponentTemplate('error'); return true; } $arResult['TASKS_ENABLED'] = CBXFeatures::IsFeatureEnabled('Tasks') && CModule::IncludeModule('tasks'); $arResult['START_INFO'] = CTimeMan::GetRuntimeInfo(false); $obReportUser = new CUserReportFull(); $arResult['WORK_REPORT'] = $obReportUser->GetReportData(); //echo '<pre>'; print_r($arResult['WORK_REPORT']); echo '</pre>'; CIntranetPlanner::initScripts($arResult['START_INFO']['PLANNER']); $arResult['START_INFO']['PLANNER'] = $arResult['START_INFO']['PLANNER']['DATA']; CJSCore::Init(array('timeman')); $this->IncludeComponentTemplate(); return true; } else { return false; }