From f9f60bb0dd17a764ba03faa8041f5b6e9e071553 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期六, 18 一月 2025 23:37:44 +0800 Subject: [PATCH] 2025-01-18 --- src/menu/modalconfig/index.jsx | 25 ++++++++++++++++++++++++- 1 files changed, 24 insertions(+), 1 deletions(-) diff --git a/src/menu/modalconfig/index.jsx b/src/menu/modalconfig/index.jsx index 884b633..91f6f5c 100644 --- a/src/menu/modalconfig/index.jsx +++ b/src/menu/modalconfig/index.jsx @@ -4,7 +4,7 @@ import { DndProvider } from 'react-dnd' import HTML5Backend from 'react-dnd-html5-backend' import { Button, Card, Modal, Collapse, Switch, message, Popover } from 'antd' -import { SettingOutlined, CopyOutlined, SwapOutlined, DeleteOutlined } from '@ant-design/icons' +import { SettingOutlined, CopyOutlined, SwapOutlined, DeleteOutlined, VerticalRightOutlined } from '@ant-design/icons' import { getModalForm } from '@/templates/zshare/formconfig' import SourceElement from '@/templates/modalconfig/dragelement/source' @@ -334,6 +334,28 @@ }) } + toLower = () => { + let _config = fromJS(this.state.config).toJS() + let that = this + + _config.fields = _config.fields.map(item => { + if (item.field) { + item.field = item.field.toLowerCase() + } + return item + }) + + confirm({ + content: `纭畾灏嗗瓧娈佃浆涓哄皬鍐欏悧锛焋, + onOk() { + that.setState({ + config: _config + }) + }, + onCancel() {} + }) + } + triggerCopy = () => { const { config } = this.state @@ -413,6 +435,7 @@ } trigger="hover"> <SwapOutlined /> </Popover> + <VerticalRightOutlined style={{color: 'orange', transform: 'rotate(270deg)'}} title="瀛楁杞皬鍐�" onClick={this.toLower}/> <FormFork forms={config.fields}/> <CopyOutlined title="澶嶅埗" onClick={this.triggerCopy} /> <Switch checkedChildren="寮�" unCheckedChildren="鍏�" defaultChecked={this.state.showField} onChange={(val) => this.setState({showField: val})} /> -- Gitblit v1.8.0