From df6d151153f0f912392461a7eb373371e1e7641d Mon Sep 17 00:00:00 2001 From: yison Date: Thu, 21 Mar 2019 12:20:16 +0800 Subject: [PATCH] forward --- src/components/modal/confirm.js | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/components/modal/confirm.js b/src/components/modal/confirm.js index d54ef0e7..a3cb86af 100644 --- a/src/components/modal/confirm.js +++ b/src/components/modal/confirm.js @@ -24,7 +24,7 @@ Modal.newInstance = properties => { buttonLoading: false, scrollable: false, closable: false, - autoClose: false + autoClose: true }), render (h) { let footerVNodes = []; @@ -102,7 +102,8 @@ Modal.newInstance = properties => { props: Object.assign({}, _props, { width: this.width, scrollable: this.scrollable, - closable: this.closable + closable: this.closable, + autoClose: this.autoClose }), domProps: { value: this.visible @@ -246,6 +247,10 @@ Modal.newInstance = properties => { modal.$parent.onCancel = props.onCancel; } + if ('autoClose' in props) { + modal.$parent.autoClose = props.autoClose; + } + if ('onOk' in props) { modal.$parent.onOk = props.onOk; }