Skip to content

Firefly III: a personal finances manager

Expenses only [skip ci]

James Colef64616748c72
diff --git a/app/Http/Controllers/Chart/CategoryController.php b/app/Http/Controllers/Chart/CategoryController.php
index 5aa5ed4592..b51120ebc1 100644
--- a/app/Http/Controllers/Chart/CategoryController.php
+++ b/app/Http/Controllers/Chart/CategoryController.php
@@ -122,6 +122,8 @@ class CategoryController extends Controller
}
/**
+ * This chart will only show expenses.
+ *
* @param GChart $chart
* @param CategoryRepositoryInterface $repository
* @param $year
diff --git a/app/Repositories/Category/CategoryRepository.php b/app/Repositories/Category/CategoryRepository.php
index 55b6f43cb3..918c879fd5 100644
--- a/app/Repositories/Category/CategoryRepository.php
+++ b/app/Repositories/Category/CategoryRepository.php
@@ -177,7 +177,7 @@ class CategoryRepository implements CategoryRepositoryInterface
// always ignore transfers between accounts!
$sum = floatval(
$category->transactionjournals()
- ->transactionTypes(['Withdrawal', 'Deposit'])
+ ->transactionTypes(['Withdrawal'])
->before($end)->after($start)->lessThan(0)->sum('amount')
) * -1;
@@ -187,7 +187,7 @@ class CategoryRepository implements CategoryRepositoryInterface
$sum = $category->transactionjournals()
->before($end)
->after($start)
- ->transactionTypes(['Withdrawal', 'Deposit'])
+ ->transactionTypes(['Withdrawal'])
->lessThan(0)
->leftJoin('accounts', 'accounts.id', '=', 'transactions.account_id')
->leftJoin(