PHP Класс Bitrix24\Task\Item

Наследование: extends Bitrix24\Bitrix24Entity
Показать файл Открыть проект

Открытые методы

Метод Описание
add ( array $taskData ) : array add new task
approve ( $taskId ) : array Change status of task waiting for confirmation to Completed.
complete ( $taskId ) : array Change status to Completed or Supposedly completed (requires creator's attention).
defer ( $taskId ) : array Change task status to Deferred
delegate ( $taskId, $userId ) : array Delegate task to a user.
delete ( $taskId ) : array Delete task.
disapprove ( $taskId ) : array Change status of task waiting for confirmation to Pending.
getAllowedActions ( $taskId ) : array Return array of allowed task actions IDs (see PHP class constants CTaskItem).
getAllowedTaskActionsAsStrings ( $taskId ) : array Return an array whose keys are acton names (the names correspond to PHP class constants CTaskItem) and values show whether the action is allowed (true) or not allowed (false).
getData ( $taskId ) : array Return array of task data fields (TITLE, DESCRIPTION, etc.)
getDependSon ( $taskId ) : array Return array with parent task IDs
getDescription ( $taskId, $format ) : array Return task description.
getFiles ( $taskId ) : array Return array of links to files attached to the task.
getManifest ( ) : array get all methods and fields of B24 entity CTaskItem. Only for information!
isActionAllowed ( $taskId, $actionId ) : array Return true if action is allowed, else returns false.
renew ( $taskId ) : array Change status to Pending.
startExecution ( $taskId ) : array Change task status to In Progress
update ( $taskId, $taskData ) : array Update task data. The following fields may be updated. Business logic and permissions are taken into account when updating task data.

Описание методов

add() публичный Метод

add new task
public add ( array $taskData ) : array
$taskData array
Результат array new task ID

approve() публичный Метод

Change status of task waiting for confirmation to Completed.
public approve ( $taskId ) : array
$taskId integer Task ID
Результат array

complete() публичный Метод

Change status to Completed or Supposedly completed (requires creator's attention).
public complete ( $taskId ) : array
$taskId integer Task ID
Результат array

defer() публичный Метод

Change task status to Deferred
public defer ( $taskId ) : array
$taskId integer Task ID
Результат array

delegate() публичный Метод

Delegate task to a user.
public delegate ( $taskId, $userId ) : array
$taskId integer Task ID
$userId integer New responsible person ID
Результат array

delete() публичный Метод

Delete task.
public delete ( $taskId ) : array
$taskId integer Task ID.
Результат array

disapprove() публичный Метод

Change status of task waiting for confirmation to Pending.
public disapprove ( $taskId ) : array
$taskId integer Task ID
Результат array

getAllowedActions() публичный Метод

Return array of allowed task actions IDs (see PHP class constants CTaskItem).
public getAllowedActions ( $taskId ) : array
$taskId integer Task ID.
Результат array

getAllowedTaskActionsAsStrings() публичный Метод

Return an array whose keys are acton names (the names correspond to PHP class constants CTaskItem) and values show whether the action is allowed (true) or not allowed (false).
public getAllowedTaskActionsAsStrings ( $taskId ) : array
$taskId integer Task ID.
Результат array

getData() публичный Метод

Return array of task data fields (TITLE, DESCRIPTION, etc.)
public getData ( $taskId ) : array
$taskId
Результат array

getDependSon() публичный Метод

Return array with parent task IDs
public getDependSon ( $taskId ) : array
$taskId integer Task ID.
Результат array

getDescription() публичный Метод

Return task description.
public getDescription ( $taskId, $format ) : array
$taskId integer Task ID.
$format integer 1 (Corresponds to the PHP constant CTaskItem::DESCR_FORMAT_RAW) � description will be returned in the format it is stored in the database (HTML or BB-code), will not be sanitized; 2 (Corresponds to the PHP constant CTaskItem::DESCR_FORMAT_HTML) � description will be returned in HTML, will first be sanitized (if included in task module settings); 3 (Corresponds to the PHP constant CTaskItem::DESCR_FORMAT_PLAIN_TEXT) � description will be returned as plain text (no HTML tags).
Результат array

getFiles() публичный Метод

Return array of links to files attached to the task.
public getFiles ( $taskId ) : array
$taskId integer Task ID.
Результат array

getManifest() публичный Метод

get all methods and fields of B24 entity CTaskItem. Only for information!
public getManifest ( ) : array
Результат array

isActionAllowed() публичный Метод

Return true if action is allowed, else returns false.
public isActionAllowed ( $taskId, $actionId ) : array
$taskId integer Task ID.
$actionId integer Validated action ID (see CTaskItem::ACTION_* constants of PHP class CTaskItem).
Результат array

renew() публичный Метод

Change status to Pending.
public renew ( $taskId ) : array
$taskId integer Task ID
Результат array

startExecution() публичный Метод

Change task status to In Progress
public startExecution ( $taskId ) : array
$taskId integer Task ID
Результат array

update() публичный Метод

Update task data. The following fields may be updated. Business logic and permissions are taken into account when updating task data.
public update ( $taskId, $taskData ) : array
$taskId integer Task ID.
$taskData array List of updated fields.
Результат array