From f744202ac799c443e9019e8e7777fcb09d670d55 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期五, 13 九月 2024 11:11:17 +0800 Subject: [PATCH] 2024-09-13 --- src/utils/utils-datamanage.js | 7 ++++++- src/tabviews/custom/index.jsx | 6 +++++- src/tabviews/custom/components/share/tabtransfer/index.jsx | 6 +++++- 3 files changed, 16 insertions(+), 3 deletions(-) diff --git a/src/tabviews/custom/components/share/tabtransfer/index.jsx b/src/tabviews/custom/components/share/tabtransfer/index.jsx index fee500a..0a67c42 100644 --- a/src/tabviews/custom/components/share/tabtransfer/index.jsx +++ b/src/tabviews/custom/components/share/tabtransfer/index.jsx @@ -140,7 +140,11 @@ let param = getStructuredParams(params, config, BID) if (config.$cache && config.$time) { - Api.getLCacheConfig(params[0].uuid || params[0].id, config.$time, BID).then(res => { + let uuid = params[0].uuid || '' + if (params[0].id) { + uuid = window.GLOB.CacheData.get('first_' + params[0].id) || '' + } + Api.getLCacheConfig(uuid, config.$time, BID).then(res => { if (!res.valid) { this.getMainData(param, params, config.uuid) } diff --git a/src/tabviews/custom/index.jsx b/src/tabviews/custom/index.jsx index 88009a6..333a938 100644 --- a/src/tabviews/custom/index.jsx +++ b/src/tabviews/custom/index.jsx @@ -1383,7 +1383,11 @@ this.setState({loading: true, loadingview: false}) if (config.$cache && config.$time) { - Api.getLCacheConfig(params[0].uuid || params[0].id, config.$time, BID).then(res => { + let uuid = params[0].uuid || '' + if (params[0].id) { + uuid = window.GLOB.CacheData.get('first_' + params[0].id) || '' + } + Api.getLCacheConfig(uuid, config.$time, BID).then(res => { if (!res.valid) { this.getMainData(param, params, config.MenuID) } else { diff --git a/src/utils/utils-datamanage.js b/src/utils/utils-datamanage.js index 900a62c..7944666 100644 --- a/src/utils/utils-datamanage.js +++ b/src/utils/utils-datamanage.js @@ -635,6 +635,11 @@ const { columns, setting, dataName, format, uuid } = component if (window.backend && window.GLOB.CacheData.has('sql_' + uuid)) { + if (first) { + let item = window.GLOB.CacheData.get('sql_' + uuid) + window.GLOB.CacheData.set('first_' + item.id, uuid) + } + return getBackendQueryParam(setting, searchlist, setting.order, 1, 1000, '', BID, '', dataName) } @@ -713,7 +718,7 @@ if (window.backend && params[0].exps) { let param = { $backend: true, - $type: 's_Get_TableData', + $type: 's_Get_structured_data', data: params.map(item => { let cell = {...item} -- Gitblit v1.8.0