only close the post modal when the request succeeds
This commit is contained in:
parent
df5a5f4729
commit
0c0b8a79af
1 changed files with 3 additions and 2 deletions
|
@ -28,8 +28,9 @@ export default {
|
|||
},
|
||||
methods: {
|
||||
saveNewItem() {
|
||||
this.$store.dispatch('postItem', this.item);
|
||||
this.$store.dispatch('postItem', this.item).then(() => {
|
||||
this.$emit('close');
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue