Bitrix-D7
23.9
Загрузка...
Поиск...
Не найдено
restapplang.php
1
<?php
2
namespace
Bitrix\MessageService\Internal\Entity
;
3
4
use
Bitrix\Main
;
5
22
class
RestAppLangTable
extends
Main\Entity\DataManager
23
{
27
public
static
function
getTableName
()
28
{
29
return
'b_messageservice_rest_app_lang'
;
30
}
31
37
public
static
function
getMap
()
38
{
39
return
array(
40
'ID'
=> array(
41
'data_type'
=>
'integer'
,
42
'primary'
=>
true
,
43
'autocomplete'
=>
true
44
),
45
'APP_ID'
=> array(
46
'data_type'
=>
'integer'
,
47
'required'
=>
true
,
48
),
49
'LANGUAGE_ID'
=> array(
50
'data_type'
=>
'string'
,
51
'required'
=>
true
,
52
'validation'
=> array(__CLASS__,
'validateLanguageId'
),
53
),
54
'NAME'
=> array(
55
'data_type'
=>
'string'
,
56
'required'
=>
true
,
57
'validation'
=> array(__CLASS__,
'validateVarchar500'
),
58
),
59
'APP_NAME'
=> array(
60
'data_type'
=>
'string'
,
61
'validation'
=> array(__CLASS__,
'validateVarchar500'
),
62
),
63
'DESCRIPTION'
=> array(
64
'data_type'
=>
'string'
,
65
'validation'
=> array(__CLASS__,
'validateVarchar1000'
),
66
),
67
);
68
}
69
70
public
static
function
deleteByApp
($appId)
71
{
72
$connection = Main\Application::getConnection();
73
return
$connection->query(
"DELETE FROM "
.static::getTableName().
" WHERE APP_ID="
.(
int
)$appId);
74
}
75
79
public
static
function
validateVarchar500
()
80
{
81
return
array(
82
new
Main\
Entity
\
Validator
\Length(
null
, 500),
83
);
84
}
85
91
public
static
function
validateLanguageId
()
92
{
93
return
array(
94
new
Main\
Entity
\
Validator
\Length(
null
, 2),
95
);
96
}
97
101
public
static
function
validateVarchar1000
()
102
{
103
return
array(
104
new
Main\
Entity
\
Validator
\Length(
null
, 1000),
105
);
106
}
107
}
Bitrix\Bizproc\Validator
Definition
validator.php:9
Bitrix\Main\ORM\Entity
Definition
entity.php:26
Bitrix\MessageService\Internal\Entity\RestAppLangTable
Definition
restapplang.php:23
Bitrix\MessageService\Internal\Entity\RestAppLangTable\getMap
static getMap()
Definition
restapplang.php:37
Bitrix\MessageService\Internal\Entity\RestAppLangTable\validateLanguageId
static validateLanguageId()
Definition
restapplang.php:91
Bitrix\MessageService\Internal\Entity\RestAppLangTable\validateVarchar1000
static validateVarchar1000()
Definition
restapplang.php:101
Bitrix\MessageService\Internal\Entity\RestAppLangTable\deleteByApp
static deleteByApp($appId)
Definition
restapplang.php:70
Bitrix\MessageService\Internal\Entity\RestAppLangTable\validateVarchar500
static validateVarchar500()
Definition
restapplang.php:79
Bitrix\MessageService\Internal\Entity\RestAppLangTable\getTableName
static getTableName()
Definition
restapplang.php:27
Bitrix\Main
Bitrix\MessageService\Internal\Entity
Definition
channeltable.php:2
modules
messageservice
lib
internal
entity
restapplang.php
Создано системой
1.10.0