• Модуль: catalogmobile
  • Путь к файлу: ~/bitrix/modules/catalogmobile/lib/ProductWizard/SaveProductCommand.php
  • Класс: BitrixCatalogMobileProductWizardSaveProductCommand
  • Вызов: SaveProductCommand::callCatalogController
private function callCatalogController(): ?array
{
	if ($this->variationId)
	{
		$productId = $this->getParentProductId($this->variationId);
		$oldFields = $this->prepareOldProductFields($this->variationId);
		$fields = $this->prepareNewProductFields($this->fields, $oldFields);

		$response = $this->controller->updateSkuAction(
			$this->variationId,
			$fields,
			$oldFields
		);
		if ($response && isset($fields['MORE_PHOTO']))
		{
			$this->controller->saveMorePhotoAction(
				$productId,
				$this->variationId,
				$this->productIblockId,
				$fields['MORE_PHOTO']
			);
		}
	}
	else
	{
		$response = $this->controller->createProductAction($this->fields);
	}

	return $response;
}