Bitrix-D7 23.9
 
Загрузка...
Поиск...
Не найдено
channel.php
1<?php
2
4
6
7final class Channel implements Fields\IField
8{
9 const CHANNEL_COMMERCE_OFFSITE = "COMMERCE_OFFSITE";
10 const CHANNEL_MARKETPLACE = "MARKETPLACE";
11 const CHANNEL_COMMERCE = "COMMERCE";
12 const CHANNEL_SIGNALS = "SIGNALS";
13 const CHANNEL_FEED = "FEED";
14
18 static function getDefaultValue()
19 {
20 return null;
21 }
22
29 static function checkValue($value): bool
30 {
31 return is_string($value) && in_array($value,[
32 static::CHANNEL_COMMERCE,
33 static::CHANNEL_COMMERCE_OFFSITE,
34 static::CHANNEL_FEED,
35 static::CHANNEL_MARKETPLACE,
36 static::CHANNEL_SIGNALS
37 ]);
38
39 }
40
44 static function available(): bool
45 {
46 return false;
47 }
48
52 static function required(): bool
53 {
54 return false;
55 }
56}