Bitrix-D7
23.9
Загрузка...
Поиск...
Не найдено
optionstatetable.php
1
<?php
2
3
namespace
Bitrix\Im\Model
;
4
5
use
Bitrix\Main\ArgumentTypeException
,
6
Bitrix\Main\ORM\Data\DataManager
,
7
Bitrix\Main\ORM\Fields\IntegerField
,
8
Bitrix\Main\ORM\Fields\StringField
,
9
Bitrix\Main\ORM\Fields\Validators\LengthValidator
,
10
Bitrix\Main\SystemException
;
11
12
26
class
OptionStateTable
extends
DataManager
27
{
33
public
static
function
getTableName
(): string
34
{
35
return
'b_im_option_state'
;
36
}
37
44
public
static
function
getMap
(): array
45
{
46
return
[
47
'GROUP_ID'
=> (
new
IntegerField
(
'GROUP_ID'
, [
48
'primary'
=>
true
,
49
])),
50
'NAME'
=> (
new
StringField
(
'NAME'
, [
51
'primary'
=>
true
,
52
'validation'
=> [__CLASS__,
'validateName'
],
53
])),
54
'VALUE'
=> (
new
StringField
(
'VALUE'
, [
55
'validation'
=> [__CLASS__,
'validateValue'
]
56
])),
57
];
58
}
59
66
public
static
function
validateName
(): array
67
{
68
return
[
69
new
LengthValidator
(
null
, 64),
70
];
71
}
72
79
public
static
function
validateValue
(): array
80
{
81
return
[
82
new
LengthValidator
(
null
, 255),
83
];
84
}
85
}
Bitrix\Im\Model\OptionStateTable
Definition
optionstatetable.php:27
Bitrix\Im\Model\OptionStateTable\getMap
static getMap()
Definition
optionstatetable.php:44
Bitrix\Im\Model\OptionStateTable\validateValue
static validateValue()
Definition
optionstatetable.php:79
Bitrix\Im\Model\OptionStateTable\validateName
static validateName()
Definition
optionstatetable.php:66
Bitrix\Im\Model\OptionStateTable\getTableName
static getTableName()
Definition
optionstatetable.php:33
Bitrix\Main\ArgumentTypeException
Definition
exception.php:114
Bitrix\Main\ORM\Data\DataManager
Definition
datamanager.php:33
Bitrix\Main\ORM\Fields\IntegerField
Definition
integerfield.php:20
Bitrix\Main\ORM\Fields\StringField
Definition
stringfield.php:20
Bitrix\Main\ORM\Fields\Validators\LengthValidator
Definition
lengthvalidator.php:19
Bitrix\Main\SystemException
Definition
exception.php:8
Bitrix\Im\Model
Definition
alias.php:2
modules
im
lib
model
optionstatetable.php
Создано системой
1.10.0