king
2021-07-28 137fb8ea6af2789b3238b22bac31d80bced41dfe
src/menu/components/tabs/tablabelform/index.jsx
@@ -1,18 +1,18 @@
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { Form, Row, Col, Input, Icon, Select } from 'antd'
import { Form, Row, Col, Input, Icon, Select, Radio } from 'antd'
// import { formRule } from '@/utils/option.js'
import './index.scss'
class SettingForm extends Component {
  static propTpyes = {
    dict: PropTypes.object,        // 字典项
    tab: PropTypes.object,         // 数据源配置
    inputSubmit: PropTypes.func    // 回车事件
    dict: PropTypes.object,
    setting: PropTypes.object,
    tab: PropTypes.object,
    inputSubmit: PropTypes.func
  }
  state = {roleList: []}
  state = {roleList: [], appType: sessionStorage.getItem('appType')}
  UNSAFE_componentWillMount () {
    let roleList = sessionStorage.getItem('sysRoles')
@@ -51,9 +51,9 @@
  }
  render() {
    const { tab } = this.props
    const { tab, setting } = this.props
    const { getFieldDecorator } = this.props.form
    const { roleList } = this.state
    const { roleList, appType } = this.state
    const formItemLayout = {
      labelCol: {
@@ -97,6 +97,18 @@
              )}
            </Form.Item>
          </Col>
          {appType === 'mob' && setting.position === 'top' && setting.display === 'inline-block' ? <Col span={24}>
            <Form.Item label="搜索">
              {getFieldDecorator('hasSearch', {
                initialValue: tab.hasSearch || 'false'
              })(
                <Radio.Group>
                  <Radio value="false">无</Radio>
                  <Radio value="icon">有</Radio>
                </Radio.Group>
              )}
            </Form.Item>
          </Col> : null}
          <Col span={24}>
            <Form.Item label="黑名单">
              {getFieldDecorator('blacklist', {