Bitrix-D7 23.9
 
Загрузка...
Поиск...
Не найдено
log.php
1<?php
2namespace Bitrix\Im\Model;
3
4use Bitrix\Im\V2\Common\MultiplyInsertTrait;
7use Bitrix\Main\ORM\Data\Internal\DeleteByFilterTrait;
8use Bitrix\Main\ORM\Data\Internal\MergeTrait;
14
44class LogTable extends DataManager
45{
46 use MergeTrait;
47 use MultiplyInsertTrait;
48 use DeleteByFilterTrait;
49
55 public static function getTableName()
56 {
57 return 'b_im_log';
58 }
59
65 public static function getMap()
66 {
67 return [
68 'ID' => new IntegerField(
69 'ID',
70 [
71 'primary' => true,
72 'autocomplete' => true,
73 ]
74 ),
75 'USER_ID' => new IntegerField(
76 'USER_ID',
77 [
78 'required' => true,
79 ]
80 ),
81 'ENTITY_TYPE' => new StringField(
82 'ENTITY_TYPE',
83 [
84 'validation' => function()
85 {
86 return[
87 new LengthValidator(null, 50),
88 ];
89 },
90 ]
91 ),
92 'ENTITY_ID' => new IntegerField(
93 'ENTITY_ID',
94 [
95 ]
96 ),
97 'EVENT' => new StringField(
98 'EVENT',
99 [
100 'required' => true,
101 'validation' => function()
102 {
103 return[
104 new LengthValidator(null, 50),
105 ];
106 },
107 ]
108 ),
109 'DATE_CREATE' => new DatetimeField(
110 'DATE_CREATE',
111 [
112 'required' => true,
113 'default_value' => static function() {
114 return new DateTime();
115 }
116 ]
117 ),
118 'DATE_DELETE' => new DatetimeField(
119 'DATE_DELETE',
120 [
121 ]
122 ),
123 ];
124 }
125}
static getTableName()
Definition log.php:55