mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-09-30 10:33:30 +00:00
Add expenses. [skip ci]
This commit is contained in:
@@ -94,7 +94,7 @@ class BudgetReportHelper implements BudgetReportHelperInterface
|
|||||||
|
|
||||||
// stuff outside of budgets:
|
// stuff outside of budgets:
|
||||||
|
|
||||||
$noBudget = $this->repository->spentInPeriodWithoutBudget($accounts, $start, $end);
|
$noBudget = $this->repository->spentInPeriodWithoutBudget($accounts, $start, $end);
|
||||||
$budgetLine = new BudgetLine;
|
$budgetLine = new BudgetLine;
|
||||||
$budgetLine->setOverspent($noBudget);
|
$budgetLine->setOverspent($noBudget);
|
||||||
$budgetLine->setSpent($noBudget);
|
$budgetLine->setSpent($noBudget);
|
||||||
@@ -175,6 +175,7 @@ class BudgetReportHelper implements BudgetReportHelperInterface
|
|||||||
$array['left'] = bccomp(bcadd($repetition->amount, $expenses), '0') === 1 ? bcadd($repetition->amount, $expenses) : '0';
|
$array['left'] = bccomp(bcadd($repetition->amount, $expenses), '0') === 1 ? bcadd($repetition->amount, $expenses) : '0';
|
||||||
$array['spent'] = bccomp(bcadd($repetition->amount, $expenses), '0') === 1 ? $expenses : '0';
|
$array['spent'] = bccomp(bcadd($repetition->amount, $expenses), '0') === 1 ? $expenses : '0';
|
||||||
$array['overspent'] = bccomp(bcadd($repetition->amount, $expenses), '0') === 1 ? '0' : bcadd($expenses, $repetition->amount);
|
$array['overspent'] = bccomp(bcadd($repetition->amount, $expenses), '0') === 1 ? '0' : bcadd($expenses, $repetition->amount);
|
||||||
|
$array['expenses'] = $expenses;
|
||||||
|
|
||||||
return $array;
|
return $array;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user