1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
sharinglinktable.php
См. документацию.
1<?php
2namespace Bitrix\Calendar\Internals;
3
4use Bitrix\Main\Entity\ReferenceField;
5use Bitrix\Main\Entity\TextField;
6use Bitrix\Main\ORM\Data\DataManager;
7use Bitrix\Main\ORM\Fields\BooleanField;
8use Bitrix\Main\ORM\Fields\DatetimeField;
9use Bitrix\Main\ORM\Fields\IntegerField;
10use Bitrix\Main\ORM\Fields\Relations\OneToMany;
11use Bitrix\Main\ORM\Fields\Relations\Reference;
12use Bitrix\Main\ORM\Fields\StringField;
13use Bitrix\Main\ORM\Fields\Validators\LengthValidator;
14use Bitrix\Main\ORM\Query\Join;
15
53
55{
61 public static function getTableName()
62 {
63 return 'b_calendar_sharing_link';
64 }
65
71 public static function getMap()
72 {
73 return [
74 (new IntegerField('ID',
75 []
76 ))
77 ->configurePrimary(true)
78 ->configureAutocomplete(true)
79 ,
80 (new IntegerField('OBJECT_ID',
81 []
82 ))
83 ->configureRequired(true)
84 ,
85 (new StringField('OBJECT_TYPE',
86 [
87 'validation' => [__CLASS__, 'validateObjectType']
88 ]
89 ))
90 ->configureRequired(true)
91 ,
92 (new StringField('HASH',
93 [
94 'validation' => [__CLASS__, 'validateHash']
95 ]
96 ))
97 ->configureRequired(true)
98 ,
99 (new TextField('OPTIONS',
100 []
101 ))
102 ,
103 (new BooleanField('ACTIVE',
104 []
105 ))
106 ->configureValues('N', 'Y')
107 ->configureDefaultValue('Y')
108 ,
109 (new DatetimeField('DATE_CREATE',
110 []
111 ))
112 ->configureRequired(true)
113 ,
114 (new DatetimeField('DATE_EXPIRE',
115 []
116 ))
117 ,
118 (new IntegerField('HOST_ID',
119 []
120 ))
121 ,
122 (new IntegerField('OWNER_ID',
123 []
124 ))
125 ,
126 (new StringField('CONFERENCE_ID',
127 [
128 'validation' => [__CLASS__, 'validateConferenceId']
129 ]
130 ))
131 ,
132 (new StringField('PARENT_LINK_HASH',
133 [
134 'validation' => [__CLASS__, 'validateParentLinkHash']
135 ]
136 ))
137 ,
138 (new IntegerField('CONTACT_ID',
139 []
140 ))
141 ->configureNullable()
142 ,
143 (new IntegerField('CONTACT_TYPE',
144 []
145 ))
146 ->configureNullable()
147 ,
148 (new StringField('MEMBERS_HASH',
149 [
150 'validation' => [__CLASS__, 'validateMembersHash']
151 ]
152 ))
153 ->configureNullable()
154 ,
155 (new IntegerField('FREQUENT_USE',
156 []
157 ))
158 ,
159 (new OneToMany(
160 'MEMBERS',
161 SharingLinkMemberTable::class,
162 'MEMBER',
163 ))
164 ->configureJoinType(Join::TYPE_LEFT),
165 ];
166 }
167
173 public static function validateObjectType(): array
174 {
175 return [
176 new LengthValidator(null, 32),
177 ];
178 }
179
185 public static function validateHash(): array
186 {
187 return [
188 new LengthValidator(null, 64),
189 ];
190 }
191
197 public static function validateConferenceId(): array
198 {
199 return [
200 new LengthValidator(null, 64),
201 ];
202 }
203
209 public static function validateParentLinkHash(): array
210 {
211 return [
212 new LengthValidator(null, 64),
213 ];
214 }
215
221 public static function validateMembersHash(): array
222 {
223 return [
224 new LengthValidator(null, 64),
225 ];
226 }
227
228}
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
Определения file_new.php:804