3namespace Bitrix\Im\V2\Chat;
7use Bitrix\Im\Access\ChatAuthProvider;
8use Bitrix\Im\V2\Chat\Collab\CollabInfo;
9use Bitrix\Im\V2\Chat\Collab\GuestCounter;
10use Bitrix\Im\V2\Entity\User\User;
11use Bitrix\Im\V2\Entity\User\UserCollaber;
12use Bitrix\Im\V2\Integration\Socialnetwork\Group;
13use Bitrix\Im\V2\Permission\Action;
14use Bitrix\Im\V2\Permission\ActionGroup;
15use Bitrix\Im\V2\Relation\DeleteUserConfig;
16use Bitrix\Im\V2\RelationCollection;
17use Bitrix\Im\V2\Recent\Initializer;
18use Bitrix\Im\V2\Rest\PopupData;
19use Bitrix\Im\V2\Result;
25 private const UNAVAILABLE_ACTION_GROUPS = [
26 ActionGroup::ManageUi,
27 ActionGroup::ManageSettings,
28 ActionGroup::ManageUsersDelete,
29 ActionGroup::ManageUsersAdd
31 private const UNAVAILABLE_ACTIONS = [
40 return self::IM_TYPE_COLLAB;
45 if (!isset(
$params[
'ENTITY_ID']))
50 $params[
'ENTITY_TYPE'] = ExtendedType::Sonet->value;
52 return parent::prepareParams(
$params);
57 return parent::getPopupData($excludedList)->
add(
new CollabInfo($this));
62 return Group::getStorageId((
int)$this->getEntityId()) ?? 0;
73 $folder =
$storage->getFolderForUploadedFiles();
79 $this->setDiskFolderId($folder->getId())->save();
80 Driver::getInstance()->getRightsManager()->append($folder, $this->getAccessCodesForDiskFolder());
89 if (in_array(
$action, self::UNAVAILABLE_ACTIONS,
true))
94 $actionGroup = ActionGroup::tryFromAction(
$action);
96 if (in_array($actionGroup, self::UNAVAILABLE_ACTION_GROUPS,
true))
101 return parent::canDo(
$action, $target);
106 Initializer::onAfterUsersAddToCollab($usersToAdd, $this->getId());
113 return parent::updateStateAfterRelationsAdd($usersToAdd);
123 return parent::updateStateAfterUserDelete($deletedUserId,
$config);
133 parent::sendPushUsersAdd($usersToAdd, $oldRelations);
143 parent::sendPushUserDelete(
$userId, $oldRelations);
if(!is_object($USER)||! $USER->IsAuthorized()) $userId
updateChatCodesByRelations(int $chatId)
static cleanCache(int $chatId)
sendPushUserDelete(int $userId, RelationCollection $oldRelations)
updateStateAfterRelationsAdd(array $usersToAdd)
needToSendMessageUserDelete()
getPopupData(array $excludedList=[])
const EXTRANET_CAN_SEE_HISTORY
prepareParams(array $params=[])
filterCollabers(array $userIds)
sendPushUsersAdd(array $usersToAdd, RelationCollection $oldRelations)
updateStateAfterUserDelete(int $deletedUserId, DeleteUserConfig $config)
canDo(Action $action, mixed $target=null)
static GetStorage(?int $chatId=null)
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
if(empty($decryptedData)) $storage
if($inWords) echo htmlspecialcharsbx(Number2Word_Rus(roundEx($totalVatSum $params['CURRENCY']