Updates on errors

Former-commit-id: 6523e78400ba84510f754e05f589b8f7c779319f [formerly 2d473b45716aaf6e35f2757bf9dc27adcafefd88] [formerly 5b34db9a57e050b307f1c5803cad82d2af155867 [formerly c206bea84a3e667047920d7dbcd0fc1c89cbced9]]
Former-commit-id: 703d059a7455131dfa20d89050c40367f692b4b5 [formerly a320aa2603c47685e484cae3715eb788b1218fe9]
Former-commit-id: 3819065ec37278f32ebceeda9cbb7af6f8723392
This commit is contained in:
Henrique Dias
2017-07-08 11:51:24 +01:00
parent e6efec5682
commit ca9646ff9e
9 changed files with 86 additions and 18 deletions

View File

@@ -14,7 +14,13 @@ const mutations = {
},
showError: (state, value) => {
state.show = 'error'
state.showMessage = value
if (typeof value !== 'object') {
state.showMessage = value
return
}
state.showMessage = value.message
},
setLoading: (state, value) => { state.loading = value },
setReload: (state, value) => { state.reload = value },