From a99b287afc2f30f3dd8af001702af893d52c8bd1 Mon Sep 17 00:00:00 2001 From: emkael Date: Sun, 15 Sep 2013 14:58:03 +0200 Subject: * dodanie pola sumy częściowej lew honorowych MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bin/lib/OsikaEvaluator.php | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'bin') diff --git a/bin/lib/OsikaEvaluator.php b/bin/lib/OsikaEvaluator.php index e3a7543..e373536 100644 --- a/bin/lib/OsikaEvaluator.php +++ b/bin/lib/OsikaEvaluator.php @@ -256,18 +256,24 @@ class OsikaEvaluator { $result['l10n'] = array('total' => $this->_localizationCorrections($result, $distribution)); $subtotal = array(); + $lhSubtotal = array(); $total = 0; foreach ($result as $category => $factor) { if (count($factor) === 5) { foreach ($factor as $index => $subt) { if (!isset($subtotal[$index])) { $subtotal[$index] = 0; + $lhSubtotal[$index] = 0; } $subtotal[$index] += $subt; + if ($category !== 'lu') { + $lhSubtotal[$index] += $subt; + } } } $total += $factor['total']; } + $result['lh_subtotal'] = $lhSubtotal; $result['subtotal'] = $subtotal; $result['total'] = array('total' => $total); -- cgit v1.2.3