| | |
| | | } |
| | | } |
| | | |
| | | mkFormSubmit = (btnId, callback, formId) => { |
| | | mkFormSubmit = (btnId, callback, formId, errId) => { |
| | | const { group } = this.state |
| | | |
| | | if (group.uuid !== btnId) return |
| | | |
| | | this.formRef.handleConfirm(formId).then(res => { |
| | | this.formRef.handleConfirm(formId, errId).then(res => { |
| | | MKEmitter.emit('triggerFormSubmit', {menuId: btnId, form: res}) |
| | | }, () => { |
| | | callback && callback() |
| | |
| | | data={data} |
| | | action={group} |
| | | unload={config.setting.supModule && !BID} |
| | | inputSubmit={(id) => this.mkFormSubmit(group.uuid, null, id)} |
| | | inputSubmit={(id, errId) => this.mkFormSubmit(group.uuid, null, id, errId)} |
| | | wrappedComponentRef={(inst) => this.formRef = inst} |
| | | /> : null} |
| | | {data ? <div className={'mk-form-action ' + (group.$button || '')}> |