3namespace Bitrix\Socialnetwork\Internals\EventService\Recepients;
5use Bitrix\Main\DB\SqlExpression;
6use Bitrix\Main\ORM\Query\Query;
7use Bitrix\Main\UserAccessTable;
8use Bitrix\Main\UserTable;
9use Bitrix\Socialnetwork\Item\LogRight;
13 private int $sonetLogId;
14 private ?
array $logRights =
null;
18 $this->sonetLogId = $sonetLogId;
19 $this->logRights = $logRights;
24 $accessCodes = (is_array($this->logRights) && !empty($this->logRights))
31 $query = in_array(
'AU', $accessCodes,
true)
32 ? $this->getAllAuthorisedQuery($limit, $offset)
33 : $this->getAllByAccessCodeQuery($limit, $offset, $accessCodes)
39 $isOnline = (
$user[
'IS_ONLINE'] ??
'Y') ===
'Y';
48 return UserTable::query()
50 ->setSelect([
'ID',
'ACTIVE',
'IS_REAL_USER',
'UF_DEPARTMENT',
'IS_ONLINE'])
51 ->where(
'ACTIVE',
'=',
'Y')
52 ->where(
'REAL_USER',
'expr',
true)
53 ->where(
'UF_DEPARTMENT',
'!=',
false)
61 $subQuery = (
new Query(UserAccessTable::getEntity()));
62 $subQuery->setSelect([
'USER_ID']);
63 $subQuery->whereIn(
'ACCESS_CODE', $accessCodes);
65 return UserTable::query()
74 ->where(
'ACTIVE',
'=',
'Y')
75 ->where(
'REAL_USER',
'expr',
true)
76 ->where(
'UF_DEPARTMENT',
'!=',
false)
if(!is_object($USER)||! $USER->IsAuthorized()) $userId
__construct(int $sonetLogId, ?array $logRights)
fetch(int $limit, int $offset)
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)