From 3df2d3624c6b768d29670b537f8d6a71d3ef122c Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期日, 12 四月 2020 22:04:53 +0800 Subject: [PATCH] 2020-04-12 --- src/templates/zshare/verifycardexcelin/index.jsx | 41 ++++++++++++++++++++++++++++++++++++++++- 1 files changed, 40 insertions(+), 1 deletions(-) diff --git a/src/templates/zshare/verifycardexcelin/index.jsx b/src/templates/zshare/verifycardexcelin/index.jsx index 3113e4e..c249aeb 100644 --- a/src/templates/zshare/verifycardexcelin/index.jsx +++ b/src/templates/zshare/verifycardexcelin/index.jsx @@ -10,6 +10,7 @@ import './index.scss' const { TabPane } = Tabs +const { confirm } = Modal class VerifyCard extends Component { static propTpyes = { @@ -19,6 +20,7 @@ } state = { + updateloading: false, // 淇敼涓� verify: {}, excelColumns: [ { @@ -281,6 +283,8 @@ this.setState({ verify: verify + }, () => { + this.updateChange() }) } @@ -302,6 +306,8 @@ this.setState({ verify: verify + }, () => { + this.updateChange() }) } @@ -323,6 +329,23 @@ this.setState({ verify: verify + }, () => { + this.updateChange() + }) + } + + updateChange = () => { + let _loading = false + if (this.columnForm && this.columnForm.state.editItem) { + _loading = true + } else if (this.scriptsForm && this.scriptsForm.state.editItem) { + _loading = true + } else if (this.uniqueForm && this.uniqueForm.state.editItem) { + _loading = true + } + + this.setState({ + updateloading: _loading }) } @@ -363,6 +386,10 @@ } }, 10) } + + this.setState({ + updateloading: true + }) } handleStatus = (record, type) => { @@ -491,7 +518,19 @@ } } - resolve(_verify) + if (this.state.updateloading) { + confirm({ + content: `瀛樺湪鏈繚瀛橀」锛岀‘瀹氭彁浜ゅ悧锛焋, + okText: this.props.dict['header.confirm'], + cancelText: this.props.dict['header.cancel'], + onOk() { + resolve(_verify) + }, + onCancel() {} + }) + } else { + resolve(_verify) + } } else { notification.warning({ top: 92, -- Gitblit v1.8.0