James Cole
2023-12-29 20:25:32 +01:00
parent 33b95b9371
commit 4230349c07
20 changed files with 75 additions and 15 deletions

View File

@@ -36,8 +36,7 @@ use Illuminate\Support\Collection;
*/
class OperationsRepository implements OperationsRepositoryInterface
{
/** @var User */
private $user;
private User $user;
/**
* This method returns a list of all the withdrawal transaction journals (as arrays) set in that period
@@ -58,7 +57,7 @@ class OperationsRepository implements OperationsRepositoryInterface
if (null === $tags || 0 === $tags->count()) {
$collector->setTags($this->getTags());
}
$collector->withCategoryInformation()->withAccountInformation()->withBudgetInformation()->withTagInformation();
$collector->withCategoryInformation()->withAccountInformation()->withBudgetInformation();
$journals = $collector->getExtractedJournals();
$array = [];
$listedJournals = [];

View File

@@ -44,8 +44,9 @@ class AvailableBudgetRepository implements AvailableBudgetRepositoryInterface
$converter = new ExchangeRateConverter();
$default = app('amount')->getDefaultCurrency();
$availableBudgets = $this->userGroup->availableBudgets()
->where('start_date', $start->format('Y-m-d'))
->where('end_date', $end->format('Y-m-d'))->get();
->where('start_date', $start->format('Y-m-d'))
->where('end_date', $end->format('Y-m-d'))->get()
;
/** @var AvailableBudget $availableBudget */
foreach ($availableBudgets as $availableBudget) {