• Модуль: tasks
  • Путь к файлу: ~/bitrix/modules/tasks/lib/comments/task/commentposter.php
  • Класс: BitrixTasksCommentsTaskCommentPoster
  • Вызов: CommentPoster::prepareTaskExpiredCommentLiveParams
private function prepareTaskExpiredCommentLiveParams(array $taskData): array
{
	$taskId = (int)$taskData['ID'];
	$deadline = (TaskRegistry::getInstance())->get($taskId)['DEADLINE'];
	$users = array_unique(
		array_merge(
			$this->getTaskMembers($taskData),
			$this->getTaskWatchers($taskId)
		)
	);

	return [
		'LIVE_DATA' => [
			'TASK_ID' => $taskId,
			'EFFICIENCY_MEMBERS' => $this->getMembersForExpiredMessages($taskData),
			'DEADLINE' => ($deadline ? $deadline->getTimestamp() : null),
			'RIGHTS' => [
				'TASK_COMPLETE' => $this->getTaskUsersRight(
					$taskId,
					$users,
					AccessActionDictionary::ACTION_TASK_COMPLETE
				),
				'DEADLINE_CHANGE' => $this->getTaskUsersRight(
					$taskId,
					$users,
					AccessActionDictionary::ACTION_TASK_DEADLINE
				),
			],
		],
	];
}