Skip to content

Commit

Permalink
added transactions and budgets module
Browse files Browse the repository at this point in the history
  • Loading branch information
matthiaswh committed Feb 10, 2017
1 parent 9dec94f commit bb85b37
Show file tree
Hide file tree
Showing 16 changed files with 104 additions and 2 deletions.
18 changes: 18 additions & 0 deletions src/app/budgets/components/BudgetsListView.vue
@@ -0,0 +1,18 @@
<template>
<div id="budgets-list-view">
I'm a list of budgets!
</div>
</template>

<script>
export default {
name: 'budgets-list-view'
};
</script>

<style scoped lang='scss'>
#budgets-list-view {
background-color: #0000ff;
color: #ffffff;
}
</style>
1 change: 1 addition & 0 deletions src/app/budgets/components/index.js
@@ -0,0 +1 @@
export { default as BudgetsListView } from './BudgetsListView';
2 changes: 2 additions & 0 deletions src/app/budgets/index.js
@@ -0,0 +1,2 @@
export { default as routes } from './routes';
export { default as vuex } from './vuex';
8 changes: 8 additions & 0 deletions src/app/budgets/routes.js
@@ -0,0 +1,8 @@
import * as components from './components';

export default [
{
path: '/budgets',
component: components.BudgetsListView
}
];
3 changes: 3 additions & 0 deletions src/app/budgets/vuex/actions.js
@@ -0,0 +1,3 @@
export const doSomething = ({ commit }, data) => {
commit('DO_SOMETHING', { data: data });
};
12 changes: 12 additions & 0 deletions src/app/budgets/vuex/index.js
@@ -0,0 +1,12 @@
import * as actions from './actions';
import mutations from './mutations';

const state = {
budgets: []
};

export default {
state,
actions,
mutations
};
5 changes: 5 additions & 0 deletions src/app/budgets/vuex/mutations.js
@@ -0,0 +1,5 @@
export default {
DO_SOMETHING (state, { data }) {
state.something = data;
}
};
4 changes: 3 additions & 1 deletion src/app/routes.js
@@ -1,3 +1,5 @@
import { routes as accounts } from './accounts'; import { routes as accounts } from './accounts';
import { routes as transactions } from './transactions';
import { routes as budgets } from './budgets';


export default [ ...accounts ]; export default [ ...accounts, ...transactions, ...budgets ];
18 changes: 18 additions & 0 deletions src/app/transactions/components/TransactionsListView.vue
@@ -0,0 +1,18 @@
<template>
<div id="transactions-list-view">
I'm a list of transactions!
</div>
</template>

<script>
export default {
name: 'transactions-list-view'
};
</script>

<style scoped lang='scss'>
#transactions-list-view {
background-color: #000000;
color: #ffffff;
}
</style>
1 change: 1 addition & 0 deletions src/app/transactions/components/index.js
@@ -0,0 +1 @@
export { default as TransactionsListView } from './TransactionsListView';
2 changes: 2 additions & 0 deletions src/app/transactions/index.js
@@ -0,0 +1,2 @@
export { default as routes } from './routes';
export { default as vuex } from './vuex';
8 changes: 8 additions & 0 deletions src/app/transactions/routes.js
@@ -0,0 +1,8 @@
import * as components from './components';

export default [
{
path: '/transactions',
component: components.TransactionsListView
}
];
3 changes: 3 additions & 0 deletions src/app/transactions/vuex/actions.js
@@ -0,0 +1,3 @@
export const doSomething = ({ commit }, data) => {
commit('DO_SOMETHING', { data: data });
};
12 changes: 12 additions & 0 deletions src/app/transactions/vuex/index.js
@@ -0,0 +1,12 @@
import * as actions from './actions';
import mutations from './mutations';

const state = {
transactions: []
};

export default {
state,
actions,
mutations
};
5 changes: 5 additions & 0 deletions src/app/transactions/vuex/mutations.js
@@ -0,0 +1,5 @@
export default {
DO_SOMETHING (state, { data }) {
state.something = data;
}
};
4 changes: 3 additions & 1 deletion src/app/vuex.js
@@ -1,3 +1,5 @@
import { vuex as accounts } from './accounts'; import { vuex as accounts } from './accounts';
import { vuex as transactions } from './transactions';
import { vuex as budgets } from './budgets';


export default { accounts }; export default { accounts, transactions, budgets };

0 comments on commit bb85b37

Please sign in to comment.