• Модуль: salescenter
  • Путь к файлу: ~/bitrix/modules/salescenter/lib/integration/locationmanager.php
  • Класс: BitrixSalesCenterIntegrationLocationManager
  • Вызов: LocationManager::storeLocationFrom
public function storeLocationFrom(int $addressId): void
{
	$location = $this->getFormattedLocation($addressId);
	if (!$location)
	{
		return;
	}

	$newLocations = [
		$this->makeLocationCode($location) => $location,
	];
	$currentLocations = $this->getLocationsFromList();
	if (is_array($currentLocations))
	{
		$newLocations = array_merge($newLocations, $currentLocations);
	}

	MainConfigOption::set(
		'salescenter',
		'default_location_from',
		serialize($newLocations)
	);
}