king
2022-05-12 b8aa5da1b2873bea760483cc5ab335fde9fb6de6
src/menu/popview/index.jsx
@@ -5,6 +5,7 @@
import moment from 'moment'
import HTML5Backend from 'react-dnd-html5-backend'
import { notification, Modal, Collapse, Card, Switch, Button } from 'antd'
import { EyeOutlined, EyeInvisibleOutlined } from '@ant-design/icons'
import Api from '@/api'
import Utils from '@/utils/utils.js'
@@ -47,7 +48,8 @@
    oriConfig: null,
    config: null,
    customComponents: [],
    comloading: false
    comloading: false,
    eyeopen: false
  }
  UNSAFE_componentWillMount() {
@@ -660,7 +662,7 @@
  render () {
    const { btn } = this.props
    const { activeKey, comloading, dict, config, menuloading, customComponents, MenuId } = this.state
    const { activeKey, comloading, dict, config, menuloading, customComponents, MenuId, eyeopen } = this.state
    return (
      <div className="pc-poper-view">
@@ -691,11 +693,12 @@
                </Panel>
              </Collapse>
            </div>
            <div className={'menu-view ' + (menuloading ? 'saving' : '')}>
            <div className={'menu-view' + (menuloading ? ' saving' : '') + (eyeopen ? ' eye-open' : '')}>
              <Card title={
                <div> {config && config.MenuName} </div>
              } bordered={false} extra={
                <div>
                  <Button className="mk-border-purple" onClick={() => this.setState({eyeopen: !eyeopen})}>{!eyeopen ? <EyeOutlined /> : <EyeInvisibleOutlined />} 组件名</Button>
                  <Versions MenuId={MenuId} open_edition={config ? config.open_edition : ''} updateConfig={this.refreshConfig}/>
                  <ReplaceField type="custom" config={config} updateConfig={this.resetConfig}/>
                  <StyleCombControlButton menu={config} />