From f07c42a322f41e14ef5b1bf8f2fd66fc5d338cdd Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期三, 28 六月 2023 18:17:09 +0800 Subject: [PATCH] 2023-06-28 --- src/tabviews/custom/components/chart/antv-bar-line/index.jsx | 28 ++++++++++++++++++++++++---- 1 files changed, 24 insertions(+), 4 deletions(-) diff --git a/src/tabviews/custom/components/chart/antv-bar-line/index.jsx b/src/tabviews/custom/components/chart/antv-bar-line/index.jsx index dc80392..68651c3 100644 --- a/src/tabviews/custom/components/chart/antv-bar-line/index.jsx +++ b/src/tabviews/custom/components/chart/antv-bar-line/index.jsx @@ -17,7 +17,6 @@ import NormalHeader from '@/tabviews/custom/components/share/normalheader' import './index.scss' -// const NormalHeader = asyncComponent(() => import('@/tabviews/custom/components/share/normalheader')) const ExcelOutButton = asyncComponent(() => import('@/tabviews/zshare/actionList/exceloutbutton')) const ExcelInButton = asyncComponent(() => import('@/tabviews/zshare/actionList/excelInbutton')) @@ -536,7 +535,7 @@ let result = await Api.genericInterface(param) if (result.status) { - if (config.$cache) { + if (config.$cache && config.setting.onload !== 'false') { Api.writeCacheConfig(config.uuid, result.data || '') } @@ -548,17 +547,38 @@ this.data = result.data || [] this.handleData() } + + if (config.timer && config.clearField && result.data && result.data[0]) { + let vals = (config.clearValue || '').split(',') + if (vals.includes(result.data[0][config.clearField])) { + this.timer && this.timer.stop() + } + } + if (result.message) { + if (result.ErrCode === 'Y') { + Modal.success({ + title: result.message + }) + } else if (result.ErrCode === 'S') { + notification.success({ + top: 92, + message: result.message, + duration: 2 + }) + } + } } else { this.setState({ loading: false }) this.timer && this.timer.stop() + if (!result.message) return if (result.ErrCode === 'N') { Modal.error({ title: result.message, }) - } else { + } else if (result.ErrCode !== '-2') { notification.error({ top: 92, message: result.message, @@ -1780,7 +1800,7 @@ let menu = null if (plot.menus && plot.menus.length > 0) { - let s = data[plot.menuType] || '' + let s = data[plot.menuType] + '' plot.menus.forEach(m => { if (s !== m.sign) return menu = m -- Gitblit v1.8.0