From 50b49c1b760489c3430fc382656d57c5fbbab07c Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期一, 29 四月 2024 16:07:24 +0800 Subject: [PATCH] 2024-04-29 --- src/tabviews/custom/popview/index.jsx | 52 ++++++++++++++++++++++++++++++++-------------------- 1 files changed, 32 insertions(+), 20 deletions(-) diff --git a/src/tabviews/custom/popview/index.jsx b/src/tabviews/custom/popview/index.jsx index ca70341..935f765 100644 --- a/src/tabviews/custom/popview/index.jsx +++ b/src/tabviews/custom/popview/index.jsx @@ -135,18 +135,6 @@ config.components.forEach(component => { if (component.type !== 'search') return - if (param.$searchkey) { - component.search = component.search.map(item => { - if (['text', 'select', 'link', 'checkcard'].includes(item.type) && param.$searchkey === item.field) { - item.initval = param.$searchval - } - - return item - }) - - component.$searches = Utils.initMainSearch(component.search) - } - window.GLOB.SearchBox.set(Tab.uuid, component.$searches) if (component.$s_req) { @@ -326,8 +314,14 @@ } } - if (item.wrap && item.wrap.supType === 'multi') { // 鏁版嵁鍗″涓婄骇缁勪欢 - item.setting.supModule = item.supNodes[0].componentId + if (item.wrap && item.wrap.supType === 'multi') { // 鏁版嵁鍗°�乼able澶氫笂绾х粍浠� + item.supNodes = item.supNodes.map(node => node.componentId) + if (item.supNodes[0]) { + item.setting.supModule = item.supNodes[0] + } else { + item.supNodes = null + item.setting.supModule = '' + } } else if (item.setting && item.setting.supModule && typeof(item.setting.supModule) !== 'string') { let pid = item.setting.supModule.pop() if (pid && pid !== 'empty') { @@ -663,7 +657,7 @@ if (cell.syncComponentId) { if (cell.syncComponentId === item.setting.supModule) { cell.syncComponentId = '' - if (cell.execSuccess === 'line' || cell.execSuccess === 'grid') { + if (['line', 'grid', 'line_grid'].includes(cell.execSuccess)) { cell.execSuccess = 'mainline' } } else if (cell.syncComponentId === 'multiComponent') { @@ -671,8 +665,17 @@ return m.syncComId.pop() || '' }) - if (item.setting.supModule && ids.includes(item.setting.supModule)) { - if (cell.execSuccess === 'line' || cell.execSuccess === 'grid') { + if (item.supNodes) { + item.supNodes.forEach(node => { + if (!ids.includes(node)) return + + if (['line', 'grid', 'line_grid'].includes(cell.execSuccess)) { + cell.execSuccess = 'mainline' + } + ids = ids.filter(id => id !== node) + }) + } else if (item.setting.supModule && ids.includes(item.setting.supModule)) { + if (['line', 'grid', 'line_grid'].includes(cell.execSuccess)) { cell.execSuccess = 'mainline' } ids = ids.filter(id => id !== item.setting.supModule) @@ -698,6 +701,17 @@ if (cell.marks && cell.marks.length === 0) { cell.marks = null + } + if (cell.anchors && cell.anchors.length === 0) { + cell.anchors = null + } + + if (cell.linkmenu && cell.linkmenu.length > 0) { + let menu_id = cell.linkmenu.pop() + cell.linkThdMenu = window.GLOB.mkThdMenus.get(menu_id) || '' + if (!cell.linkThdMenu) { + cell.link = '' + } } if (['text', 'number', 'formula'].includes(cell.eleType)) { @@ -1121,9 +1135,7 @@ ) } else if (item.type === 'group' && item.subtype === 'normalgroup') { return ( - <Col span={item.width} style={style} key={item.uuid}> - <NormalGroup config={item}/> - </Col> + <NormalGroup config={item} style={style} key={item.uuid}/> ) } else if (item.type === 'editor') { return ( -- Gitblit v1.8.0