From d5fdd438627a1b3e5fdb438968dc289781bddb18 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A4=9C=E7=AC=99=E6=AD=8C?= <2277317060@qq.com> Date: Sat, 23 Jul 2022 18:31:47 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=95=8C=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/resources/static/js/echartsCommon.js | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/ruoyi-admin/src/main/resources/static/js/echartsCommon.js b/ruoyi-admin/src/main/resources/static/js/echartsCommon.js index 8195faf..6413be8 100644 --- a/ruoyi-admin/src/main/resources/static/js/echartsCommon.js +++ b/ruoyi-admin/src/main/resources/static/js/echartsCommon.js @@ -138,8 +138,7 @@ const horizontalRoundedBarChartWithBackground = function (data, id) { $(window).resize(charts.resize); } const horizontalRoundedBarChartWithBackgroundTwo = function (data, id) { - let time = () => { - } + let time =() =>{} clearInterval(time) let charts = echarts.init(id); if (!data) { @@ -254,8 +253,7 @@ const horizontalRoundedBarChartWithBackgroundTwo = function (data, id) { }) let step = 1 / (data.yNameOne.length / 9) * 100 - time = () => { - setInterval(() => { + time = setInterval(() => { option.dataZoom[0].end += step option.dataZoom[0].start += step if (option.dataZoom[0].start >= 100) { @@ -268,8 +266,7 @@ const horizontalRoundedBarChartWithBackgroundTwo = function (data, id) { } charts.setOption(option); }, 6000) - } - time() + // time() } charts.setOption(option); $(window).resize(charts.resize); From ba74d85fb8284820f9d028ca38fe49c8aa0e043e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A4=9C=E7=AC=99=E6=AD=8C?= <2277317060@qq.com> Date: Mon, 25 Jul 2022 09:22:01 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=95=8C=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ruoyi-admin/src/main/resources/static/js/echartsCommon.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/ruoyi-admin/src/main/resources/static/js/echartsCommon.js b/ruoyi-admin/src/main/resources/static/js/echartsCommon.js index 6413be8..7ff58cc 100644 --- a/ruoyi-admin/src/main/resources/static/js/echartsCommon.js +++ b/ruoyi-admin/src/main/resources/static/js/echartsCommon.js @@ -1,5 +1,5 @@ const vw = (document.documentElement.clientWidth || document.body.clientWidth) / 100 - +let time1 =() =>{} // 随机数 const random = (val = 1) => { return Math.ceil(Math.random() * val) @@ -138,8 +138,7 @@ const horizontalRoundedBarChartWithBackground = function (data, id) { $(window).resize(charts.resize); } const horizontalRoundedBarChartWithBackgroundTwo = function (data, id) { - let time =() =>{} - clearInterval(time) + clearInterval(time1) let charts = echarts.init(id); if (!data) { data = { @@ -253,7 +252,7 @@ const horizontalRoundedBarChartWithBackgroundTwo = function (data, id) { }) let step = 1 / (data.yNameOne.length / 9) * 100 - time = setInterval(() => { + time1 = setInterval(() => { option.dataZoom[0].end += step option.dataZoom[0].start += step if (option.dataZoom[0].start >= 100) {