diff --git a/packages/amis/src/renderers/Dialog.tsx b/packages/amis/src/renderers/Dialog.tsx index 550ea891f..adae62083 100644 --- a/packages/amis/src/renderers/Dialog.tsx +++ b/packages/amis/src/renderers/Dialog.tsx @@ -230,8 +230,9 @@ export default class Dialog extends React.Component { } handleSelfClose(e?: any, confirmed?: boolean) { - const {onClose, store} = this.props; + const {onClose, store, dispatchEvent} = this.props; + dispatchEvent('cancel'); // clear error store.updateMessage(); onClose(confirmed);