• Модуль: sale
  • Путь к файлу: ~/bitrix/modules/sale/lib/cashbox/rest/cashboxservice.php
  • Класс: BitrixSaleCashboxRestCashboxService
  • Вызов: CashboxService::mergeCashboxSettings
static function mergeCashboxSettings($cashboxId, $newSettings)
{
	$existingSettings = Manager::getList([
		'select' => ['SETTINGS'],
		'filter' => ['=ID' => $cashboxId],
		'limit' => 1,
	])->fetch()['SETTINGS'];

	if (!$existingSettings)
	{
		return $newSettings;
	}

	$mergedSettings = array_replace_recursive($existingSettings, $newSettings);
	return $mergedSettings;
}