diff --git a/src/views/components/emotionDecod.vue b/src/views/components/emotionDecod.vue
index ac33a8d..b4498b3 100644
--- a/src/views/components/emotionDecod.vue
+++ b/src/views/components/emotionDecod.vue
@@ -66,15 +66,27 @@ function initQXNLZHEcharts(kline, qxnlzhqData) {
const dealData = spliteDate(data);
// 给配置项
const KlineOption = {
- tooltip: {
- trigger: "item", // 触发类型 坐标轴触发
- // axisPointer: {
- // type: "cross", // 十字准星效果
- // crossStyle: {
- // color: "#999"
- // }
- // }
- },
+ tooltip: {
+ trigger: 'item', // 触发类型 坐标轴触发
+ axisPointer: {
+ type: 'cross', // 十字准星效果
+ crossStyle: {
+ color: '#999'
+ }
+ },
+ formatter: function (params) {
+ if (params.seriesType === 'candlestick') {
+ const date = params.name
+ // 开收低高分别取参数的第2到第5个数
+ const open = params.data[1]
+ const close = params.data[2]
+ const low = params.data[3]
+ const high = params.data[4]
+ return `日期: ${date}
开: ${open}
收: ${close}
低: ${low}
高: ${high}`
+ }
+ return params.value[2]
+ }
+ },
//控制坐标轴
grid: [