2020-09-23 18:09:40 +00:00
|
|
|
export default {
|
|
|
|
computed: {
|
|
|
|
saving() { return this.$store.state.saving; }
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
methods: {
|
|
|
|
setSaving(value)
|
|
|
|
{
|
2020-10-09 18:38:09 +00:00
|
|
|
this.$store.commit('saving', value);
|
2020-09-23 18:09:40 +00:00
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
showNotification(message, isError)
|
|
|
|
{
|
|
|
|
this.$store.dispatch('showNotification', {
|
|
|
|
message: message,
|
|
|
|
isError: isError || false
|
|
|
|
});
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
handleAPIError(messageId, error)
|
|
|
|
{
|
|
|
|
this.$store.dispatch('notifyAPIError', { message: this.$i18n.t(messageId), error });
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|