• Модуль: catalog
  • Путь к файлу: ~/bitrix/modules/catalog/lib/product/catalogprovider.php
  • Класс: BitrixCatalogProductCatalogProvider
  • Вызов: CatalogProvider::getCompileReserve
static function getCompileReserve(array $product): array
	{
		if (empty($product['NEED_RESERVE_BY_STORE_LIST']) || !is_array($product['NEED_RESERVE_BY_STORE_LIST']))
		{
			return [];
		}

		$result = [];
		foreach ($product['NEED_RESERVE_BY_STORE_LIST'] as $shipment)
		{
			if (empty($shipment) || !is_array($shipment))
			{
				continue;
			}
			foreach ($shipment as $storeId => $flag)
			{
				if ($flag === true)
				{
					$result[$storeId] = true;
				}
			}
		}

		return $result;
	}