9 if(!isset($offerParams[
"IBLOCK_ID"]) || intval($offerParams[
"IBLOCK_ID"]) <= 0)
10 throw new SystemException(
"Incorrect iBlock ID (".__CLASS__.
"::".__METHOD__.
")");
12 $arCatalog = \CCatalogSku::GetInfoByIBlock($offerParams[
"IBLOCK_ID"]);
14 if (empty($arCatalog))
15 throw new SystemException(
"IBlock is not catalog. (".__CLASS__.
"::".__METHOD__.
")");
17 $catalogType = $arCatalog[
"CATALOG_TYPE"];
18 if (!in_array($catalogType, \CCatalogSku::GetCatalogTypes()))
19 throw new SystemException(
"Unknown type of catalog (".__CLASS__.
"::".__METHOD__.
")");
25 case \CCatalogSku::TYPE_CATALOG:
26 case \CCatalogSku::TYPE_OFFERS:
27 $result =
new ExportOffer($catalogType, $offerParams);
30 case \CCatalogSku::TYPE_PRODUCT:
31 case \CCatalogSku::TYPE_FULL: