diff --git a/src/components/ui/VnConfirm.vue b/src/components/ui/VnConfirm.vue index c5d2b43f5..ec9d0f48b 100644 --- a/src/components/ui/VnConfirm.vue +++ b/src/components/ui/VnConfirm.vue @@ -30,7 +30,7 @@ const props = defineProps({ }, }); -defineEmits(['confirm', 'cancel', ...useDialogPluginComponent.emits]); +const emit = defineEmits(['confirm', 'cancel', ...useDialogPluginComponent.emits]); const { dialogRef, onDialogHide, onDialogOK, onDialogCancel } = useDialogPluginComponent(); @@ -55,6 +55,7 @@ async function confirm() { } function cancel() { + emit('cancel'); onDialogCancel(); }