1C-Bitrix
25.700.0
Загрузка...
Поиск...
Не найдено
RelationChangeSet.php
См. документацию.
1
<?php
2
3
declare(strict_types=1);
4
5
namespace
Bitrix\Im\V2\Relation;
6
7
class
RelationChangeSet
8
{
9
private
array
$newRelations = [];
10
private
array
$newMembers = [];
11
12
public
function
addNewRelation
(
int
$userId
,
bool
$isHidden): void
13
{
14
$this->newRelations[
$userId
] =
$userId
;
15
if
(!$isHidden)
16
{
17
$this->newMembers[
$userId
] =
$userId
;
18
}
19
}
20
21
public
function
addNewMembers
(
int
$userId
): void
22
{
23
$this->newMembers[
$userId
] =
$userId
;
24
}
25
26
public
function
getNewRelations
():
array
27
{
28
return
$this->newRelations;
29
}
30
31
public
function
getNewMembers
():
array
32
{
33
return
$this->newMembers;
34
}
35
36
public
function
getAll
():
array
37
{
38
return
array_unique(array_merge($this->newRelations, $this->newMembers));
39
}
40
41
public
function
isEmpty
(): bool
42
{
43
return
empty($this->newRelations) && empty($this->newMembers);
44
}
45
}
$userId
if(!is_object($USER)||! $USER->IsAuthorized()) $userId
Определения
check_mail.php:18
Bitrix\Im\V2\Relation\RelationChangeSet
Определения
RelationChangeSet.php:8
Bitrix\Im\V2\Relation\RelationChangeSet\getNewMembers
getNewMembers()
Определения
RelationChangeSet.php:31
Bitrix\Im\V2\Relation\RelationChangeSet\addNewMembers
addNewMembers(int $userId)
Определения
RelationChangeSet.php:21
Bitrix\Im\V2\Relation\RelationChangeSet\getNewRelations
getNewRelations()
Определения
RelationChangeSet.php:26
Bitrix\Im\V2\Relation\RelationChangeSet\addNewRelation
addNewRelation(int $userId, bool $isHidden)
Определения
RelationChangeSet.php:12
Bitrix\Im\V2\Relation\RelationChangeSet\getAll
getAll()
Определения
RelationChangeSet.php:36
Bitrix\Im\V2\Relation\RelationChangeSet\isEmpty
isEmpty()
Определения
RelationChangeSet.php:41
array
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
Определения
file_new.php:804
bitrix
modules
im
lib
V2
Relation
RelationChangeSet.php
Создано системой
1.14.0