From 46f79b491173d284a4900d19e7aecf7509481438 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期五, 21 一月 2022 17:21:25 +0800
Subject: [PATCH] 2022-01-21

---
 src/menu/components/tree/antd-tree/index.jsx |   32 +++++++++++++++++---------------
 1 files changed, 17 insertions(+), 15 deletions(-)

diff --git a/src/menu/components/tree/antd-tree/index.jsx b/src/menu/components/tree/antd-tree/index.jsx
index 06040f1..5911a79 100644
--- a/src/menu/components/tree/antd-tree/index.jsx
+++ b/src/menu/components/tree/antd-tree/index.jsx
@@ -1,15 +1,14 @@
 import React, {Component} from 'react'
 import PropTypes from 'prop-types'
 import { is, fromJS } from 'immutable'
-import { Icon, Popover, Tree } from 'antd'
+import { Popover, Tree } from 'antd'
+import { EditOutlined, ToolOutlined, DeleteOutlined, FontColorsOutlined, FileOutlined, FolderOpenOutlined } from '@ant-design/icons'
 
 import asyncComponent from '@/utils/asyncComponent'
 import asyncIconComponent from '@/utils/asyncIconComponent'
 import { resetStyle } from '@/utils/utils-custom.js'
 import MKEmitter from '@/utils/events.js'
 import getWrapForm from './options'
-import zhCN from '@/locales/zh-CN/model.js'
-import enUS from '@/locales/en-US/model.js'
 
 import './index.scss'
 
@@ -30,7 +29,6 @@
   }
 
   state = {
-    dict: sessionStorage.getItem('lang') !== 'en-US' ? zhCN : enUS,
     card: null,
     back: false
   }
@@ -67,6 +65,10 @@
         _card.wrap.name = card.name
         _card.style = config.style
         _card.headerStyle = config.headerStyle
+
+        _card.setting = config.setting
+        _card.columns = config.columns
+        _card.scripts = config.scripts
       }
       
       this.setState({
@@ -164,32 +166,32 @@
     let _style = resetStyle(card.style)
 
     return (
-      <div className="menu-editor-sand-box" style={_style} onClick={this.clickComponent} id={card.uuid}>
+      <div className="menu-tree-box" style={_style} onClick={this.clickComponent} id={card.uuid}>
         <NormalHeader config={card} updateComponent={this.updateComponent}/>
         <Popover overlayClassName="mk-popover-control-wrap" mouseLeaveDelay={0.2} mouseEnterDelay={0.2} content={
           <div className="mk-popover-control">
             <NormalForm title="鍩烘湰璁剧疆" width={800} update={this.updateWrap} getForms={this.getWrapForms}>
-              <Icon type="edit" style={{color: '#1890ff'}} title="缂栬緫"/>
+              <EditOutlined style={{color: '#1890ff'}} title="缂栬緫"/>
             </NormalForm>
             <CopyComponent type="normaltable" card={card}/>
-            <Icon className="style" title="璋冩暣鏍峰紡" onClick={this.changeStyle} type="font-colors" />
+            <FontColorsOutlined className="style" title="璋冩暣鏍峰紡" onClick={this.changeStyle}/>
             <ClockComponent config={card} updateConfig={this.updateComponent}/>
             <UserComponent config={card}/>
-            <Icon className="close" title="鍒犻櫎缁勪欢" type="delete" onClick={() => this.props.deletecomponent(card.uuid)} />
+            <DeleteOutlined className="close" title="鍒犻櫎缁勪欢" onClick={() => this.props.deletecomponent(card.uuid)} />
             <SettingComponent config={card} updateConfig={this.updateComponent} />
           </div>
         } trigger="hover">
-          <Icon type="tool" />
+          <ToolOutlined />
         </Popover>
         <div className="tree-box">
           <Tree defaultExpandAll={true} blockNode showIcon={card.wrap.showIcon === 'true'} showLine={card.wrap.showLine === 'true'} >
-            <TreeNode icon={<Icon type="folder-open" />} title="parent 0" key="0-0">
-              <TreeNode icon={<Icon type="file" />} title="leaf 0-0" key="0-0-0" isLeaf />
-              <TreeNode icon={<Icon type="file" />} title="leaf 0-1" key="0-0-1" isLeaf />
+            <TreeNode icon={<FolderOpenOutlined />} title="parent 0" key="0-0">
+              <TreeNode icon={<FileOutlined />} title="leaf 0-0" key="0-0-0" isLeaf />
+              <TreeNode icon={<FileOutlined />} title="leaf 0-1" key="0-0-1" isLeaf />
             </TreeNode>
-            <TreeNode icon={<Icon type="folder-open" />} title="parent 1" key="0-1">
-              <TreeNode icon={<Icon type="file" />} title="leaf 1-0" key="0-1-0" isLeaf />
-              <TreeNode icon={<Icon type="file" />} title="leaf 1-1" key="0-1-1" isLeaf />
+            <TreeNode icon={<FolderOpenOutlined />} title="parent 1" key="0-1">
+              <TreeNode icon={<FileOutlined />} title="leaf 1-0" key="0-1-0" isLeaf />
+              <TreeNode icon={<FileOutlined />} title="leaf 1-1" key="0-1-1" isLeaf />
             </TreeNode>
           </Tree>
         </div>

--
Gitblit v1.8.0