1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
CollabLogTable.php
См. документацию.
1<?php
2namespace Bitrix\Socialnetwork\Collab\Internals;
3
4use Bitrix\Main\ORM\Data\DataManager;
5use Bitrix\Main\ORM\Fields\ArrayField;
6use Bitrix\Main\ORM\Fields\DatetimeField;
7use Bitrix\Main\ORM\Fields\IntegerField;
8use Bitrix\Main\ORM\Fields\StringField;
9use Bitrix\Main\ORM\Fields\Validators\LengthValidator;
10
41
43{
49 public static function getTableName()
50 {
51 return 'b_sonet_collab_log';
52 }
53
59 public static function getMap()
60 {
61 $lengthValidator = function()
62 {
63 return [
64 new LengthValidator(null, 255),
65 ];
66 };
67
68 return [
69 (new IntegerField('ID'))
70 ->configurePrimary()
71 ->configureAutocomplete()
72 ,
73 (new IntegerField('COLLAB_ID'))
74 ->configureRequired()
75 ,
76 (new DatetimeField('DATETIME'))
77 ->configureRequired()
78 ,
79 (new StringField('TYPE', ['validation' => $lengthValidator]))
80 ,
81 (new IntegerField('USER_ID'))
82 ->configureRequired()
83 ,
84 (new StringField('ENTITY_TYPE', ['validation' => $lengthValidator]))
85 ,
86 (new IntegerField('ENTITY_ID'))
87 ,
88 (new ArrayField('DATA'))
89 ->configureSerializationJson()
90 ,
91 ];
92 }
93}