• Модуль: bizproc
  • Путь к файлу: ~/bitrix/modules/bizproc/lib/restservice.php
  • Класс: BitrixBizprocRestService
  • Вызов: RestService::checkStartWorkflowPermissions
static function checkStartWorkflowPermissions(array $documentId, $templateId)
{
	if (static::isAdmin())
	{
		return true;
	}

	if (
		CBPDocument::CanUserOperateDocument(
			CBPCanUserOperateOperation::StartWorkflow,
			static::getCurrentUserId(),
			$documentId,
			['WorkflowTemplateId' => $templateId]
		)
	)
	{
		return true;
	}

	throw new AccessException();
}