Remove TODO's.

This commit is contained in:
James Cole
2021-06-11 20:39:01 +02:00
parent 0d7d3f45f0
commit 8832387b84
70 changed files with 107 additions and 107 deletions

View File

@@ -159,7 +159,7 @@ class IndexController extends Controller
$accounts->each(
function (Account $account) use ($activities, $startBalances, $endBalances) {
// TODO lots of queries executed in this block.
// See reference nr. 68
$account->lastActivityDate = $this->isInArray($activities, $account->id);
$account->startBalance = $this->isInArray($startBalances, $account->id);
$account->endBalance = $this->isInArray($endBalances, $account->id);

View File

@@ -509,7 +509,7 @@ class AccountController extends Controller
/**
* Shows the balances for a given set of dates and accounts.
*
* TODO this chart is not multi-currency aware.
* See reference nr. 55
*
* @param Carbon $start
* @param Carbon $end

View File

@@ -63,7 +63,7 @@ class CategoryController extends Controller
/**
* Show an overview for a category for all time, per month/week/year.
* TODO test method, for category refactor.
* See reference nr. 59
*
* @param Category $category
*
@@ -111,7 +111,7 @@ class CategoryController extends Controller
/**
* Shows the category chart on the front page.
* TODO test method, for category refactor.
* See reference nr. 60
*
* @return JsonResponse
*/
@@ -138,7 +138,7 @@ class CategoryController extends Controller
/**
* Chart report.
* TODO test method, for category refactor.
* See reference nr. 61
*
* @param Category $category
* @param Collection $accounts
@@ -254,7 +254,7 @@ class CategoryController extends Controller
/**
* Chart for period for transactions without a category.
* TODO test me.
* See reference nr. 62
*
* @param Collection $accounts
* @param Carbon $start
@@ -281,7 +281,7 @@ class CategoryController extends Controller
/**
* Chart for a specific period.
* TODO test method, for category refactor.
* See reference nr. 63
*
* @param Category $category
* @param Carbon $date

View File

@@ -318,7 +318,7 @@ class CategoryReportController extends Controller
}
/**
* TODO duplicate function
* See reference nr. 57
*
* @param Carbon $start
* @param Carbon $end

View File

@@ -249,7 +249,7 @@ class DoubleReportController extends Controller
}
/**
* TODO this method is double.
* See reference nr. 51
*
* @param Collection $accounts
* @param int $id
@@ -274,7 +274,7 @@ class DoubleReportController extends Controller
}
/**
* TODO duplicate function
* See reference nr. 52
*
* @param Carbon $start
* @param Carbon $end

View File

@@ -69,7 +69,7 @@ class ExpenseReportController extends Controller
/**
* Main chart that shows income and expense for a combination of expense/revenue accounts.
*
* TODO this chart is not multi-currency aware.
* See reference nr. 58
*
* @param Collection $accounts
* @param Collection $expense

View File

@@ -58,7 +58,7 @@ class PiggyBankController extends Controller
/**
* Shows the piggy bank history.
*
* TODO this chart is not multi-currency aware.
* See reference nr. 53
*
* @param PiggyBankRepositoryInterface $repository
* @param PiggyBank $piggyBank

View File

@@ -102,7 +102,7 @@ class ReportController extends Controller
}
);
// TODO get liabilities and include those as well?
// See reference nr. 56
while ($current < $end) {
// get balances by date, grouped by currency.

View File

@@ -323,7 +323,7 @@ class TagReportController extends Controller
}
/**
* TODO duplicate function
* See reference nr. 54
*
* @param Carbon $start
* @param Carbon $end

View File

@@ -69,7 +69,7 @@ class IndexController extends Controller
/**
* Show overview of all piggy banks.
* TODO complicated
* See reference nr. 66
*
* @param Request $request
*

View File

@@ -653,7 +653,7 @@ class ProfileController extends Controller
}
/**
* TODO duplicate code.
* See reference nr. 64
*
* @param string $mfaCode
*/

View File

@@ -86,7 +86,7 @@ class EditController extends Controller
*/
public function edit(Request $request, Recurrence $recurrence)
{
// TODO should be in repos
// See reference nr. 69
$count = $recurrence->recurrenceTransactions()->count();
if (0 === $count) {
throw new FireflyException('This recurring transaction has no meta-data. You will have to delete it and recreate it. Sorry!');

View File

@@ -68,7 +68,7 @@ class IndexController extends Controller
}
/**
* TODO the notes of a recurrence are pretty pointless at this moment.
* See reference nr. 70
* Show all recurring transactions.
*
* @param Request $request

View File

@@ -292,7 +292,7 @@ class DoubleController extends Controller
}
/**
* TODO this method is double.
* See reference nr. 67
*
* @param Collection $accounts
* @param int $id

View File

@@ -143,7 +143,7 @@ class EditController extends Controller
*/
private function parseFromOperators(array $submittedOperators): array
{
// TODO duplicated code.
// See reference nr. 65
$operators = config('firefly.search.operators');
$renderedEntries = [];
$triggers = [];

View File

@@ -63,7 +63,7 @@ class BulkController extends Controller
/**
* Edit a set of journals in bulk.
*
* TODO user wont be able to tell if journal is part of split.
* See reference nr. 47
*
* @param array $journals
*

View File

@@ -47,7 +47,7 @@ use Log;
/**
* Class ConvertController.
*
* TODO when converting to a split transfer, all sources and destinations must be the same.
* See reference nr. 49
*/
class ConvertController extends Controller
{
@@ -346,7 +346,7 @@ class ConvertController extends Controller
throw new FireflyException(sprintf(trans('firefly.convert_invalid_destination'), $journal->id));
}
// TODO typeOverrule: the account validator may have another opinion on the transaction type.
// See reference nr. 50
$update = [
'source_id' => $sourceId,

View File

@@ -167,7 +167,7 @@ class MassController extends Controller
{
$journalIds = $request->get('journals');
if (!is_array($journalIds)) {
// TODO something error.
// See reference nr. 48
throw new FireflyException('This is not an array.');
}
$count = 0;

View File

@@ -304,7 +304,7 @@ class RecurrenceFormRequest extends FormRequest
$sourceId = null;
$destinationId = null;
// TODO typeOverrule: the account validator may have another opinion on the transaction type.
// See reference nr. 45
switch ($this->string('transaction_type')) {
default:

View File

@@ -37,7 +37,7 @@ class TestRuleFormRequest extends FormRequest
/**
* Rules for this request.
* TODO these rules are not valid anymore.
* See reference nr. 46
*
* @return array
*/