mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-12 23:45:10 +00:00
Method no longer used.
This commit is contained in:
@@ -384,7 +384,6 @@ class ReportHelper implements ReportHelperInterface
|
|||||||
$diffLine->setRole(BalanceLine::ROLE_DIFFROLE);
|
$diffLine->setRole(BalanceLine::ROLE_DIFFROLE);
|
||||||
|
|
||||||
foreach ($accounts as $account) {
|
foreach ($accounts as $account) {
|
||||||
//$spent = $this->query->spentNoBudget($account, $start, $end);
|
|
||||||
$entry = $spentData->filter(
|
$entry = $spentData->filter(
|
||||||
function (TransactionJournal $model) use ($budget, $account) {
|
function (TransactionJournal $model) use ($budget, $account) {
|
||||||
return $model->account_id == $account->id && is_null($model->budget_id);
|
return $model->account_id == $account->id && is_null($model->budget_id);
|
||||||
|
@@ -19,26 +19,6 @@ use Illuminate\Support\Collection;
|
|||||||
class ReportQuery implements ReportQueryInterface
|
class ReportQuery implements ReportQueryInterface
|
||||||
{
|
{
|
||||||
|
|
||||||
/**
|
|
||||||
* @param Account $account
|
|
||||||
* @param Carbon $start
|
|
||||||
* @param Carbon $end
|
|
||||||
*
|
|
||||||
* @return string
|
|
||||||
*/
|
|
||||||
public function spentNoBudget(Account $account, Carbon $start, Carbon $end)
|
|
||||||
{
|
|
||||||
return
|
|
||||||
Auth::user()->transactionjournals()
|
|
||||||
->leftJoin('transactions', 'transactions.transaction_journal_id', '=', 'transaction_journals.id')
|
|
||||||
->leftJoin('budget_transaction_journal', 'budget_transaction_journal.transaction_journal_id', '=', 'transaction_journals.id')
|
|
||||||
->transactionTypes([TransactionType::WITHDRAWAL])
|
|
||||||
->where('transactions.account_id', $account->id)
|
|
||||||
->before($end)
|
|
||||||
->after($start)
|
|
||||||
->whereNull('budget_transaction_journal.budget_id')->get(['transaction_journals.*'])->sum('amount');
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns an array of the amount of money spent in the given accounts (on withdrawals, opening balances and transfers)
|
* Returns an array of the amount of money spent in the given accounts (on withdrawals, opening balances and transfers)
|
||||||
* grouped by month like so: "2015-01" => '123.45'
|
* grouped by month like so: "2015-01" => '123.45'
|
||||||
|
@@ -39,15 +39,6 @@ interface ReportQueryInterface
|
|||||||
*/
|
*/
|
||||||
public function expense(Collection $accounts, Carbon $start, Carbon $end);
|
public function expense(Collection $accounts, Carbon $start, Carbon $end);
|
||||||
|
|
||||||
/**
|
|
||||||
* @param Account $account
|
|
||||||
* @param Carbon $start
|
|
||||||
* @param Carbon $end
|
|
||||||
*
|
|
||||||
* @return string
|
|
||||||
*/
|
|
||||||
public function spentNoBudget(Account $account, Carbon $start, Carbon $end);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns an array of the amount of money spent in the given accounts (on withdrawals, opening balances and transfers)
|
* Returns an array of the amount of money spent in the given accounts (on withdrawals, opening balances and transfers)
|
||||||
* grouped by month like so: "2015-01" => '123.45'
|
* grouped by month like so: "2015-01" => '123.45'
|
||||||
|
Reference in New Issue
Block a user