add remove product

This commit is contained in:
Tiago Vasconcelos 2023-03-23 16:38:09 +00:00
parent 83f25f7972
commit 70d6c23d47
2 changed files with 9 additions and 2 deletions

View file

@ -29,6 +29,13 @@ async function shoppingCart(path) {
'remove-from-cart',
this.products.find(p => p.id == id)
)
},
removeProduct(id) {
this.$emit(
'remove-from-cart',
this.products.find(p => p.id == id),
true
)
}
},
created() {}