Bitrix-D7
23.9
Загрузка...
Поиск...
Не найдено
messageviewed.php
1
<?php
2
namespace
Bitrix\Im\Model
;
3
4
use Bitrix\Im\V2\Common\InsertSelectTrait;
5
use Bitrix\Im\V2\Common\MultiplyInsertTrait;
6
use
Bitrix\Main\ORM\Data\DataManager
;
7
use Bitrix\Main\ORM\Data\Internal\DeleteByFilterTrait;
8
use Bitrix\Main\ORM\Data\Internal\MergeTrait;
9
use
Bitrix\Main\ORM\Fields\DatetimeField
;
10
use
Bitrix\Main\ORM\Fields\IntegerField
;
11
use
Bitrix\Main\ORM\Fields\StringField
;
12
use
Bitrix\Main\ORM\Fields\Validators\LengthValidator
;
13
use
Bitrix\Main\Type\DateTime
;
14
44
class
MessageViewedTable
extends
DataManager
45
{
46
use MultiplyInsertTrait;
47
use MergeTrait;
48
use InsertSelectTrait;
49
use DeleteByFilterTrait;
50
56
public
static
function
getTableName
()
57
{
58
return
'b_im_message_viewed'
;
59
}
60
66
public
static
function
getMap
()
67
{
68
return
[
69
'ID'
=>
new
IntegerField
(
70
'ID'
,
71
[
72
'primary'
=>
true
,
73
'autocomplete'
=>
true
,
74
]
75
),
76
'USER_ID'
=>
new
IntegerField
(
77
'USER_ID'
,
78
[
79
'required'
=>
true
,
80
]
81
),
82
'CHAT_ID'
=>
new
IntegerField
(
83
'CHAT_ID'
,
84
[
85
'required'
=>
true
,
86
]
87
),
88
'MESSAGE_ID'
=>
new
IntegerField
(
89
'MESSAGE_ID'
,
90
[
91
'required'
=>
true
,
92
]
93
),
94
'DATE_CREATE'
=>
new
DatetimeField
(
95
'DATE_CREATE'
,
96
[
97
'default'
=>
function
()
98
{
99
return
new
DateTime
();
100
},
101
]
102
),
103
];
104
}
105
111
public
static
function
validateReaction
(): array
112
{
113
return
[
114
new
LengthValidator
(
null
, 50),
115
];
116
}
117
}
Bitrix\Im\Model\MessageViewedTable
Definition
messageviewed.php:45
Bitrix\Im\Model\MessageViewedTable\getMap
static getMap()
Definition
messageviewed.php:66
Bitrix\Im\Model\MessageViewedTable\validateReaction
static validateReaction()
Definition
messageviewed.php:111
Bitrix\Im\Model\MessageViewedTable\getTableName
static getTableName()
Definition
messageviewed.php:56
Bitrix\Main\ORM\Data\DataManager
Definition
datamanager.php:33
Bitrix\Main\ORM\Fields\DatetimeField
Definition
datetimefield.php:22
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\Type\DateTime
Definition
datetime.php:9
Bitrix\Im\Model
Definition
alias.php:2
modules
im
lib
model
messageviewed.php
Создано системой
1.10.0