Remove TODO's.

This commit is contained in:
James Cole 2021-06-12 14:14:49 +02:00
parent 91b08d1772
commit 4614625f82
No known key found for this signature in database
GPG Key ID: B5669F9493CDE38D
22 changed files with 54 additions and 54 deletions

View File

@ -309,7 +309,7 @@ export default {
this.accounts[i].order = newOrder;
let url = './api/v1/accounts/' + current.id;
axios.put(url, {order: newOrder}).then(response => {
// TODO should update local account list, not refresh the whole thing.
// See reference nr. 8
this.getAccountList();
});
}
@ -485,7 +485,7 @@ export default {
//
// allAccounts.push(acct);
// if ('asset' === this.type) {
// // TODO
// See reference nr. 9
// //this.getAccountBalanceDifference(this.allAccounts.length - 1, current);
// //this.getAccountLastActivity(this.allAccounts.length - 1, current);
// }

View File

@ -324,7 +324,7 @@ export default {
let today = new Date(this.range.start);
let start;
let end;
let title = 'todo';
let title = 'tbd';
let half = 1;
// its currently first half of year:

View File

@ -79,7 +79,7 @@ import format from "date-fns/format";
const {mapState, mapGetters, mapActions, mapMutations} = createNamespacedHelpers('dashboard/index')
// TODO same as credit list but reversed
// See reference nr. 2
export default {
name: "MainCreditList",

View File

@ -56,7 +56,7 @@ const getters = {
return state.transactionType;
},
accountToTransaction: state => {
// TODO better architecture here, does not need the store.
// See reference nr. 1
// possible API point!!
return state.accountToTransaction;
},

View File

@ -23,7 +23,7 @@
<alert :message="errorMessage" type="danger"/>
<alert :message="successMessage" type="success"/>
<form @submit="submitTransaction" autocomplete="off">
<SplitPills :transactions="transactions"/>
<SplitPills :transactions="transactions" :count="transactions.length"/>
<div class="tab-content">
<SplitForm
v-for="(transaction, index) in this.transactions"
@ -492,7 +492,7 @@ export default {
}
// submit transaction link:
promises.push(axios.post('./api/v1/transaction_links', currentLink).then(response => {
// TODO error handling.
// See reference nr. 4
}));
}
}

View File

@ -298,7 +298,7 @@ export default {
if (0 === index) {
this.transactionType = array.type.charAt(0).toUpperCase() + array.type.slice(1);
// TODO here you may need to catch stuff like loan/debt/mortgage
// See reference nr. 5
this.sourceAllowedTypes = [array.source_type];
this.destinationAllowedTypes = [array.destination_type];
this.date = array.date.substring(0, 16);
@ -938,7 +938,7 @@ export default {
return JSON.stringify(compare);
},
// uploadAttachments: function (result) {
// //console.log('TODO, upload attachments.');
// See reference nr. 6
// if (0 === Object.keys(result).length) {
//
// for (let i in this.transactions) {
@ -1172,7 +1172,7 @@ export default {
for (let i in this.transactions) {
if (this.transactions.hasOwnProperty(i) && /^0$|^[1-9]\d*$/.test(i) && i <= 4294967294) {
if (this.transactions.hasOwnProperty(i)) {
// TODO
// See reference nr. 7
}
}
}

View File

@ -185,7 +185,7 @@
<script>
const lodashClonedeep = require('lodash.clonedeep');
// TODO error handling
// See reference nr. 3
export default {
props: ['index', 'value', 'errors', 'customFields'],
name: "TransactionLinks",

View File

@ -30,8 +30,8 @@ import IndexOptions from "../../components/accounts/IndexOptions";
let i18n = require('../../i18n');
let props = {};
// TODO: long lists are slow to load. Fix this.
// TODO add interest for liabilities
// See reference nr. 8
// See reference nr. 9
Vue.component('b-table', BTable);
Vue.component('b-pagination', BPagination);
@ -45,7 +45,7 @@ new Vue({
return createElement(Index, {props: props});
},
beforeCreate() {
// init the old root store (TODO remove me)
// See reference nr. 10
this.$store.commit('initialiseStore');
this.$store.dispatch('updateCurrencyPreference');
@ -64,7 +64,7 @@ new Vue({
render: (createElement) => {
return createElement(Calendar, {props: props});
},
// TODO init store as well?
// See reference nr. 11
});
new Vue({
@ -74,5 +74,5 @@ new Vue({
render: (createElement) => {
return createElement(IndexOptions, {props: props});
},
// TODO init store as well?
// See reference nr. 12
});

View File

@ -35,7 +35,7 @@ new Vue({
return createElement(Index, {props: props});
},
beforeCreate() {
// init the old root store (TODO remove me)
// See reference nr. 13
//this.$store.commit('initialiseStore');
//this.$store.dispatch('updateCurrencyPreference');

View File

@ -43,7 +43,7 @@ import store from '../components/store';
* vue, uiv and vuei18n are in app_vue.js
*/
// TODO pretty sure not all categories, budgets and other objects are picked up because they're paginated.
// See reference nr. 14
require('../bootstrap');
require('chart.js');
@ -78,7 +78,7 @@ new Vue({
return createElement(Dashboard, {props: props});
},
beforeCreate() {
// TODO migrate to "root" store.
// See reference nr. 15
this.$store.commit('initialiseStore');
this.$store.dispatch('updateCurrencyPreference');
this.$store.dispatch('root/initialiseStore');
@ -92,5 +92,5 @@ new Vue({
render: (createElement) => {
return createElement(Calendar, {props: props});
},
// TODO init store as well?
// See reference nr. 16
});

View File

@ -28,11 +28,11 @@ Vue.config.productionTip = false;
// i18n
let i18n = require('../../i18n');
// TODO take transaction type from URL. Simplifies a lot of code.
// TODO make sure the enter button works.
// TODO add preferences in sidebar
// TODO If I change the date box at all even if you just type over it with the current date, it posts back a day.
// TODO Cash accounts do not work
// See reference nr. 3
// See reference nr. 4
// See reference nr. 5
// See reference nr. 6
// See reference nr. 7
let props = {};
new Vue({

View File

@ -40,7 +40,7 @@ new Vue({
return createElement(Index, {props: props});
},
beforeCreate() {
// init the old root store (TODO remove me)
// See reference nr. 2
this.$store.commit('initialiseStore');
this.$store.dispatch('updateCurrencyPreference');

View File

@ -198,19 +198,19 @@ export default {
if (this.transactionType.toString() !== '' && this.index > 0) {
if (this.transactionType.toString().toLowerCase() === 'transfer') {
this.inputDisabled = true;
// todo: needs to copy value from very first input
// See reference nr. 2
return;
}
if (this.transactionType.toString().toLowerCase() === 'withdrawal' && this.inputName.substr(0, 6).toLowerCase() === 'source') {
// todo also clear value?
// See reference nr. 3
this.inputDisabled = true;
return;
}
if (this.transactionType.toString().toLowerCase() === 'deposit' && this.inputName.substr(0, 11).toLowerCase() === 'destination') {
// todo also clear value?
// See reference nr. 4
this.inputDisabled = true;
}
}
@ -240,7 +240,7 @@ export default {
this.$emit('clear:value')
},
handleEnter: function (e) {
// todo feels sloppy
// See reference nr. 5
if (e.keyCode === 13) {
//e.preventDefault();
}

View File

@ -166,7 +166,7 @@ export default {
this.$emit('input', this.name.name);
},
handleEnter: function (e) {
// todo feels sloppy
// See reference nr. 1
if (e.keyCode === 13) {
//e.preventDefault();
}

View File

@ -96,7 +96,7 @@ export default {
};
},
computed: {
// TODO this seems a pretty weird way of doing it.
// See reference nr. 6
dateComponent() {
return 'custom-date';
},

View File

@ -138,7 +138,7 @@ export default {
this.$emit('input', this.$refs.descr.value);
},
handleEnter: function (e) {
// todo feels sloppy
// See reference nr. 7
if (e.keyCode === 13) {
//e.preventDefault();

View File

@ -125,7 +125,7 @@
{% if journal.reconciled %}
<span class="fa fa-check" aria-hidden="true"></span>
{% else %}
<!-- TODO include icon -->
<!-- See reference nr. 1 -->
{% endif %}
{% endif %}

View File

@ -16,7 +16,7 @@
<td data-value="{{ transaction.description }}">{{ transaction.description }}</td>
<td data-value="{{ transaction.date.format('Y-m-d') }}">
{{ transaction.date.formatLocalized(monthAndDayFormat) }}
</td><!-- TODO i dont think transactionAmount will work -->
</td><!-- See reference nr. 3 -->
<td style="text-align: right;" data-value="{{ transaction.amount}}"><span
style="margin-right:5px;">

View File

@ -3,7 +3,7 @@
<a href="#" class="btn btn-danger btn-sm remove-action"><span class="fa fa-trash"></span></a>
</td>
<td style="width:30%;">
{# todo error when invalid name. #}
{# See reference nr. 2 #}
<select name="actions[{{ count }}][type]" class="form-control">
{% for key,type in allRuleActions() %}
<option value="{{ key }}" label="{{ type }}" {% if key == oldAction %} selected{% endif %}>{{ type }}</option>

View File

@ -121,10 +121,10 @@ Route::group(
Route::get('tag', ['uses' => 'TagController@tag', 'as' => 'tag']);
Route::get('no-tag', ['uses' => 'TagController@noTag', 'as' => 'no-tag']);
// TODO Per object group, maybe in the future.
// TODO Per recurrence, all transactions created under it.
// TODO Per currency, or as a filter?
// TODO Show user net worth?
// See reference nr. 7
// See reference nr. 8
// See reference nr. 9
// See reference nr. 10
}
);
// insight in income
@ -142,10 +142,10 @@ Route::group(
Route::get('tag', ['uses' => 'TagController@tag', 'as' => 'tag']);
Route::get('no-tag', ['uses' => 'TagController@noTag', 'as' => 'no-tag']);
// TODO Per object group, maybe in the future.
// TODO Per recurrence, all transactions created under it.
// TODO Per currency, or as a filter?
// TODO Show user net worth?
// See reference nr. 11
// See reference nr. 12
// See reference nr. 13
// See reference nr. 14
}
);
@ -162,7 +162,7 @@ Route::group(
Route::get('no-tag', ['uses' => 'TagController@noTag', 'as' => 'no-tag']);
Route::get('total', ['uses' => 'PeriodController@total', 'as' => 'total']);
// TODO Transfers for piggies
// See reference nr. 15
}
);
/**
@ -342,7 +342,7 @@ Route::group(
Route::delete('{recurrence}', ['uses' => 'DestroyController@destroy', 'as' => 'delete']);
Route::get('{recurrence}/transactions', ['uses' => 'ListController@transactions', 'as' => 'transactions']);
// TODO
// See reference nr. 16
Route::post('trigger', ['uses' => 'RecurrenceController@trigger', 'as' => 'trigger']);
}
);
@ -360,9 +360,9 @@ Route::group(
Route::delete('{rule}', ['uses' => 'DestroyController@destroy', 'as' => 'delete']);
Route::get('{rule}/test', ['uses' => 'TriggerController@testRule', 'as' => 'test']);
// TODO give results back.
// See reference nr. 17
Route::post('{rule}/trigger', ['uses' => 'TriggerController@triggerRule', 'as' => 'trigger']);
// TODO rule transactions, rule bills?
// See reference nr. 18
}
);

View File

@ -1111,13 +1111,13 @@ try {
$title = limitStringLength((string)$group->title);
}
if ('opening balance' === $type) {
// TODO link to account.
// See reference nr. 1
$breadcrumbs->push($title, route('transactions.show', [$group->id]));
return;
}
if ('reconciliation' === $type) {
// TODO link to account.
// See reference nr. 2
$breadcrumbs->push($title, route('transactions.show', [$group->id]));
return;

View File

@ -808,7 +808,7 @@ Route::group(
'as' => 'report-data.category.',],
static function () {
// TODO three routes still in use?
// See reference nr. 3
Route::get('operations/{accountList}/{start_date}/{end_date}', ['uses' => 'CategoryController@operations', 'as' => 'operations']);
Route::get('income/{accountList}/{start_date}/{end_date}', ['uses' => 'CategoryController@income', 'as' => 'income']);
Route::get('expenses/{accountList}/{start_date}/{end_date}', ['uses' => 'CategoryController@expenses', 'as' => 'expenses']);
@ -864,7 +864,7 @@ Route::group(
['middleware' => 'user-full-auth', 'namespace' => 'FireflyIII\Http\Controllers\Report', 'prefix' => 'report-data/budget', 'as' => 'report-data.budget.'],
static function () {
Route::get('general/{accountList}/{start_date}/{end_date}/', ['uses' => 'BudgetController@general', 'as' => 'general']);
// TODO is route still used?
// See reference nr. 4
Route::get('period/{accountList}/{start_date}/{end_date}', ['uses' => 'BudgetController@period', 'as' => 'period']);
Route::get('accounts/{accountList}/{budgetList}/{start_date}/{end_date}', ['uses' => 'BudgetController@accounts', 'as' => 'accounts']);
@ -974,7 +974,7 @@ Route::group(
static function () {
// show groups:
// TODO improve these routes
// See reference nr. 5
Route::get('{what}/all', ['uses' => 'Transaction\IndexController@indexAll', 'as' => 'index.all'])->where(
['what' => 'withdrawal|deposit|transfers|transfer']
);
@ -1047,7 +1047,7 @@ Route::group(
static function () {
Route::get('modal/{tj}', ['uses' => 'LinkController@modal', 'as' => 'modal']);
// TODO improve this route:
// See reference nr. 6
Route::post('store/{tj}', ['uses' => 'LinkController@store', 'as' => 'store']);
Route::get('delete/{journalLink}', ['uses' => 'LinkController@delete', 'as' => 'delete']);
Route::get('switch/{journalLink}', ['uses' => 'LinkController@switchLink', 'as' => 'switch']);