17 public static function get(
string $key =
'', $siteId = SITE_ID): string
31 ? Option::get(
'intranet',
'search_user_url', self::getDefault($key, $siteId), $siteId)
35 case 'user_calendar_path_template':
36 $result = self::get(
'user_profile', $siteId) .
'calendar/';
38 case 'user_create_group_path_template':
39 $result = self::get(
'user_profile', $siteId) .
'groups/create/';
41 case 'user_tasks_path_template':
42 $result = self::get(
'user_profile', $siteId) .
'tasks/';
44 case 'user_tasks_view_path_template':
45 $result = self::get(
'user_tasks_path_template', $siteId) .
'view/#action#/#view_id#/';
47 case 'user_tasks_report_path_template':
48 $result = self::get(
'user_tasks_path_template', $siteId) .
'report/';
50 case 'user_tasks_templates_path_template':
51 $result = self::get(
'user_tasks_path_template', $siteId) .
'templates/';
53 case 'userblogpost_page':
54 case 'group_path_template':
55 case 'workgroups_page':
56 $result = Option::get(
'socialnetwork', $key, self::getDefault($key, $siteId), $siteId);
58 case 'group_edit_path_template':
59 $result = self::get(
'group_path_template', $siteId) .
'edit/';
61 case 'group_delete_path_template':
62 $result = self::get(
'group_path_template', $siteId) .
'delete/';
64 case 'group_invite_path_template':
65 $result = self::get(
'group_path_template', $siteId) .
'invite/';
67 case 'group_livefeed_path_template':
68 $result = self::get(
'group_path_template', $siteId) . (
70 && SITE_TEMPLATE_ID ===
'bitrix24'
75 case 'group_tasks_path_template':
76 $result = self::get(
'group_path_template', $siteId) .
'tasks/';
78 case 'group_tasks_task_path_template':
79 $result = self::get(
'group_tasks_path_template', $siteId) .
'task/#action#/#task_id#/';
81 case 'group_tasks_view_path_template':
82 $result = self::get(
'group_tasks_path_template', $siteId) .
'view/#action#/#view_id#/';
84 case 'group_tasks_report_path_template':
85 $result = self::get(
'group_tasks_path_template', $siteId) .
'report/';
87 case 'group_calendar_path_template':
88 $result = self::get(
'group_path_template', $siteId) .
'calendar/';
90 case 'group_users_path_template':
91 $result = self::get(
'group_path_template', $siteId) .
'users/';
93 case 'group_requests_path_template':
94 $result = self::get(
'group_path_template', $siteId) .
'requests/';
96 case 'group_requests_out_path_template':
97 $result = self::get(
'group_path_template', $siteId) .
'requests_out/';
99 case 'user_request_group_path_template':
100 $result = self::get(
'group_path_template', $siteId) .
'user_request/';
102 case 'user_leave_group_path_template':
103 $result = self::get(
'group_path_template', $siteId) .
'user_leave/';
105 case 'department_path_template':
106 $result = Option::get(
'main',
'TOOLTIP_PATH_TO_CONPANY_DEPARTMENT', self::getDefault(
'TOOLTIP_PATH_TO_CONPANY_DEPARTMENT', $siteId), $siteId);
114 private static function getDefault(
string $key =
'', $siteId = SITE_ID): string
131 $result = $siteDir . self::getUserFolder($siteId) .
'#user_id#/';
133 case 'userblogpost_page':
134 $result = $siteDir . self::getUserFolder($siteId) .
'#user_id#/blog/#post_id#/';
136 case 'group_path_template':
137 $result = self::getDefault(
'workgroups_page', $siteId) .
'group/#group_id#/';
139 case 'department_path_template':
140 $result = $siteDir .
'company/structure.php?set_filter_structure=Y&structure_UF_DEPARTMENT=#ID#';
142 case 'workgroups_page':
143 $result = $siteDir .
'workgroups/';
151 private static function getUserFolder($siteId = SITE_ID): string
153 static $extranetSiteId =
null;
155 if ($extranetSiteId ===
null)
160 return ($siteId === $extranetSiteId ?
'contacts' :
'company') .
'/personal/user/';
static includeModule($moduleName)
static isModuleInstalled($moduleName)