1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
userprofilerecord.php
См. документацию.
1<?php
8
9namespace Bitrix\Main;
10
29class UserProfileRecordTable extends Entity\DataManager
30{
31 public static function getTableName()
32 {
33 return 'b_user_profile_record';
34 }
35
36 public static function getMap()
37 {
38 return array(
39 new Entity\IntegerField("ID", array(
40 'primary' => true,
41 'autocomplete' => true,
42 )),
43 new Entity\IntegerField("HISTORY_ID", array(
44 'required' => true,
45 )),
46 new Entity\StringField("FIELD"),
47 new Entity\TextField('DATA', array(
48 'serialized' => true
49 )),
50 new Entity\ReferenceField("HISTORY",
51 '\Bitrix\Main\UserProfileHistoryTable',
52 array('=this.HISTORY_ID' => 'ref.ID'),
53 array('join_type' => 'INNER')
54 ),
55 );
56 }
57
58 public static function deleteByHistoryFilter($where)
59 {
60 if ($where == '')
61 {
62 throw new ArgumentException("Deleting by empty filter is not allowed, use truncate (b_user_profile_record).", "where");
63 }
64
65 $entity = static::getEntity();
66 $conn = $entity->getConnection();
67
68 $alias = ($conn instanceof DB\MysqlCommonConnection ? 'R' : '');
69
70 $conn->queryExecute("
71 DELETE {$alias} FROM b_user_profile_record R
72 WHERE R.HISTORY_ID IN(
73 SELECT ID FROM b_user_profile_history
74 {$where}
75 )
76 ");
77
78 $entity->cleanCache();
79 }
80}
static deleteByHistoryFilter($where)
Определения userprofilerecord.php:58
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
Определения file_new.php:804
$entity
Определения ufield.php:9