- Модуль: conversion
- Путь к файлу: ~/bitrix/modules/conversion/lib/reportcontext.php
- Класс: BitrixConversionReportContext
- Вызов: ReportContext::getSplitCountersDeprecated
private function getSplitCountersDeprecated(array $splits, array $filter = null, array $steps = null)
{
$result = array();
$totalCounters = $this->getCountersDeprecated($filter, $steps);
$otherCounters = $totalCounters;
foreach ($splits as $splitKey => $attribute)
{
if ($attribute['NAME'])
{
$this->setAttribute($attribute['NAME'], $attribute['VALUE']);
$counters = $this->getCountersDeprecated($filter, $steps);
$result[$splitKey] = $counters;
self::subtructCounters($otherCounters, $counters, $steps);
$this->unsetAttribute($attribute['NAME'], $attribute['VALUE']);
}
}
$result['other'] = $otherCounters > 0 ? $otherCounters : 0; // can be -0 or maybe -something
$result['total'] = $totalCounters;
return $result;
}