2namespace Bitrix\Landing\Restriction;
4use \Bitrix\Main\Localization\Loc;
6Loc::loadMessages(__FILE__);
14 'limit_sites_google_analytics' => [
16 '\Bitrix\Landing\Restriction\Hook',
'isAllowed'
19 'limit_sites_powered_by' => [
21 '\Bitrix\Landing\Restriction\Hook',
'isAllowed'
24 'limit_sites_html_js' => [
26 '\Bitrix\Landing\Restriction\Hook',
'isAllowed'
29 'limit_sites_change_color_palette' => [
31 '\Bitrix\Landing\Restriction\Hook',
'isAllowed'
34 'limit_sites_access_permissions' => [
36 '\Bitrix\Landing\Restriction\Rights',
'isAllowed'
39 'limit_sites_transfer' => [
41 '\Bitrix\Landing\Restriction\Site',
'isExportAllowed'
44 'limit_free_domen' => [
46 '\Bitrix\Landing\Restriction\Site',
'isFreeDomainAllowed'
49 'limit_sites_number' => [
51 '\Bitrix\Landing\Restriction\Site',
'isCreatingAllowed'
54 'knowledge' =>
'limit_knowledge_base_number_page',
55 'group' =>
'limit_knowledge_base_number_page'
58 'limit_sites_number_page' => [
60 '\Bitrix\Landing\Restriction\Landing',
'isCreatingAllowed'
63 'knowledge' =>
'limit_knowledge_base_number_page',
64 'group' =>
'limit_knowledge_base_number_page'
67 'limit_knowledge_base_number_page' => [
69 '\Bitrix\Landing\Restriction\Site',
'isCreatingAllowed'
72 'limit_knowledge_base_number_page_view' => [
74 '\Bitrix\Landing\Restriction\Knowledge',
'isViewAllowed'
77 'limit_sites_dynamic_blocks' => [
79 '\Bitrix\Landing\Restriction\Block',
'isDynamicEnabled'
82 'limit_crm_superblock' => [
84 '\Bitrix\Landing\Restriction\Block',
'isDesignerAllowed'
87 'limit_crm_free_knowledge_base_project' => [
89 '\Bitrix\Landing\Restriction\Knowledge',
'isAllowedInGroup'
92 'limit_crm_forms_templates' => [
94 '\Bitrix\Landing\Restriction\Form',
'isMinisitesAllowed'
112 static $scopeId =
null;
114 if (isset(self::MAP[
$code]))
116 if ($scopeId ===
null)
120 $item = self::MAP[
$code];
121 $item[
'code'] = $item[
'scope_alias'][$scopeId] ??
$code;
134 if ($mapItem = self::getMapItem(
$code))
136 return 'top.BX.UI.InfoHelper.show("' . $mapItem[
'code'] .
'");';
147 static $included =
false;
152 if (SITE_TEMPLATE_ID !=
'bitrix24')
155 ->includeComponent(
'bitrix:ui.info.helper',
'', []);
168 if ($mapItem = self::getMapItem(
$code))
170 self::includeInformerComponent();
177 var nodes = ' . \CUtil::phpToJSObject($nodes) .
';
178 for (var i = 0, c = nodes.length; i < c; i++)
180 BX.bind(BX(nodes[i]), "click", function(e)
182 ' . self::getActionCode(
$code) .
'
183 BX.PreventDefault(e);
189 return $script .
'<span class="tariff-lock" id="' . $idCode .
'"></span>';
200 if ($mapItem = self::getMapItem(
$code))
202 return Loc::getMessage(
'LANDING_' . strtoupper($mapItem[
'code']));
204 return Loc::getMessage(
'LANDING_' . strtoupper(
$code));
218 isset(self::$tmpFeatures[
$code]) &&
219 self::$tmpFeatures[
$code]
225 $cacheCode =
$code . ($cacheSalt ?
'_' :
'') . $cacheSalt;
227 if (array_key_exists($cacheCode, $cache))
229 return $cache[$cacheCode];
232 if ($mapItem = self::getMapItem(
$code))
234 $cache[$cacheCode] = call_user_func_array($mapItem[
'check_callback'], [$mapItem[
'code'],
$params]);
235 return $cache[$cacheCode];
248 self::$tmpFeatures[$feature] =
true;
258 if (isset(self::$tmpFeatures[$feature]))
260 unset(self::$tmpFeatures[$feature]);
270 self::$tmpFeatures = [];
static disableAllFeaturesTmp()
static getLockIcon(?string $code, array $nodes=[])
static enableFeatureTmp($feature)
static isAllowed(string $code, array $params=[], string $cacheSalt='')
static getActionCode(string $code)
static getSystemErrorMessage($code)
static disableFeatureTmp($feature)
static includeInformerComponent()
static getMapItem(string $code)
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
if(!is_null($config))($config as $configItem)(! $configItem->isVisible()) $code
randString($pass_len=10, $pass_chars=false)
if($inWords) echo htmlspecialcharsbx(Number2Word_Rus(roundEx($totalVatSum $params['CURRENCY']