mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2026-05-03 20:56:21 +00:00
Code clean up.
This commit is contained in:
@@ -114,7 +114,10 @@ class BalanceReportHelper implements BalanceReportHelperInterface
|
||||
$balanceEntry = new BalanceEntry;
|
||||
$balanceEntry->setAccount($account);
|
||||
$spent = $this->budgetRepository->spentInPeriod(
|
||||
new Collection([$budgetLimit->budget]), new Collection([$account]), $budgetLimit->start_date, $budgetLimit->end_date
|
||||
new Collection([$budgetLimit->budget]),
|
||||
new Collection([$account]),
|
||||
$budgetLimit->start_date,
|
||||
$budgetLimit->end_date
|
||||
);
|
||||
$balanceEntry->setSpent($spent);
|
||||
$line->addBalanceEntry($balanceEntry);
|
||||
@@ -142,7 +145,6 @@ class BalanceReportHelper implements BalanceReportHelperInterface
|
||||
$budgetEntry->setAccount($account);
|
||||
$budgetEntry->setSpent($spent);
|
||||
$empty->addBalanceEntry($budgetEntry);
|
||||
|
||||
}
|
||||
|
||||
return $empty;
|
||||
@@ -176,7 +178,5 @@ class BalanceReportHelper implements BalanceReportHelperInterface
|
||||
$balance->setBalanceLines($newSet);
|
||||
|
||||
return $balance;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -27,7 +27,6 @@ use Carbon\Carbon;
|
||||
use FireflyIII\Helpers\Collection\Balance;
|
||||
use Illuminate\Support\Collection;
|
||||
|
||||
|
||||
/**
|
||||
* Interface BalanceReportHelperInterface
|
||||
*
|
||||
|
||||
@@ -23,7 +23,6 @@ declare(strict_types=1);
|
||||
|
||||
namespace FireflyIII\Helpers\Report;
|
||||
|
||||
|
||||
use Carbon\Carbon;
|
||||
use FireflyIII\Models\Budget;
|
||||
use FireflyIII\Models\BudgetLimit;
|
||||
@@ -163,6 +162,5 @@ class BudgetReportHelper implements BudgetReportHelperInterface
|
||||
$array['expenses'] = $expenses;
|
||||
|
||||
return $array;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,7 +23,6 @@ declare(strict_types=1);
|
||||
|
||||
namespace FireflyIII\Helpers\Report;
|
||||
|
||||
|
||||
use Carbon\Carbon;
|
||||
use Illuminate\Support\Collection;
|
||||
|
||||
@@ -52,5 +51,4 @@ interface BudgetReportHelperInterface
|
||||
* @return Collection
|
||||
*/
|
||||
public function getBudgetsWithExpenses(Carbon $start, Carbon $end, Collection $accounts): Collection;
|
||||
|
||||
}
|
||||
|
||||
@@ -153,5 +153,4 @@ class ReportHelper implements ReportHelperInterface
|
||||
|
||||
return $months;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -57,5 +57,4 @@ interface ReportHelperInterface
|
||||
* @return array
|
||||
*/
|
||||
public function listOfMonths(Carbon $date): array;
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user