public static function CanDo($operation, $sectId = 0, $userId = false)
 {
     global $USER;
     if (!isset($USER) || !$sectId) {
         return false;
     }
     if ($USER->CanDoOperation('edit_php')) {
         return true;
     }
     if ((CCalendar::GetType() == 'group' || CCalendar::GetType() == 'user') && CCalendar::IsSocNet() && CCalendar::IsSocnetAdmin()) {
         return true;
     }
     $res = in_array($operation, self::GetOperations($sectId, $userId));
     self::$bClearOperationCache = false;
     return $res;
 }