Fixed a small bug in the bill-chart and simplified yet another Json box.

This commit is contained in:
James Cole
2015-04-09 21:36:58 +02:00
parent 490997157e
commit d3f642551d
2 changed files with 24 additions and 25 deletions

View File

@@ -302,7 +302,7 @@ class GoogleChartController extends Controller
/** @var Bill $entry */
foreach ($unpaid as $entry) {
$unpaidDescriptions[] = $entry[0]->name . ' (' . $entry[1]->format('jS M Y') . ')';
$unpaidAmount += ($bill->amount_max + $bill->amount_min / 2);
$unpaidAmount += ($entry[0]->amount_max + $entry[0]->amount_min / 2);
}
$chart->addRow('Unpaid: ' . join(', ', $unpaidDescriptions), $unpaidAmount);