• Модуль: sale
  • Путь к файлу: ~/bitrix/modules/sale/lib/location/migration/migrate.php
  • Класс: BitrixSaleLocationMigrationCUpdaterLocationPro
  • Вызов: CUpdaterLocationPro::convertTree
public function convertTree()
{
	$res = LocationNameLocationTable::getList(array('select' => array('ID'), 'limit' => 1))->fetch();
	if(!$res['ID']) // if we got smth in name table - this means we already have done this conversion in the past
	{
		$this->grabTree();
		$this->convertCountries();
		$this->convertRegions();
		$this->convertCities();

		$this->resort();

		$this->insertTreeInfo();
		$this->insertNames();
	}
}