1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
OnboardingFeature.php
См. документацию.
1<?php
2
3declare(strict_types=1);
4
5namespace Bitrix\Socialnetwork\Collab\Onboarding;
6
7use Bitrix\Main\Config\Configuration;
8use Bitrix\Main\Config\Option;
9use Bitrix\Socialnetwork\Collab\CollabFeature;
10
12{
13 public static function isOn(): bool
14 {
15 return Option::get('socialnetwork', 'collab_onboarding_feature', 'Y') === 'Y';
16 }
17
18 public static function turnOn(): void
19 {
20 Option::set('socialnetwork', 'collab_onboarding_feature', 'Y');
21 }
22
23 public static function isAvailable(): bool
24 {
25 if (self::isDevMode())
26 {
27 return true;
28 }
29
30 if (!self::isOn())
31 {
32 return false;
33 }
34
36 }
37
38 private static function isDevMode(): bool
39 {
40 $exceptionHandling = Configuration::getValue('exception_handling');
41
42 return !empty($exceptionHandling['debug']);
43 }
44}
static isFeatureEnabledInPortalSettings()
Определения CollabFeature.php:29