From ee50d5424a093209d1c5c549f4578107893b22f8 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期四, 05 十一月 2020 18:40:54 +0800 Subject: [PATCH] 2020-11-05 --- src/tabviews/custom/components/share/tabtransfer/index.jsx | 23 +++++++++++++++-------- 1 files changed, 15 insertions(+), 8 deletions(-) diff --git a/src/tabviews/custom/components/share/tabtransfer/index.jsx b/src/tabviews/custom/components/share/tabtransfer/index.jsx index f2bb801..ffa91e7 100644 --- a/src/tabviews/custom/components/share/tabtransfer/index.jsx +++ b/src/tabviews/custom/components/share/tabtransfer/index.jsx @@ -68,16 +68,17 @@ } let params = [] - config.components.forEach(component => { - if (component.type === 'tabs') return + config.components.forEach(item => { + if (item.type === 'tabs') return - if (!component.format || (component.subtype === 'propcard' && component.wrap.datatype === 'static')) return + if (!item.setting || item.setting.interType !== 'system') return + if (!item.format || (item.subtype === 'propcard' && item.wrap.datatype === 'static')) return - if (component.dataName && !component.pageable && component.setting.interType === 'system' && component.setting.onload === 'true' && component.setting.sync === 'true') { - let param = this.getDefaultParam(component, _mainSearch) + if (item.dataName && (!item.pageable || (item.pageable && !item.setting.laypage)) && item.setting.onload === 'true' && item.setting.sync === 'true') { + let param = this.getDefaultParam(item, _mainSearch) params.push(param) } else { - component.setting.sync = 'false' + item.setting.sync = 'false' } }) @@ -103,8 +104,14 @@ if (search && search.length > 0) { searchlist = Utils.initMainSearch(search) } + if (setting.useMSearch === 'true') { - searchlist = [...mainSearch, ...searchlist] + let keys = searchlist.map(item => item.key) + mainSearch.forEach(item => { + if (!keys.includes(item.key)) { + searchlist.push(item) + } + }) } let arr_field = columns.map(col => col.field) @@ -255,7 +262,7 @@ if (item.subtype === 'datacard') { return ( <Col span={item.width} key={item.uuid}> - <DataCard config={item} BID={BID} mainSearch={mainSearch} menuType={menuType} dataManager={dataManager} /> + <DataCard config={item} data={data} BID={BID} mainSearch={mainSearch} menuType={menuType} dataManager={dataManager} /> </Col> ) } else if (item.subtype === 'propcard') { -- Gitblit v1.8.0