Bitrix API

UserOption

Class UserOption

Table of Contents

Constants

REMOVE_ON_USER_ROLE_CHANGED  = [\Bitrix\Tasks\Internals\UserOption\Option::MUTED]

Properties

$cache  : mixed

Methods

add()  : Result
delete()  : Result
deleteByTaskId()  : void
deleteByTaskIdAndUserId()  : void
deleteByUserId()  : void
deleteOnUserRoleChanged()  : void
Removes necessary options when changing the user's role in a task
getAllowedOptions()  : array<string|int, mixed>
getFilterSql()  : string
getOptions()  : array<string|int, mixed>
getSelectSql()  : string
isOption()  : bool
isOptionSet()  : bool
onBeforeOptionChanged()  : void
onOptionChanged()  : void

Constants

REMOVE_ON_USER_ROLE_CHANGED

public mixed REMOVE_ON_USER_ROLE_CHANGED = [\Bitrix\Tasks\Internals\UserOption\Option::MUTED]

Properties

Methods

add()

public static add(int $taskId, int $userId, int $option) : Result
Parameters
$taskId : int
$userId : int
$option : int
Tags
throws
ArgumentException
throws
ObjectPropertyException
throws
SystemException
throws
Exception
Return values
Result

delete()

public static delete(int $taskId, int $userId, int $option) : Result
Parameters
$taskId : int
$userId : int
$option : int
Tags
throws
ArgumentException
throws
ObjectPropertyException
throws
SystemException
throws
Exception
Return values
Result

deleteByTaskId()

public static deleteByTaskId(int $taskId) : void
Parameters
$taskId : int
Tags
throws
SqlQueryException

deleteByTaskIdAndUserId()

public static deleteByTaskIdAndUserId(int $taskId, int $userId) : void
Parameters
$taskId : int
$userId : int
Tags
throws
SqlQueryException

deleteByUserId()

public static deleteByUserId(int $userId) : void
Parameters
$userId : int
Tags
throws
SqlQueryException

deleteOnUserRoleChanged()

Removes necessary options when changing the user's role in a task

public static deleteOnUserRoleChanged(int $taskId, int $userId) : void
Parameters
$taskId : int
$userId : int

getAllowedOptions()

public static getAllowedOptions() : array<string|int, mixed>
Return values
array<string|int, mixed>

getFilterSql()

public static getFilterSql(int $userId, int $option[, string $aliasPrefix = '' ]) : string
Parameters
$userId : int
$option : int
$aliasPrefix : string = ''
Return values
string

getOptions()

public static getOptions(int $taskId, int $userId) : array<string|int, mixed>
Parameters
$taskId : int
$userId : int
Tags
throws
ArgumentException
throws
ObjectPropertyException
throws
SystemException
Return values
array<string|int, mixed>

getSelectSql()

public static getSelectSql(int $userId, int $option) : string
Parameters
$userId : int
$option : int
Return values
string

isOption()

public static isOption(int $option) : bool
Parameters
$option : int
Return values
bool

isOptionSet()

public static isOptionSet(int $taskId, int $userId, int $option) : bool
Parameters
$taskId : int
$userId : int
$option : int
Tags
throws
ArgumentException
throws
ObjectPropertyException
throws
SystemException
Return values
bool

onBeforeOptionChanged()

public static onBeforeOptionChanged(int $taskId, int $userId, int $option) : void
Parameters
$taskId : int
$userId : int
$option : int

onOptionChanged()

public static onOptionChanged(int $taskId, int $userId, int $option, bool $added) : void
Parameters
$taskId : int
$userId : int
$option : int
$added : bool
Tags
throws
ArgumentException
throws
SqlQueryException
throws
LoaderException
throws
ObjectPropertyException
throws
SystemException

        
On this page

Search results