From 1aa5654a0b51bb82948fff8bed77b166f25f11ea Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期三, 19 二月 2025 20:14:20 +0800 Subject: [PATCH] Merge branch 'develop' --- src/menu/components/share/pastecomponent/index.jsx | 46 +++++++++++++++++++++++++++++++++++----------- 1 files changed, 35 insertions(+), 11 deletions(-) diff --git a/src/menu/components/share/pastecomponent/index.jsx b/src/menu/components/share/pastecomponent/index.jsx index a96fa09..90944e9 100644 --- a/src/menu/components/share/pastecomponent/index.jsx +++ b/src/menu/components/share/pastecomponent/index.jsx @@ -6,9 +6,11 @@ import Utils from '@/utils/utils.js' import MKEmitter from '@/utils/events.js' +import MenuUtils from '@/utils/utils-custom.js' import asyncComponent from '@/utils/asyncComponent' // import './index.scss' +const { confirm } = Modal const PasteForm = asyncComponent(() => import('@/templates/zshare/pasteform')) class PasteController extends Component { @@ -28,7 +30,9 @@ item.uuid = _uuid } - if (item.copyType === 'cardcell' && config.subtype === 'datacard') { + if (item.copyType === 'action') { + MenuUtils.resetBtn(item, _uuid) + } else if (item.copyType === 'cardcell' && config.subtype === 'datacard') { item.setting = item.setting || {} item.$cardType = 'extendCard' item.setting.width = item.setting.width || 6 @@ -39,6 +43,10 @@ cell.datatype = 'static' } cell.uuid = Utils.getuuid() + + if (cell.eleType === 'button') { + MenuUtils.resetBtn(cell, _uuid) + } return cell }) } @@ -48,6 +56,10 @@ cell.datatype = 'static' } cell.uuid = Utils.getuuid() + + if (cell.eleType === 'button') { + MenuUtils.resetBtn(cell, _uuid) + } return cell }) } @@ -64,12 +76,18 @@ if (item.elements) { item.elements = item.elements.map(cell => { cell.uuid = Utils.getuuid() + if (cell.eleType === 'button') { + MenuUtils.resetBtn(cell, _uuid) + } return cell }) } if (item.backElements) { item.backElements = item.backElements.map(cell => { cell.uuid = Utils.getuuid() + if (cell.eleType === 'button') { + MenuUtils.resetBtn(cell, _uuid) + } return cell }) } @@ -87,6 +105,9 @@ } else if (col.type === 'custom' && col.elements) { col.elements = col.elements.map(cell => { cell.uuid = Utils.getuuid() + if (cell.eleType === 'button') { + MenuUtils.resetBtn(cell, _uuid) + } return cell }) } @@ -153,17 +174,20 @@ } } - if (res.field && keys.includes(res.field.toLowerCase())) { - notification.warning({ - top: 92, - message: '鎼滅储瀛楁宸插瓨鍦紒', - duration: 5 - }) - return - } - - MKEmitter.emit('plusSearch', config.uuid, res, 'simple') this.setState({visible: false}) + if (res.field && keys.includes(res.field.toLowerCase())) { + confirm({ + title: '鎼滅储瀛楁宸插瓨鍦紒', + okText: '鐭ラ亾浜�', + cancelText: '鏇挎崲', + onOk() {}, + onCancel() { + MKEmitter.emit('plusSearch', config.uuid, res, 'replace') + } + }) + } else { + MKEmitter.emit('plusSearch', config.uuid, res, 'simple') + } return } else if (type === 'cardcell') { config.subcards.push(res) -- Gitblit v1.8.0