...Человеческий поиск в разработке...
- Модуль: crm
- Путь к файлу: ~/bitrix/modules/crm/classes/general/crm_activity.php
- Класс: \CAllCrmActivity
- Вызов: CAllCrmActivity::CheckItemUpdatePermission
static function CheckItemUpdatePermission(array $fields, $userPermissions = null) { $ID = isset($fields['ID']) ? (int)$fields['ID'] : 0; if($ID <= 0) { return false; } $bindings = self::GetBindings($ID); if(is_array($bindings) && !empty($bindings)) { foreach($bindings as &$binding) { if(self::CheckUpdatePermission($binding['OWNER_TYPE_ID'], $binding['OWNER_ID'], $userPermissions)) { return true; } } unset($binding); return false; } $ownerTypeID = isset($fields['OWNER_TYPE_ID']) ? (int)$fields['OWNER_TYPE_ID'] : CCrmOwnerType::Undefined; $ownerID = isset($fields['OWNER_ID']) ? (int)$fields['OWNER_ID'] : 0; return $ownerID > 0 && CCrmOwnerType::IsDefined($ownerTypeID) && self::CheckUpdatePermission($ownerTypeID, $ownerID, $userPermissions); }