Code: Select all
<script lang="ts">
export default defineComponent({
data: () => ({
dtContextmenuModel: [
{
label: 'Ver',
icon: 'pi pi-fw pi-search',
command: () => this.viewProduct(),
},
{ label: 'Editar', icon: 'pi pi-fw pi-pencil' },
],
})
methods: {
viewProduct() {
this.$toast.add({ severity: 'info', summary: 'Product Selected', detail: 'hellooo' });
},
}
})
</script>