Documentation

Item

Controller class for processing REST and AJAX queries.


Inheritance chain

class Bitrix\Rpa\Controller\Item extends Bitrix\Rpa\Controller\Base

Methods

Methods for query processing are not described here, REST information about them can be found in this section.

However this class has several methods that are called from php, they are described below.

Method Description Available from version
public function prepareItemData(\Bitrix\Rpa\Model\Item $item, array $params = []): array Returns structure, similar to the response to rpa.item.get.
  • $item - Item object;
  • $params - set of boolean values for managing set of passed data:
    • $params['withTasks'] - true by default, the response will contain data on the number of tasks (tasksCounter) иand task participants (tasksFaces);
    • $params['withUsers'] - true by default, the response will contain data on users that had contact with element (users);
    • $params['withDisplay'] - false by default, the response will contain the key display with rendered user field values;
    • $params['withPermissions'] - false by default, the response will contain data on current user permissions (permissions).
public function prepareValue($value) Returns a user field value processed for use in Rest/Ajax.
public function getSortByPreviousItemId(\Bitrix\Rpa\Model\Item $item, int $userId, int $previousItemId = 0): int Returns sorting index for element $item for user $userId when moving it after $previousItemId.


© «Bitrix24», 2001-2024