From c7c793f399abd64e7d22bc5ce216a589a6cd14e6 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期三, 15 十一月 2023 13:14:19 +0800
Subject: [PATCH] 2023-11-15

---
 src/menu/components/chart/antv-dashboard/chartcompile/index.jsx |   14 +++++++++++++-
 1 files changed, 13 insertions(+), 1 deletions(-)

diff --git a/src/menu/components/chart/antv-dashboard/chartcompile/index.jsx b/src/menu/components/chart/antv-dashboard/chartcompile/index.jsx
index b25f286..71f4cc1 100644
--- a/src/menu/components/chart/antv-dashboard/chartcompile/index.jsx
+++ b/src/menu/components/chart/antv-dashboard/chartcompile/index.jsx
@@ -1,7 +1,7 @@
 import React, {Component} from 'react'
 import PropTypes from 'prop-types'
 import { fromJS } from 'immutable'
-import { Modal, Form, Row, Col, Select, Radio, Tooltip, Input, InputNumber, Tabs, Button } from 'antd'
+import { Modal, Form, Row, Col, Select, Radio, Tooltip, Input, InputNumber, notification, Tabs, Button } from 'antd'
 import { QuestionCircleOutlined, EditOutlined } from '@ant-design/icons'
 
 import Utils from '@/utils/utils.js'
@@ -250,6 +250,18 @@
       this.baseRef.handleConfirm().then(res => {
         let _plot = {...plot, ...res}
 
+        if (!plot.valueField && tab === 'color') {
+          this.setState({
+            plot: _plot,
+            view: 'normal'
+          })
+          notification.warning({
+            top: 92,
+            message: '璇锋坊鍔犲浘琛ㄨ缃��',
+            duration: 3
+          })
+          return
+        }
         this.setState({
           plot: _plot,
           view: tab

--
Gitblit v1.8.0