• Модуль: tasks
  • Путь к файлу: ~/bitrix/modules/tasks/lib/scrum/controllers/sprint.php
  • Класс: BitrixTasksScrumControllersSprint
  • Вызов: Sprint::processBeforeAction
protected function processBeforeAction(Action $action)
{
	if (!Loader::includeModule('socialnetwork'))
	{
		$this->errorCollection->setError(
			new Error(
				Loc::getMessage('TSSC_ERROR_INCLUDE_MODULE_ERROR'),
				self::ERROR_COULD_NOT_LOAD_MODULE
			)
		);

		return false;
	}

	$post = $this->request->getPostList()->toArray();

	$groupId = (is_numeric($post['groupId']) ? (int) $post['groupId'] : 0);
	$userId = User::getId();

	if (!$this->canReadGroupTasks($userId, $groupId))
	{
		$this->errorCollection->setError(
			new Error(
				Loc::getMessage('TSSC_ERROR_ACCESS_DENIED'),
				self::ERROR_ACCESS_DENIED
			)
		);

		return false;
	}

	return parent::processBeforeAction($action);
}