CBPDocumentService::onWorkflowStatusChange

  1. Bitrix24 API (v. 23.675.0)
  2. bizproc
  3. CBPDocumentService
  4. onWorkflowStatusChange
  • Модуль: bizproc
  • Путь к файлу: ~/bitrix/modules/bizproc/classes/general/documentservice.php
  • Класс: CBPDocumentService
  • Вызов: CBPDocumentService::onWorkflowStatusChange
public function onWorkflowStatusChange($parameterDocumentId, $workflowId, $status, $rootActivity = null)
{
	[$moduleId, $entity, $documentId] = CBPHelper::ParseDocumentId($parameterDocumentId);

	if (
		$rootActivity
		&& $rootActivity->workflow->isNew()
		&& $status === CBPWorkflowStatus::Running
	)
	{
		$this->clearCache();
	}

	if ($moduleId)
	{
		CModule::IncludeModule($moduleId);
	}

	if (class_exists($entity) && method_exists($entity, "onWorkflowStatusChange"))
		return call_user_func_array(array($entity, "onWorkflowStatusChange"), array($documentId, $workflowId, $status, $rootActivity));

	return false;
}

Добавить комментарий