Abstract footer to separate component. Abstract logo to separate component. Be able to edit team in modal. Add custom fields to team. Removed vat and reg no from team (replaced by custom fields). Custom fields are also stored on the invoice. When creating invoice add team custom fields to invoice as well. Be able to set default invoice due date, late fee, vat rate and currency.

This commit is contained in:
HenriT
2021-04-13 12:07:08 +03:00
parent dce73b5603
commit 580fd9aa5a
19 changed files with 523 additions and 137 deletions

View File

@ -3,8 +3,14 @@ import Team from '@/store/models/team';
export default {
namespaced: true,
state: {},
mutations: {},
state: {
isModalOpen: false,
},
mutations: {
isModalOpen(state, isOpen) {
state.isModalOpen = isOpen;
},
},
actions: {
async init({ dispatch }) {
await Promise.all([
@ -39,12 +45,7 @@ export default {
},
getters: {
team() {
return Team.query().first();
},
all() {
return Team.query()
.where('$isNew', false)
.get();
return Team.query().with(['fields']).first();
},
},
};