Mobile add money to piggy routine

This commit is contained in:
James Cole
2016-06-16 20:52:59 +02:00
parent 6267930938
commit ae649223d8
8 changed files with 88 additions and 15 deletions

View File

@@ -23,6 +23,7 @@ use FireflyIII\User;
use Illuminate\Database\Eloquent\Relations\HasMany;
use Illuminate\Database\Query\JoinClause;
use Illuminate\Support\Collection;
use Log;
/**
* Class BudgetRepository
@@ -44,6 +45,18 @@ class BudgetRepository implements BudgetRepositoryInterface
$this->user = $user;
}
/**
* @return bool
*/
public function cleanupBudgets(): bool
{
// delete limits with amount 0:
BudgetLimit::where('amount', 0)->delete();
return true;
}
/**
* @param Budget $budget
*
@@ -156,18 +169,6 @@ class BudgetRepository implements BudgetRepositoryInterface
return $set;
}
/**
* @return bool
*/
public function cleanupBudgets(): bool
{
// delete limits with amount 0:
BudgetLimit::where('amount', 0)->delete();
return true;
}
/**
* @return Collection
*/