king
2022-02-17 3c3c5b4e5f239b712eb837af7f732ce5ab3e859f
src/templates/zshare/verifycard/customscript/index.jsx
@@ -11,6 +11,7 @@
class CustomForm extends Component {
  static propTpyes = {
    type: PropTypes.any,
    dict: PropTypes.object,         // 字典项
    btn: PropTypes.object,          // 按钮信息
    usefulfields: PropTypes.string, // 可用字段
@@ -219,7 +220,7 @@
  }
  render() {
    const { usefulfields, systemScripts, btn } = this.props
    const { usefulfields, systemScripts, btn, type } = this.props
    const { getFieldDecorator } = this.props.form
    const formItemLayout = {
      labelCol: {
@@ -232,20 +233,22 @@
      }
    }
    let _type = type || ''
    return (
      <Form {...formItemLayout} className="verify-form" id="verify-custom-scripts">
      <Form {...formItemLayout} className="verify-form verify-custom-scripts" id={'verify-custom-scripts' + _type}>
        <Row gutter={24}>
          {btn.sql ? <Col span={8}>
          {!_type && btn.sql ? <Col span={8}>
            <Form.Item label={'表名'} style={{whiteSpace: 'nowrap', margin: 0}}>
              {btn.sql}
            </Form.Item>
          </Col> : null}
          <Col span={10}>
          {!_type ? <Col span={10}>
            <Form.Item label={'报错字段'} style={{margin: 0, whiteSpace: 'nowrap'}}>
              ErrorCode(增加后缀NT表示数据不回滚,如ENT、NNT、FNT、NMNT), retmsg
            </Form.Item>
          </Col>
          {usefulfields ? <Col span={24} className="sqlfield">
          </Col> : null}
          {!_type && usefulfields ? <Col span={24} className="sqlfield">
            <Form.Item label={'可用字段'}>
              {usefulfields}
            </Form.Item>
@@ -274,7 +277,7 @@
                showSearch
                filterOption={(input, option) => option.props.children.toLowerCase().indexOf(input.toLowerCase()) >= 0}
                onSelect={this.selectScript}
                getPopupContainer={() => document.getElementById('verify-custom-scripts')}
                getPopupContainer={() => document.getElementById('verify-custom-scripts' + _type)}
              >
                <Select.Option key="default" value={this.props.defaultsql}>默认sql</Select.Option>
                <Select.Option key="debugger" value={`z_debug: select @ErrorCode='E',@retmsg='测试断点' goto aaa`}>