mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-17 09:51:40 +00:00
Fix #3251
This commit is contained in:
@@ -86,7 +86,6 @@ class IndexController extends Controller
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* TODO the "budgeted" progress bar doesn't update.
|
|
||||||
* Show all budgets.
|
* Show all budgets.
|
||||||
*
|
*
|
||||||
* @param Request $request
|
* @param Request $request
|
||||||
@@ -106,7 +105,6 @@ class IndexController extends Controller
|
|||||||
$budgeted = '0';
|
$budgeted = '0';
|
||||||
$spent = '0';
|
$spent = '0';
|
||||||
|
|
||||||
|
|
||||||
// new period stuff:
|
// new period stuff:
|
||||||
$periodTitle = app('navigation')->periodShow($start, $range);
|
$periodTitle = app('navigation')->periodShow($start, $range);
|
||||||
$prevLoop = $this->getPreviousPeriods($start, $range);
|
$prevLoop = $this->getPreviousPeriods($start, $range);
|
||||||
|
@@ -35,6 +35,7 @@ use FireflyIII\Models\RuleTrigger;
|
|||||||
use FireflyIII\Repositories\Currency\CurrencyRepositoryInterface;
|
use FireflyIII\Repositories\Currency\CurrencyRepositoryInterface;
|
||||||
use FireflyIII\Services\Internal\Destroy\BudgetDestroyService;
|
use FireflyIII\Services\Internal\Destroy\BudgetDestroyService;
|
||||||
use FireflyIII\User;
|
use FireflyIII\User;
|
||||||
|
use http\Exception\RuntimeException;
|
||||||
use Illuminate\Database\QueryException;
|
use Illuminate\Database\QueryException;
|
||||||
use Illuminate\Support\Collection;
|
use Illuminate\Support\Collection;
|
||||||
use Log;
|
use Log;
|
||||||
@@ -187,12 +188,12 @@ class BudgetRepository implements BudgetRepositoryInterface
|
|||||||
*/
|
*/
|
||||||
public function getActiveBudgets(): Collection
|
public function getActiveBudgets(): Collection
|
||||||
{
|
{
|
||||||
|
//throw new \RuntimeException;
|
||||||
/** @var Collection $set */
|
/** @var Collection $set */
|
||||||
$set = $this->user->budgets()->where('active', 1)
|
$set = $this->user->budgets()->where('active', 1)
|
||||||
->orderBy('order', 'DESC')
|
->orderBy('order', 'ASC')
|
||||||
->orderBy('name', 'ASC')
|
->orderBy('name', 'ASC')
|
||||||
->get();
|
->get();
|
||||||
|
|
||||||
return $set;
|
return $set;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -202,7 +203,7 @@ class BudgetRepository implements BudgetRepositoryInterface
|
|||||||
public function getBudgets(): Collection
|
public function getBudgets(): Collection
|
||||||
{
|
{
|
||||||
/** @var Collection $set */
|
/** @var Collection $set */
|
||||||
$set = $this->user->budgets()->orderBy('order', 'DESC')
|
$set = $this->user->budgets()->orderBy('order', 'ASC')
|
||||||
->orderBy('name', 'ASC')->get();
|
->orderBy('name', 'ASC')->get();
|
||||||
|
|
||||||
return $set;
|
return $set;
|
||||||
@@ -227,7 +228,7 @@ class BudgetRepository implements BudgetRepositoryInterface
|
|||||||
{
|
{
|
||||||
/** @var Collection $set */
|
/** @var Collection $set */
|
||||||
$set = $this->user->budgets()
|
$set = $this->user->budgets()
|
||||||
->orderBy('order', 'DESC')
|
->orderBy('order', 'ASC')
|
||||||
->orderBy('name', 'ASC')->where('active', 0)->get();
|
->orderBy('name', 'ASC')->where('active', 0)->get();
|
||||||
|
|
||||||
return $set;
|
return $set;
|
||||||
|
Reference in New Issue
Block a user