• Модуль: catalog
  • Путь к файлу: ~/bitrix/modules/catalog/lib/component/baseform.php
  • Класс: BitrixCatalogComponentBaseForm
  • Вызов: BaseForm::getSequence
protected function getSequence(int $propertyId, int $propertyIblockId): int
{
	static $sequenceList = [];

	if (empty($sequenceList[$propertyId]))
	{
		$sequence = new CIBlockSequence($propertyIblockId, $propertyId);
		$isAjaxRequest = BitrixMainContext::getCurrent()->getRequest()->isAjaxRequest();
		$sequenceList[$propertyId] = $isAjaxRequest ? $sequence->getCurrent() : $sequence->getNext();
	}

	return $sequenceList[$propertyId];
}