From 4313d9ccea6534b1da71baa1bf499f045d3c1f0b Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期五, 08 七月 2022 00:57:55 +0800 Subject: [PATCH] 2022-07-08 --- src/menu/components/chart/antv-bar/index.jsx | 18 +++++++++++------- 1 files changed, 11 insertions(+), 7 deletions(-) diff --git a/src/menu/components/chart/antv-bar/index.jsx b/src/menu/components/chart/antv-bar/index.jsx index 0f5c231..ca919d0 100644 --- a/src/menu/components/chart/antv-bar/index.jsx +++ b/src/menu/components/chart/antv-bar/index.jsx @@ -788,13 +788,17 @@ } } - const view2 = chart.createView({ - region: { - start: { x: 0, y: 0 }, - end: { x: 1, y: 1 } - }, - padding - }) + let view2 = chart // 鏃犵嫭绔嬫煴鐘跺浘鏃朵笉鍋氬垎闈� + + if (Bar_axis.length) { + view2 = chart.createView({ + region: { + start: { x: 0, y: 0 }, + end: { x: 1, y: 1 } + }, + padding + }) + } view2.data(dv.rows) -- Gitblit v1.8.0