king
2023-08-04 051981a2211bb86f88a6d68f2e29816f8caeac20
src/templates/sharecomponent/searchcomponent/searchform/index.jsx
@@ -84,6 +84,7 @@
      {value: '[3, 0]', label: '近三天'},
      {value: '[7, 0]', label: '近七天'},
      {value: '[30, 0]', label: '近30天'},
      {value: '[90, 0]', label: '近90天'},
      {value: '[7, -7]', label: '前后七天'},
      {value: '[30, -30]', label: '前后30天'},
      {value: '[90, -90]', label: '前后90天'},
@@ -119,11 +120,7 @@
  }
  state = {
    openType: null,          // 搜索条件显示类型
    resourceType: null,      // 下拉搜索时,选项来源类型
    formlist: null,          // 表单
    cFields: [],
    textTooltip: '字段名可以使用逗号分隔,进行综合搜索',
    formlist: null
  }
  record = {}
@@ -213,6 +210,9 @@
        }
        if (this.record.selectStyle === 'custom') {
          shows.push('backgroundColor')
        }
        if (this.record.multiple === 'dropdown' && this.record.resourceType === '1') {
          shows.push('mark', 'parentField')
        }
      }
      shows.push('linkField')
@@ -487,7 +487,7 @@
            <Input placeholder="" autoComplete="off" onPressEnter={this.handleSubmit} />
          </AutoComplete>
        } else {
          content = <Input placeholder="" autoComplete="off" onPressEnter={this.handleSubmit} />
          content = <Input placeholder="" autoComplete="off" onPressEnter={this.handleSubmit} onChange={(e) => {this.optionChange(item.key, e.target.value)}}/>
        }
      } else if (item.type === 'number') {
        rules = [
@@ -554,7 +554,7 @@
          if (this.record.linkField) {
            type = 'link'
          }
          content = <DataTable type={type} display={this.record.display} linkSubFields={[]} transfield={{}} fields={this.record.fields || []} onChange={this.changeOptions}/>
          content = <DataTable type={type} multiple={this.record.multiple} display={this.record.display} linkSubFields={[]} transfield={{}} fields={this.record.fields || []} onChange={this.changeOptions}/>
        }
      } else if (item.type === 'fields') {
        span = 24
@@ -665,10 +665,15 @@
              values.options = []
            }
          } else if (values.type === 'checkcard') {
            if (values.multiple === 'dropdown' && values.display !== 'text') {
              values.multiple = 'false'
            }
            if (values.resourceType === '0') {
              values.options = values.options || []
              values.options = values.options.map(m => {
                m.ParentID = m.ParentID || ''
                m.pid = m.pid || ''
                return m
              })