mirror of
				https://github.com/firefly-iii/firefly-iii.git
				synced 2025-10-31 02:36:28 +00:00 
			
		
		
		
	Update files for new release
This commit is contained in:
		| @@ -138,7 +138,7 @@ class IndexController extends Controller | ||||
| 
 | ||||
|         // get budgeted for default currency:
 | ||||
|         if (0 === count($availableBudgets)) { | ||||
|             $budgeted = $this->blRepository->budgeted($start, $end, $defaultCurrency, ); | ||||
|             $budgeted = $this->blRepository->budgeted($start, $end, $defaultCurrency,); | ||||
|             $spentArr = $this->opsRepository->sumExpenses($start, $end, null, null, $defaultCurrency); | ||||
|             $spent    = $spentArr[$defaultCurrency->id]['sum'] ?? '0'; | ||||
|             unset($spentArr); | ||||
| @@ -197,7 +197,7 @@ class IndexController extends Controller | ||||
|             $array['spent'] = $spentArr[$entry->transaction_currency_id]['sum'] ?? '0'; | ||||
| 
 | ||||
|             // budgeted in period:
 | ||||
|             $budgeted           = $this->blRepository->budgeted($entry->start_date, $entry->end_date, $entry->transactionCurrency, ); | ||||
|             $budgeted           = $this->blRepository->budgeted($entry->start_date, $entry->end_date, $entry->transactionCurrency,); | ||||
|             $array['budgeted']  = $budgeted; | ||||
|             $availableBudgets[] = $array; | ||||
|             unset($spentArr); | ||||
| @@ -227,6 +227,7 @@ class IndexController extends Controller | ||||
|             Log::debug(sprintf('Working on budget #%d ("%s")', $current->id, $current->name)); | ||||
|             $array                = $current->toArray(); | ||||
|             $array['spent']       = []; | ||||
|             $array['spent_total'] = []; | ||||
|             $array['budgeted']    = []; | ||||
|             $array['attachments'] = $this->repository->getAttachments($current); | ||||
|             $array['auto_budget'] = $this->repository->getAutoBudget($current); | ||||
| @@ -235,9 +236,10 @@ class IndexController extends Controller | ||||
|             foreach ($budgetLimits as $limit) { | ||||
|                 Log::debug(sprintf('Working on budget limit #%d', $limit->id)); | ||||
|                 $currency            = $limit->transactionCurrency ?? $defaultCurrency; | ||||
|                 $amount              = app('steam')->bcround($limit->amount, $currency->decimal_places); | ||||
|                 $array['budgeted'][] = [ | ||||
|                     'id'                      => $limit->id, | ||||
|                     'amount'                  => app('steam')->bcround($limit->amount, $currency->decimal_places), | ||||
|                     'amount'                  => $amount, | ||||
|                     'start_date'              => $limit->start_date->isoFormat($this->monthAndDayFormat), | ||||
|                     'end_date'                => $limit->end_date->isoFormat($this->monthAndDayFormat), | ||||
|                     'in_range'                => $limit->start_date->isSameDay($start) && $limit->end_date->isSameDay($end), | ||||
| @@ -246,6 +248,7 @@ class IndexController extends Controller | ||||
|                     'currency_name'           => $currency->name, | ||||
|                     'currency_decimal_places' => $currency->decimal_places, | ||||
|                 ]; | ||||
|                 Log::debug(sprintf('The amount budgeted for budget limit #%d is %s %s', $limit->id, $currency->code, $amount)); | ||||
|             } | ||||
| 
 | ||||
|             /** @var TransactionCurrency $currency */ | ||||
|   | ||||
		Reference in New Issue
	
	Block a user