| | |
| | | return |
| | | } |
| | | |
| | | let _loading = false |
| | | let msg = '' |
| | | if (this.customForm && this.customForm.state.editItem) { |
| | | _loading = true |
| | | msg = '自定义验证' |
| | | } else if (this.customForm && this.customForm.props.form.getFieldValue('sql') && !/^\s+$/.test(this.customForm.props.form.getFieldValue('sql'))) { |
| | | msg = '自定义验证' |
| | | } else if (this.orderForm && this.orderForm.state.editItem) { |
| | | _loading = true |
| | | msg = '单号生成' |
| | | } else if (this.scriptsForm && this.scriptsForm.state.editItem) { |
| | | _loading = true |
| | | } |
| | | |
| | | if (this.scriptsForm && this.scriptsForm.props.form.getFieldValue('sql') && this.scriptsForm.props.form.getFieldValue('sql') !== ' ') { |
| | | _loading = true |
| | | } else if (this.customForm && this.customForm.props.form.getFieldValue('sql') && this.customForm.props.form.getFieldValue('sql') !== ' ') { |
| | | _loading = true |
| | | msg = '自定义脚本' |
| | | } else if (this.scriptsForm && this.scriptsForm.props.form.getFieldValue('sql') && !/^\s+$/.test(this.scriptsForm.props.form.getFieldValue('sql'))) { |
| | | msg = '自定义脚本' |
| | | } |
| | | |
| | | if (verify.noteEnable === 'true' && !verify.noteCode) { // 开启短信时,需要模板编码 |
| | |
| | | verify.noteCode = '' |
| | | } |
| | | |
| | | if (_loading) { |
| | | if (msg) { |
| | | confirm({ |
| | | content: `存在未保存项,确定提交吗?`, |
| | | content: msg + '未保存,确定提交吗?', |
| | | onOk() { |
| | | resolve(verify) |
| | | }, |