| | |
| | | profVisible: true, |
| | | card: element |
| | | }) |
| | | MKEmitter.emit('modalStatus', '验证信息') |
| | | } |
| | | |
| | | /** |
| | |
| | | }, () => { |
| | | this.props.updateElement(_elements) |
| | | }) |
| | | |
| | | MKEmitter.emit('modalStatus', false) |
| | | }) |
| | | } |
| | | |
| | |
| | | } |
| | | } |
| | | |
| | | handleSave = (_cards, btn, modal) => { |
| | | handleSave = (componentId, btnId, modal) => { |
| | | const { cards } = this.props |
| | | const { elements } = this.state |
| | | |
| | | if (cards.uuid !== _cards.uuid) return |
| | | if (cards.uuid !== componentId) return |
| | | |
| | | let _index = elements.findIndex(cell => cell.uuid === btn.uuid) |
| | | let _index = elements.findIndex(cell => cell.uuid === btnId) |
| | | |
| | | if (_index === -1) return |
| | | |
| | | let _elements = elements.map(cell => { |
| | | if (cell.uuid === btn.uuid) { |
| | | if (cell.uuid === btnId) { |
| | | cell.modal = modal |
| | | } |
| | | |
| | |
| | | if (this.verifyRef.handleCancel) { |
| | | this.verifyRef.handleCancel().then(() => { |
| | | this.setState({ profVisible: false }) |
| | | MKEmitter.emit('modalStatus', false) |
| | | }) |
| | | } else { |
| | | this.setState({ profVisible: false }) |
| | | MKEmitter.emit('modalStatus', false) |
| | | } |
| | | }} |
| | | destroyOnClose |