close modals when saving
This commit is contained in:
parent
d3a52aae06
commit
7131a54455
3 changed files with 6 additions and 5 deletions
|
|
@ -17,7 +17,7 @@ import Modal from '@/components/Modal';
|
|||
import EditItem from '@/components/EditItem';
|
||||
|
||||
export default {
|
||||
name: 'AddItem',
|
||||
name: 'AddItemModal',
|
||||
components: { Modal, EditItem },
|
||||
props: ['isModal'],
|
||||
data: () => ({
|
||||
|
|
@ -26,6 +26,7 @@ export default {
|
|||
methods: {
|
||||
saveNewItem() {
|
||||
this.$store.dispatch('postItem', this.item);
|
||||
this.$emit('close');
|
||||
}
|
||||
}
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue