• Модуль: iblock
  • Путь к файлу: ~/bitrix/modules/iblock/lib/copy/implement/children/workflow.php
  • Класс: BitrixIblockCopyImplementChildrenWorkflow
  • Вызов: Workflow::copy
public function copy($iblockId, $copiedIblockId): Result
{
	$documentType = $this->getDocumentType($iblockId);
	$newDocumentType = $this->getDocumentType($copiedIblockId);

	$bizprocHelper = new BizprocHelper($documentType);
	$templateIdsToCopy = $bizprocHelper->getWorkflowTemplateIds();

	$implementer = $this->getImplementer($newDocumentType);
	$copier = $this->getCopier($implementer);
	$this->result = $copier->copy($this->getContainerCollection($templateIdsToCopy));

	return $this->result;
}