king
2021-01-18 38b5297cbfbe3d61ee2e800b51e8324ee163f43e
src/tabviews/zshare/mutilform/index.jsx
@@ -18,7 +18,7 @@
const CustomSwitch = asyncComponent(() => import('./customSwitch'))
const FileUpload = asyncComponent(() => import('../fileupload'))
const ColorSketch = asyncComponent(() => import('@/mob/colorsketch'))
// const Editor = asyncComponent(() => import('@/components/editor'))
const Editor = asyncComponent(() => import('@/components/editor'))
class MainSearch extends Component {
  static propTpyes = {
@@ -121,7 +121,7 @@
      }
      let _fieldlen = item.fieldlength || 50
      if (item.type === 'textarea' || item.type === 'fileupload' || item.type === 'multiselect') {
      if (item.type === 'textarea' || item.type === 'fileupload' || item.type === 'multiselect' || item.type === 'brafteditor') {
        _fieldlen = item.fieldlength || 512
      } else if (item.type === 'number') {
        _fieldlen = item.decimal ? item.decimal : 0
@@ -1186,6 +1186,33 @@
            </Form.Item>
          </Col>
        )
      } else if (item.type === 'brafteditor') {
        let _max = item.fieldlength || 512
        fields.push(
          <Col span={24} key={index}>
            <Form.Item label={item.tooltip ?
              <Tooltip placement="topLeft" title={item.tooltip}>
                <Icon type="question-circle" />
                {item.label}
              </Tooltip> : item.label
            }>
              {getFieldDecorator(item.field, {
                initialValue: item.initval || null,
                rules: [
                  {
                    required: item.required === 'true',
                    message: this.props.dict['form.required.input'] + item.label + '!'
                  },
                  {
                    max: _max,
                    message: formRule.input.formMessage.replace('@max', _max)
                  }
                ]
              })(<Editor />)}
            </Form.Item>
          </Col>
        )
      }
    })
    
@@ -1373,7 +1400,6 @@
    return (
      <Form {...formItemLayout} className="ant-advanced-search-form main-form-field" id="main-form-box">
        <Row className={'cols' + cols} gutter={24}>{this.getFields()}</Row>
        {/* <Editor /> */}
      </Form>
    )
  }